1import { 2 memo, 3 __memo_context_type, 4 __memo_id_type, 5 State, 6 StateDecoratedVariable, 7 MutableState, 8 stateOf, 9 observableProxy 10} from '@ohos.arkui.stateManagement' // should be insert by ui-plugins 11 12import { 13 Text, 14 TextAttribute, 15 Column, 16 Component, 17 Button, 18 ButtonAttribute, 19 ClickEvent, 20 UserView, 21 TextInput, 22 TextInputController, 23 TextArea, 24 TextAreaController, 25 Color, 26 CopyOptions, 27 InputType, 28 UnderlineColor, 29 IconOptions, 30 CancelButtonOptions, 31 CancelButtonStyle, 32 FontWeight, 33 TextMenuItem, 34 Resource, 35 EditMenuOptions, 36 TextRange, 37 TextMenuItemId, 38 EllipsisMode, 39 TextOverflow, 40 TextAlign, 41 LengthMetrics, 42 TextDecorationType, 43 TextDecorationOptions, 44 TextDecorationStyle, 45 DecorationStyleInterface, 46 Font, 47 FontStyle, 48 ShadowOptions, 49 Callback, 50 TextCase, 51 TextHeightAdaptivePolicy, 52 WordBreak, 53 TextSelectableMode, 54 LineBreakStrategy, 55 MarqueeState, 56 MarqueeStartPolicy, 57 TextMarqueeOptions, 58 ObscuredReasons, 59 TextDataDetectorType, 60 Builder, 61 Menu, 62 Span, 63 ImageSpan, 64 TextSpanType, 65 TextResponseType, 66 MenuItemGroup, 67 ImageFit, 68 ImageSpanAlignment, 69 TextController, 70 TextOptions, 71 MenuItem, 72 MenuItemOptions, 73 TextRange, 74 StyledStringValue, 75 DecorationStyle, 76 StyleOptions, 77 StyledString, 78 StyledStringKey, 79 TextStyle, 80 TextContentControllerOptions, 81 EditableTextChangeValue, 82 Margin, 83 Search, 84 SearchOptions, 85 Marquee, 86 MarqueeUpdateStrategy, 87 MarqueeOptions, 88 TextMenuShowMode, 89 SymbolGlyph, 90 NavDestination, 91 NavPathStack, 92 NavDestinationContext, 93 Callback 94} from '@ohos.arkui.component' // TextAttribute should be insert by ui-plugins 95 96import hilog from '@ohos.hilog' 97import { $r } from 'arkui.component.common' 98 99@Component 100export struct SearchTest { 101 textAreaController: TextAreaController = new TextAreaController() 102 textInputController: TextInputController = new TextInputController() 103 104 build() { 105 NavDestination() { 106 Column(undefined) { 107 Text('Search测试') 108 .fontSize(12) 109 .textAlign(TextAlign.Center) 110 .margin({ 111 bottom: 0, 112 top: 30, 113 left: 0, 114 right: 0 115 } as Margin) 116 Search({ placeholder: 'Type to search...' } as SearchOptions) 117 .searchButton('SEARCH') 118 } 119 } 120 .title('Search搜索框用例001') 121 } 122} 123 124@Component 125struct Child { 126 @State stateVar: string = 'Child'; 127 build() { 128 Text(this.stateVar).fontSize(50) 129 } 130}