From f9c9a8ac55d8decf7f66764e4d7039537c241cf0 Mon Sep 17 00:00:00 2001 From: chenbaodi Date: Thu, 10 Oct 2024 14:06:28 +0800 Subject: [PATCH] =?UTF-8?q?pr=20=E4=BB=A3=E7=A0=81=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: 陈宝迪 --- .../entry/src/ohosTest/ets/test/List.test.ets | 83 +- ...ntEditAbleTextThreeReplacement001.test.ets | 421 ++ ...ponentReverseAnalysisInterface001.test.ets | 112 + ...ponentSettextselectionReplacement.test.ets | 146 + ...tAffineTransformationInterface001.test.ets | 358 + ...onentTextCommonHandleInterface001.test.ets | 382 ++ ...ComponentTextCommonSelectionState.test.ets | 943 +++ ...onentTextCopyAttributeReplacement.test.ets | 1154 ++++ .../UIComponentTextEditMenuOptions.test.ets | 501 ++ ...xtInputDeleteCallbackInterface001.test.ets | 691 ++ ...extRefactorAdjustMentInterface001.test.ets | 698 ++ ...onentTextSearchActionInterface001.test.ets | 184 + ...UIComponentTextSearchInterface001.test.ets | 1375 ++++ .../UIComponentTextSelectionAction.test.ets | 947 +++ ...UIComponentTextSelectionInterface.test.ets | 263 + ...xtCommonApplicationLevelFontsTest.test.ets | 66 + ...tomKeyBoardIsSupportAvoidanceTest.test.ets | 6003 +++++++++++++++++ .../UiComponentTextCommonEmojiTest.test.ets | 946 +++ ...iComponentTextCommonMenuAvoidTest.test.ets | 1916 ++++++ ...onentTextCommonQuanXuanCaiDanTest.test.ets | 1341 ++++ .../UiComponentTextCommonTextImprove.test.ets | 436 ++ ...omponentTextCommonTextMinFontsize.test.ets | 1321 ++++ .../UiComponentTextCommonTextStyle.test.ets | 888 +++ .../UiComponentTextDecorationTest.test.ets | 2098 ++++++ ...ponentTextInputDeleteCallBackTest.test.ets | 128 + ...iComponentTextInputReplacement001.test.ets | 265 + .../UiComponentTextMirrorTest.test.ets | 417 ++ ...mponentTextRefactorAdjustmentTest.test.ets | 645 ++ ...mponentTextSearchEnterKeyTypeTest.test.ets | 244 + .../src/ohosTest/ets/test/model/Settings.ets | 11 +- .../ohosTest/ets/testability/TestAbility.ets | 26 +- .../UIComponentCommonAttrCom0080.ets | 28 + .../UIComponentCustomSpanInvailDate0110.ets | 99 + ...ponentEditAbleTextThreeReplacement0340.ets | 61 + ...ponentEditAbleTextThreeReplacement0630.ets | 62 + ...ponentEditAbleTextThreeReplacement0730.ets | 74 + ...ponentEditAbleTextThreeReplacement1020.ets | 56 + .../UIComponentTextCopyAttribute0010.ets | 165 + .../UIComponentTextMinFontSize042.ets | 38 + .../UIComponentTextMinFontSize043.ets | 36 + .../UIComponentTextMinFontSize044.ets | 40 + .../UIComponentTextMinFontSize045.ets | 40 + .../UIComponentTextMinFontSize046.ets | 40 + .../UIComponentTextMinFontSize047.ets | 32 + .../UIComponentTextMinFontSize048.ets | 33 + ...UIComponentReverseAnalysisInterface001.ets | 67 + ...UIComponentReverseAnalysisInterface002.ets | 124 + ...mponentSettextselectionReplacement0210.ets | 49 + ...mponentSettextselectionReplacement0220.ets | 39 + ...ntTextAffineTransformationInterface001.ets | 40 + ...tTextAffineTransformationInterface0010.ets | 86 + ...ntTextAffineTransformationInterface002.ets | 46 + ...ntTextAffineTransformationInterface003.ets | 46 + ...ntTextAffineTransformationInterface004.ets | 42 + ...ntTextAffineTransformationInterface005.ets | 56 + ...ntTextAffineTransformationInterface006.ets | 59 + ...ntTextAffineTransformationInterface007.ets | 61 + ...ntTextAffineTransformationInterface008.ets | 67 + ...ntTextAffineTransformationInterface009.ets | 66 + ...IComponentTextCommonHandleInterface001.ets | 117 + ...ComponentTextCommonHandleInterface0010.ets | 96 + ...IComponentTextCommonHandleInterface002.ets | 119 + ...IComponentTextCommonHandleInterface003.ets | 97 + ...IComponentTextCommonHandleInterface004.ets | 102 + ...IComponentTextCommonHandleInterface005.ets | 103 + ...IComponentTextCommonHandleInterface006.ets | 132 + ...IComponentTextCommonHandleInterface007.ets | 72 + ...IComponentTextCommonHandleInterface008.ets | 72 + ...IComponentTextCommonHandleInterface009.ets | 51 + ...IComponentTextCommonSelectionState0010.ets | 154 + ...IComponentTextCommonSelectionState0190.ets | 59 + ...IComponentTextCommonSelectionState0200.ets | 197 + ...IComponentTextCommonSelectionState0210.ets | 40 + ...omponentTextCommonSelectionState0230_1.ets | 122 + ...omponentTextCommonSelectionState0230_2.ets | 113 + ...omponentTextCommonSelectionState0230_3.ets | 117 + ...omponentTextCommonSelectionState0240_1.ets | 55 + ...omponentTextCommonSelectionState0240_2.ets | 53 + ...IComponentTextCommonSelectionState0250.ets | 52 + ...IComponentTextCommonSelectionState0260.ets | 85 + ...ponentTextCopyAttributeReplacement0050.ets | 247 + ...ponentTextCopyAttributeReplacement0060.ets | 247 + ...ponentTextCopyAttributeReplacement0070.ets | 247 + ...ponentTextCopyAttributeReplacement0080.ets | 247 + ...ponentTextCopyAttributeReplacement0090.ets | 247 + ...ponentTextCopyAttributeReplacement0100.ets | 246 + ...ponentTextCopyAttributeReplacement0110.ets | 246 + ...ponentTextCopyAttributeReplacement0120.ets | 247 + ...ponentTextCopyAttributeReplacement0130.ets | 246 + ...ponentTextCopyAttributeReplacement0140.ets | 236 + ...ponentTextCopyAttributeReplacement0150.ets | 246 + ...ponentTextCopyAttributeReplacement0160.ets | 246 + ...ponentTextCopyAttributeReplacement0170.ets | 246 + ...ponentTextCopyAttributeReplacement0180.ets | 246 + ...ponentTextCopyAttributeReplacement0190.ets | 254 + ...ponentTextCopyAttributeReplacement0200.ets | 252 + ...ponentTextCopyAttributeReplacement0210.ets | 254 + ...ponentTextCopyAttributeReplacement0220.ets | 253 + ...ponentTextCopyAttributeReplacement0230.ets | 313 + ...ponentTextCopyAttributeReplacement0240.ets | 312 + ...ponentTextCopyAttributeReplacement0250.ets | 314 + ...ponentTextCopyAttributeReplacement0260.ets | 313 + ...ponentTextCopyAttributeReplacement0270.ets | 313 + ...ponentTextCopyAttributeReplacement0280.ets | 314 + ...ponentTextCopyAttributeReplacement0290.ets | 314 + ...ponentTextCopyAttributeReplacement0300.ets | 315 + ...ponentTextCopyAttributeReplacement0310.ets | 315 + ...ponentTextCopyAttributeReplacement0320.ets | 315 + ...ponentTextCopyAttributeReplacement0330.ets | 315 + ...ponentTextCopyAttributeReplacement0340.ets | 316 + ...ponentTextCopyAttributeReplacement0350.ets | 316 + ...ponentTextCopyAttributeReplacement0360.ets | 320 + ...ponentTextCopyAttributeReplacement0370.ets | 248 + ...ponentTextCopyAttributeReplacement0380.ets | 251 + .../UIComponentTextEditMenuOptions0040.ets | 216 + .../UIComponentTextEditMenuOptions0050.ets | 214 + .../UIComponentTextEditMenuOptions0060.ets | 264 + .../UIComponentTextEditMenuOptions0090.ets | 225 + .../UIComponentTextEditMenuOptions0110.ets | 260 + .../UIComponentTextEditMenuOptions0150.ets | 217 + .../UIComponentTextEditMenuOptions0160.ets | 192 + .../UIComponentTextEditMenuOptions0170.ets | 259 + .../UIComponentTextEditMenuOptions0180.ets | 213 + .../UIComponentTextEditMenuOptions0190.ets | 179 + .../UIComponentTextEditMenuOptions0260.ets | 88 + ...entTextInputDeleteCallbackInterface001.ets | 36 + ...ntTextInputDeleteCallbackInterface0010.ets | 59 + ...ntTextInputDeleteCallbackInterface0011.ets | 68 + ...ntTextInputDeleteCallbackInterface0012.ets | 67 + ...ntTextInputDeleteCallbackInterface0013.ets | 62 + ...ntTextInputDeleteCallbackInterface0014.ets | 69 + ...ntTextInputDeleteCallbackInterface0015.ets | 67 + ...entTextInputDeleteCallbackInterface002.ets | 36 + ...entTextInputDeleteCallbackInterface003.ets | 35 + ...entTextInputDeleteCallbackInterface004.ets | 39 + ...entTextInputDeleteCallbackInterface005.ets | 39 + ...entTextInputDeleteCallbackInterface006.ets | 38 + ...entTextInputDeleteCallbackInterface007.ets | 63 + ...entTextInputDeleteCallbackInterface008.ets | 59 + ...entTextInputDeleteCallbackInterface009.ets | 59 + ...nentTextRefactorAdjustMentInterface001.ets | 32 + ...nentTextRefactorAdjustMentInterface002.ets | 33 + ...nentTextRefactorAdjustMentInterface003.ets | 37 + ...nentTextRefactorAdjustMentInterface004.ets | 126 + ...nentTextRefactorAdjustMentInterface005.ets | 53 + ...nentTextRefactorAdjustMentInterface006.ets | 109 + ...nentTextRefactorAdjustMentInterface007.ets | 131 + ...IComponentTextSearchActionInterface001.ets | 30 + ...IComponentTextSearchActionInterface002.ets | 32 + ...IComponentTextSearchActionInterface003.ets | 47 + .../UIComponentTextSearchInterface001.ets | 35 + .../UIComponentTextSearchInterface0010.ets | 35 + .../UIComponentTextSearchInterface0011.ets | 35 + .../UIComponentTextSearchInterface0012.ets | 29 + .../UIComponentTextSearchInterface0013.ets | 33 + .../UIComponentTextSearchInterface0014.ets | 33 + .../UIComponentTextSearchInterface002.ets | 60 + .../UIComponentTextSearchInterface0020.ets | 31 + .../UIComponentTextSearchInterface003.ets | 45 + .../UIComponentTextSearchInterface0030.ets | 31 + .../UIComponentTextSearchInterface004.ets | 47 + .../UIComponentTextSearchInterface0040.ets | 29 + .../UIComponentTextSearchInterface005.ets | 44 + .../UIComponentTextSearchInterface006.ets | 48 + .../UIComponentTextSearchInterface007.ets | 50 + .../UIComponentTextSearchInterface008.ets | 36 + .../UIComponentTextSearchInterface009.ets | 44 + .../UIComponentTextSearchInterface0370.ets | 32 + .../UIComponentTextSearchInterface0390.ets | 32 + .../UIComponentTextSearchInterface0400.ets | 32 + .../UIComponentTextSearchInterface0410.ets | 32 + .../UIComponentTextSearchInterface0420.ets | 32 + .../UIComponentTextSearchInterface0430.ets | 32 + .../UIComponentTextSearchInterface0530.ets | 31 + ...ponentTextSearchInterface_Interface200.ets | 31 + ...ComponentTextSearchInterface_Symbol020.ets | 38 + ...ComponentTextSearchInterface_Symbol030.ets | 38 + ...ComponentTextSearchInterface_Symbol040.ets | 28 + ...ComponentTextSearchInterface_Symbol050.ets | 33 + ...ComponentTextSearchInterface_Symbol060.ets | 41 + ...ComponentTextSearchInterface_Symbol070.ets | 38 + ...ComponentTextSearchInterface_Symbol080.ets | 38 + .../UIComponentTextSelectionAction0020.ets | 40 + .../UIComponentTextSelectionAction0110.ets | 63 + .../UIComponentTextSelectionAction0120.ets | 65 + .../UIComponentTextSelectionAction0160.ets | 42 + .../UIComponentTextSelectionAction0430.ets | 48 + .../UIComponentTextSelectionAction0630.ets | 51 + .../UIComponentTextSelectionInterface.ets | 114 + .../UIComponentTextSelectionInterface020.ets | 57 + .../UIComponentTextSelectionInterface040.ets | 32 + ...entTextCommonApplicationLevelFonts0010.ets | 117 + ...onCustomKeyBoardIsSupportAvoidance0010.ets | 56 + ...onCustomKeyBoardIsSupportAvoidance0020.ets | 56 + ...onCustomKeyBoardIsSupportAvoidance0030.ets | 102 + ...onCustomKeyBoardIsSupportAvoidance0040.ets | 102 + ...onCustomKeyBoardIsSupportAvoidance0050.ets | 105 + ...onCustomKeyBoardIsSupportAvoidance0060.ets | 105 + ...onCustomKeyBoardIsSupportAvoidance0070.ets | 106 + ...onCustomKeyBoardIsSupportAvoidance0080.ets | 106 + ...onCustomKeyBoardIsSupportAvoidance0090.ets | 106 + ...onCustomKeyBoardIsSupportAvoidance0100.ets | 106 + ...onCustomKeyBoardIsSupportAvoidance0110.ets | 107 + ...onCustomKeyBoardIsSupportAvoidance0120.ets | 107 + ...onCustomKeyBoardIsSupportAvoidance0130.ets | 111 + ...onCustomKeyBoardIsSupportAvoidance0150.ets | 52 + ...onCustomKeyBoardIsSupportAvoidance0160.ets | 154 + ...onCustomKeyBoardIsSupportAvoidance0170.ets | 154 + ...onCustomKeyBoardIsSupportAvoidance0200.ets | 86 + ...onCustomKeyBoardIsSupportAvoidance0210.ets | 85 + ...onCustomKeyBoardIsSupportAvoidance0220.ets | 85 + ...onCustomKeyBoardIsSupportAvoidance0230.ets | 85 + ...onCustomKeyBoardIsSupportAvoidance0240.ets | 85 + ...onCustomKeyBoardIsSupportAvoidance0250.ets | 103 + ...onCustomKeyBoardIsSupportAvoidance0260.ets | 103 + ...onCustomKeyBoardIsSupportAvoidance0270.ets | 103 + ...onCustomKeyBoardIsSupportAvoidance0280.ets | 104 + ...onCustomKeyBoardIsSupportAvoidance0290.ets | 104 + ...onCustomKeyBoardIsSupportAvoidance0300.ets | 104 + ...onCustomKeyBoardIsSupportAvoidance0310.ets | 104 + ...onCustomKeyBoardIsSupportAvoidance0320.ets | 104 + ...onCustomKeyBoardIsSupportAvoidance0330.ets | 104 + ...onCustomKeyBoardIsSupportAvoidance0340.ets | 110 + ...onCustomKeyBoardIsSupportAvoidance0360.ets | 52 + ...onCustomKeyBoardIsSupportAvoidance0370.ets | 171 + ...onCustomKeyBoardIsSupportAvoidance0380.ets | 154 + ...onCustomKeyBoardIsSupportAvoidance0410.ets | 86 + ...onCustomKeyBoardIsSupportAvoidance0420.ets | 87 + ...onCustomKeyBoardIsSupportAvoidance0430.ets | 87 + ...onCustomKeyBoardIsSupportAvoidance0440.ets | 87 + ...onCustomKeyBoardIsSupportAvoidance0450.ets | 103 + ...onCustomKeyBoardIsSupportAvoidance0460.ets | 103 + ...onCustomKeyBoardIsSupportAvoidance0470.ets | 105 + ...onCustomKeyBoardIsSupportAvoidance0480.ets | 105 + ...onCustomKeyBoardIsSupportAvoidance0490.ets | 104 + ...onCustomKeyBoardIsSupportAvoidance0500.ets | 104 + ...onCustomKeyBoardIsSupportAvoidance0510.ets | 104 + ...onCustomKeyBoardIsSupportAvoidance0520.ets | 104 + ...onCustomKeyBoardIsSupportAvoidance0530.ets | 106 + ...onCustomKeyBoardIsSupportAvoidance0540.ets | 106 + ...onCustomKeyBoardIsSupportAvoidance0550.ets | 110 + ...onCustomKeyBoardIsSupportAvoidance0570.ets | 52 + ...onCustomKeyBoardIsSupportAvoidance0580.ets | 99 + ...onCustomKeyBoardIsSupportAvoidance0590.ets | 73 + ...onCustomKeyBoardIsSupportAvoidance0600.ets | 71 + ...onCustomKeyBoardIsSupportAvoidance0610.ets | 155 + ...onCustomKeyBoardIsSupportAvoidance0620.ets | 155 + ...onCustomKeyBoardIsSupportAvoidance0650.ets | 86 + ...onCustomKeyBoardIsSupportAvoidance0660.ets | 85 + .../UiComponentTextCommonEmoji0010.ets | 33 + .../UiComponentTextCommonEmoji0020.ets | 33 + .../UiComponentTextCommonEmoji0030.ets | 31 + .../UiComponentTextCommonEmoji0040.ets | 31 + .../UiComponentTextCommonEmoji0050.ets | 36 + .../UiComponentTextCommonEmoji0060.ets | 48 + .../UiComponentTextCommonEmoji0070.ets | 48 + .../UiComponentTextCommonEmoji0080.ets | 50 + .../UiComponentTextCommonEmoji0090.ets | 31 + .../UiComponentTextCommonEmoji0100.ets | 36 + .../UiComponentTextCommonEmoji0110.ets | 38 + .../UiComponentTextCommonEmoji0120.ets | 38 + .../UiComponentTextCommonEmoji0140.ets | 50 + .../UiComponentTextCommonEmoji0150.ets | 31 + .../UiComponentTextCommonEmoji0160.ets | 36 + .../UiComponentTextCommonEmoji0180.ets | 34 + .../UiComponentTextCommonEmoji0200.ets | 31 + .../UiComponentTextCommonEmoji0210.ets | 31 + .../UiComponentTextCommonEmoji0220.ets | 34 + .../UiComponentTextCommonEmoji0230.ets | 26 + .../UiComponentTextCommonEmoji0240.ets | 26 + .../UiComponentTextCommonEmoji0250.ets | 60 + .../UiComponentTextCommonEmoji0270.ets | 50 + .../UiComponentTextCommonMenuAvoid0010.ets | 30 + .../UiComponentTextCommonMenuAvoid0020.ets | 27 + .../UiComponentTextCommonMenuAvoid0030.ets | 34 + .../UiComponentTextCommonMenuAvoid0040.ets | 30 + .../UiComponentTextCommonMenuAvoid0050.ets | 27 + .../UiComponentTextCommonMenuAvoid0060.ets | 27 + .../UiComponentTextCommonMenuAvoid0070.ets | 34 + .../UiComponentTextCommonMenuAvoid0080.ets | 33 + .../UiComponentTextCommonMenuAvoid0090.ets | 33 + .../UiComponentTextCommonMenuAvoid0100.ets | 32 + .../UiComponentTextCommonMenuAvoid0110.ets | 32 + .../UiComponentTextCommonMenuAvoid0120.ets | 34 + .../UiComponentTextCommonMenuAvoid0130.ets | 30 + .../UiComponentTextCommonMenuAvoid0140.ets | 27 + .../UiComponentTextCommonMenuAvoid0150.ets | 40 + .../UiComponentTextCommonMenuAvoid0160.ets | 31 + .../UiComponentTextCommonMenuAvoid0170.ets | 28 + .../UiComponentTextCommonMenuAvoid0180.ets | 28 + .../UiComponentTextCommonMenuAvoid0190.ets | 31 + .../UiComponentTextCommonMenuAvoid0200.ets | 32 + .../UiComponentTextCommonMenuAvoid0210.ets | 32 + .../UiComponentTextCommonMenuAvoid0220.ets | 31 + .../UiComponentTextCommonMenuAvoid0230.ets | 31 + .../UiComponentTextCommonMenuAvoid0250.ets | 31 + .../UiComponentTextCommonMenuAvoid0260.ets | 49 + .../UiComponentTextCommonMenuAvoid0270.ets | 68 + .../UiComponentTextCommonMenuAvoid0280.ets | 43 + .../UiComponentTextCommonMenuAvoid0290.ets | 42 + .../UiComponentTextCommonMenuAvoid0300.ets | 42 + .../UiComponentTextCommonMenuAvoid0310.ets | 34 + .../UiComponentTextCommonMenuAvoid0320.ets | 32 + .../UiComponentTextCommonMenuAvoid0330.ets | 42 + .../UiComponentTextCommonMenuAvoid0340.ets | 31 + .../UiComponentTextCommonMenuAvoid0350.ets | 42 + .../UiComponentTextCommonMenuAvoid0360.ets | 49 + .../UiComponentTextCommonMenuAvoid0370.ets | 68 + .../UiComponentTextCommonMenuAvoid0380.ets | 43 + .../UiComponentTextCommonMenuAvoid0390.ets | 42 + .../UiComponentTextCommonMenuAvoid0400.ets | 42 + .../UiComponentTextCommonMenuAvoid0410.ets | 42 + .../UiComponentTextCommonMenuAvoid0420.ets | 48 + .../UiComponentTextCommonMenuAvoid0430.ets | 67 + .../UiComponentTextCommonMenuAvoid0440.ets | 42 + .../UiComponentTextCommonMenuAvoid0450.ets | 44 + .../UiComponentTextCommonMenuAvoid0460.ets | 42 + .../UiComponentTextCommonMenuAvoid0470.ets | 42 + .../UiComponentTextCommonMenuAvoid0480.ets | 38 + .../UiComponentTextCommonMenuAvoid0490.ets | 50 + .../UiComponentTextCommonMenuAvoid0500.ets | 41 + .../UiComponentTextCommonMenuAvoid0510.ets | 42 + .../UiComponentTextCommonMenuAvoid0520.ets | 62 + .../UiComponentTextCommonMenuAvoid0530.ets | 48 + .../UiComponentTextCommonMenuAvoid0540.ets | 39 + ...iComponentTextCommonQuanXuanCaiDan0010.ets | 33 + ...iComponentTextCommonQuanXuanCaiDan0020.ets | 30 + ...iComponentTextCommonQuanXuanCaiDan0030.ets | 32 + ...iComponentTextCommonQuanXuanCaiDan0040.ets | 32 + ...iComponentTextCommonQuanXuanCaiDan0050.ets | 36 + ...iComponentTextCommonQuanXuanCaiDan0060.ets | 36 + ...iComponentTextCommonQuanXuanCaiDan0070.ets | 33 + ...iComponentTextCommonQuanXuanCaiDan0080.ets | 34 + ...iComponentTextCommonQuanXuanCaiDan0090.ets | 36 + ...iComponentTextCommonQuanXuanCaiDan0100.ets | 36 + ...iComponentTextCommonQuanXuanCaiDan0110.ets | 32 + ...iComponentTextCommonQuanXuanCaiDan0120.ets | 30 + ...iComponentTextCommonQuanXuanCaiDan0130.ets | 37 + ...iComponentTextCommonQuanXuanCaiDan0140.ets | 36 + ...iComponentTextCommonQuanXuanCaiDan0150.ets | 33 + ...iComponentTextCommonQuanXuanCaiDan0160.ets | 34 + ...iComponentTextCommonQuanXuanCaiDan0170.ets | 33 + ...iComponentTextCommonQuanXuanCaiDan0180.ets | 34 + ...iComponentTextCommonQuanXuanCaiDan0190.ets | 35 + ...iComponentTextCommonQuanXuanCaiDan0200.ets | 31 + ...iComponentTextCommonQuanXuanCaiDan0210.ets | 35 + ...iComponentTextCommonQuanXuanCaiDan0220.ets | 35 + ...iComponentTextCommonQuanXuanCaiDan0230.ets | 32 + ...iComponentTextCommonQuanXuanCaiDan0240.ets | 33 + ...iComponentTextCommonQuanXuanCaiDan0250.ets | 36 + ...iComponentTextCommonQuanXuanCaiDan0260.ets | 33 + ...iComponentTextCommonQuanXuanCaiDan0270.ets | 30 + ...iComponentTextCommonQuanXuanCaiDan0280.ets | 30 + ...iComponentTextCommonQuanXuanCaiDan0290.ets | 33 + ...iComponentTextCommonQuanXuanCaiDan0300.ets | 33 + ...iComponentTextCommonQuanXuanCaiDan0310.ets | 30 + ...iComponentTextCommonQuanXuanCaiDan0320.ets | 30 + ...iComponentTextCommonQuanXuanCaiDan0330.ets | 64 + ...iComponentTextCommonQuanXuanCaiDan0340.ets | 64 + ...iComponentTextCommonQuanXuanCaiDan0350.ets | 64 + ...iComponentTextCommonQuanXuanCaiDan0360.ets | 64 + ...iComponentTextCommonQuanXuanCaiDan0370.ets | 40 + ...iComponentTextCommonQuanXuanCaiDan0380.ets | 39 + ...iComponentTextCommonQuanXuanCaiDan0390.ets | 46 + ...iComponentTextCommonQuanXuanCaiDan0400.ets | 48 + ...iComponentTextCommonQuanXuanCaiDan0410.ets | 64 + .../UiComponentTextCommonTextImprove0010.ets | 30 + .../UiComponentTextCommonTextImprove0020.ets | 31 + .../UiComponentTextCommonTextImprove0030.ets | 30 + .../UiComponentTextCommonTextImprove0040.ets | 30 + .../UiComponentTextCommonTextImprove0050.ets | 31 + .../UiComponentTextCommonTextImprove0060.ets | 31 + .../UiComponentTextCommonTextImprove0070.ets | 30 + .../UiComponentTextCommonTextImprove0080.ets | 30 + .../UiComponentTextCommonTextImprove0090.ets | 31 + .../UiComponentTextCommonTextImprove0100.ets | 31 + .../UiComponentTextCommonTextImprove0110.ets | 31 + .../UiComponentTextCommonTextImprove0120.ets | 30 + .../UiComponentTextCommonTextImprove0130.ets | 30 + .../UiComponentTextCommonTextImprove0140.ets | 32 + .../UiComponentTextCommonTextImprove0150.ets | 51 + .../UiComponentTextCommonTextImprove0160.ets | 29 + .../UiComponentTextCommonTextImprove0170.ets | 30 + .../UiComponentTextCommonTextImprove0180.ets | 30 + ...iComponentTextCommonTextMinFontSize008.ets | 33 + ...iComponentTextCommonTextMinFontSize009.ets | 33 + ...iComponentTextCommonTextMinFontSize010.ets | 33 + ...iComponentTextCommonTextMinFontSize011.ets | 46 + ...iComponentTextCommonTextMinFontSize012.ets | 69 + ...iComponentTextCommonTextMinFontSize013.ets | 56 + ...iComponentTextCommonTextMinFontSize014.ets | 65 + ...iComponentTextCommonTextMinFontSize015.ets | 49 + ...iComponentTextCommonTextMinFontSize016.ets | 60 + ...iComponentTextCommonTextMinFontSize017.ets | 34 + ...iComponentTextCommonTextMinFontSize018.ets | 50 + ...iComponentTextCommonTextMinFontSize019.ets | 50 + ...iComponentTextCommonTextMinFontSize020.ets | 75 + ...iComponentTextCommonTextMinFontSize021.ets | 47 + ...iComponentTextCommonTextMinFontSize022.ets | 41 + ...iComponentTextCommonTextMinFontSize023.ets | 43 + ...iComponentTextCommonTextMinFontSize024.ets | 42 + ...iComponentTextCommonTextMinFontSize025.ets | 42 + ...iComponentTextCommonTextMinFontSize026.ets | 46 + ...iComponentTextCommonTextMinFontSize027.ets | 68 + ...iComponentTextCommonTextMinFontSize028.ets | 56 + ...iComponentTextCommonTextMinFontSize029.ets | 65 + ...iComponentTextCommonTextMinFontSize030.ets | 47 + ...iComponentTextCommonTextMinFontSize031.ets | 49 + ...iComponentTextCommonTextMinFontSize032.ets | 60 + ...iComponentTextCommonTextMinFontSize033.ets | 38 + ...iComponentTextCommonTextMinFontSize034.ets | 48 + ...iComponentTextCommonTextMinFontSize035.ets | 48 + ...iComponentTextCommonTextMinFontSize036.ets | 57 + ...iComponentTextCommonTextMinFontSize037.ets | 71 + ...iComponentTextCommonTextMinFontSize038.ets | 64 + .../UiComponentTextCommonTextStyle0210.ets | 31 + .../UiComponentTextCommonTextStyle0220.ets | 31 + .../UiComponentTextCommonTextStyle0320.ets | 30 + .../UiComponentTextCommonTextStyle0330.ets | 30 + .../UiComponentTextCommonTextStyle0340.ets | 30 + .../UiComponentTextCommonTextStyle0350.ets | 30 + .../UiComponentTextCommonTextStyle0360.ets | 30 + .../UiComponentTextCommonTextStyle0730.ets | 29 + .../UiComponentTextCommonTextStyle0740.ets | 30 + .../UiComponentTextCommonTextStyle0750.ets | 30 + .../UiComponentTextCommonTextStyle0760.ets | 30 + .../UiComponentTextCommonTextStyle0770.ets | 29 + .../UiComponentTextCommonTextStyle0780.ets | 29 + .../UiComponentTextCommonTextStyle0790.ets | 30 + .../UiComponentTextCommonTextStyle0800.ets | 30 + .../UiComponentTextCommonTextStyle0810.ets | 30 + .../UiComponentTextCommonTextStyle0820.ets | 31 + .../UiComponentTextCommonTextStyle0830.ets | 30 + .../UiComponentTextCommonTextStyle0840.ets | 30 + .../UiComponentTextCommonTextStyle1150.ets | 30 + .../UiComponentTextCommonTextStyle1160.ets | 30 + .../UiComponentTextCommonTextStyle1170.ets | 30 + .../UiComponentTextCommonTextStyle1450.ets | 29 + .../UiComponentTextCommonTextStyle1460.ets | 29 + .../UiComponentTextCommonTextStyle1470.ets | 29 + .../UiComponentTextCommonTextStyle1850.ets | 29 + .../UiComponentTextCommonTextStyle1860.ets | 29 + .../UiComponentTextCommonTextStyle1870.ets | 29 + .../UiComponentTextCommonTextStyle1880.ets | 30 + .../UiComponentTextCommonTextStyle1890.ets | 30 + .../UiComponentTextCommonTextStyle1910.ets | 35 + .../UiComponentTextCommonTextStyle1920.ets | 35 + .../UiComponentTextCommonTextStyle1930.ets | 35 + .../UiComponentTextCommonTextStyle1940.ets | 34 + .../UiComponentTextCommonTextStyle2040.ets | 35 + .../UiComponentTextCommonTextStyle2050.ets | 30 + .../UiComponentTextCommonTextStyle2060.ets | 30 + .../UiComponentTextCommonTextStyle2070.ets | 30 + .../UiComponentTextCommonTextStyle2120.ets | 42 + .../UiComponentTextCommonTextStyle2130.ets | 42 + .../UiComponentTextCommonTextStyle2140.ets | 42 + .../UiComponentTextDecoration0010.ets | 75 + .../UiComponentTextDecoration0020.ets | 79 + .../UiComponentTextDecoration0030.ets | 79 + .../UiComponentTextDecoration0040.ets | 79 + .../UiComponentTextDecoration0050.ets | 79 + .../UiComponentTextDecoration0060.ets | 79 + .../UiComponentTextDecoration0070.ets | 81 + .../UiComponentTextDecoration0080.ets | 42 + .../UiComponentTextDecoration0090.ets | 80 + .../UiComponentTextDecoration0100.ets | 84 + .../UiComponentTextDecoration0110.ets | 84 + .../UiComponentTextDecoration0120.ets | 84 + .../UiComponentTextDecoration0130.ets | 84 + .../UiComponentTextDecoration0140.ets | 84 + .../UiComponentTextDecoration0150.ets | 80 + .../UiComponentTextDecoration0160.ets | 44 + .../UiComponentTextDecoration0170.ets | 96 + .../UiComponentTextDecoration0180.ets | 105 + .../UiComponentTextDecoration0190.ets | 105 + .../UiComponentTextDecoration0200.ets | 105 + .../UiComponentTextDecoration0210.ets | 105 + .../UiComponentTextDecoration0220.ets | 105 + .../UiComponentTextDecoration0230.ets | 105 + .../UiComponentTextDecoration0240.ets | 51 + .../UiComponentTextDecoration0250.ets | 70 + .../UiComponentTextDecoration0260.ets | 53 + .../UiComponentTextDecoration0270.ets | 58 + .../UiComponentTextDecoration0280.ets | 52 + .../UiComponentTextDecoration0290.ets | 56 + .../UiComponentTextDecoration0300.ets | 63 + .../UiComponentTextDecoration0310.ets | 56 + .../UiComponentTextDecoration0320.ets | 54 + .../UiComponentTextDecoration0330.ets | 66 + .../UiComponentTextDecoration0360.ets | 84 + .../UiComponentTextDecoration0380.ets | 85 + .../UiComponentTextDecoration0390.ets | 87 + .../UiComponentTextDecoration0400.ets | 87 + .../UiComponentTextDecoration0410.ets | 87 + .../UiComponentTextDecoration0420.ets | 87 + .../UiComponentTextDecoration0430.ets | 87 + .../UiComponentTextDecoration0440.ets | 89 + .../UiComponentTextDecoration0450.ets | 44 + .../UiComponentTextDecoration0460.ets | 60 + .../UiComponentTextDecoration0470.ets | 48 + .../UiComponentTextDecoration0480.ets | 58 + .../UiComponentTextDecoration0490.ets | 45 + .../UiComponentTextDecoration0500.ets | 85 + .../UiComponentTextDecoration0510.ets | 88 + .../UiComponentTextDecoration0520.ets | 87 + .../UiComponentTextDecoration0530.ets | 87 + .../UiComponentTextDecoration0540.ets | 87 + .../UiComponentTextDecoration0550.ets | 87 + .../UiComponentTextDecoration0560.ets | 89 + .../UiComponentTextDecoration0570.ets | 44 + .../UiComponentTextDecoration0580.ets | 60 + .../UiComponentTextDecoration0600.ets | 58 + .../UiComponentTextDecoration0610.ets | 83 + .../UiComponentTextDecoration0620.ets | 88 + .../UiComponentTextDecoration0630.ets | 88 + .../UiComponentTextDecoration0640.ets | 88 + .../UiComponentTextDecoration0650.ets | 87 + .../UiComponentTextDecoration0660.ets | 87 + .../UiComponentTextDecoration0670.ets | 89 + .../UiComponentTextDecoration0680.ets | 44 + .../UiComponentTextDecoration0690.ets | 60 + .../UiComponentTextDecoration0710.ets | 58 + .../UiComponentTextDecoration0720.ets | 45 + .../UiComponentTextEditMeauOptions0030.ets | 73 + ...UiComponentTextInputDeleteCallBack0010.ets | 54 + ...UiComponentTextInputDeleteCallBack0020.ets | 54 + ...UiComponentTextInputDeleteCallBack0030.ets | 58 + .../UiComponentTextInputReplacement0010.ets | 100 + .../UiComponentTextInputReplacement0020.ets | 82 + .../UiComponentTextInputReplacement0030.ets | 73 + .../UiComponentTextInputReplacement0040.ets | 97 + .../UiComponentTextInputReplacement0050.ets | 112 + .../UiComponentTextInputReplacement0060.ets | 106 + .../UiComponentTextInputReplacement0070.ets | 102 + .../UiComponentTextInputReplacement0080.ets | 102 + .../UiComponentTextInputReplacement0090.ets | 120 + .../UiComponentTextMirror0010.ets | 48 + .../UiComponentTextMirror0040.ets | 51 + .../UiComponentTextMirror0050.ets | 51 + .../UiComponentTextMirror0060.ets | 51 + .../UiComponentTextMirror0070.ets | 51 + .../UiComponentTextMirror0080.ets | 58 + .../UiComponentTextMirror0090.ets | 82 + .../UiComponentTextMirror0100.ets | 52 + .../UiComponentTextMirror0110.ets | 93 + .../UiComponentTextMirror0120.ets | 51 + .../UiComponentTextMirror0130.ets | 93 + .../UiComponentTextMirror0140.ets | 61 + .../UiComponentTextMirror0150.ets | 66 + .../UiComponentTextMirror0160.ets | 78 + .../UiComponentTextMirror0170.ets | 72 + .../UiComponentTextMirror0180.ets | 81 + .../UiComponentTextMirror0190.ets | 51 + .../UiComponentTextMirror0200.ets | 75 + .../UiComponentTextRefactorAdjustment0020.ets | 27 + .../UiComponentTextRefactorAdjustment0050.ets | 29 + .../UiComponentTextRefactorAdjustment0110.ets | 34 + .../UiComponentTextRefactorAdjustment0120.ets | 29 + .../UiComponentTextRefactorAdjustment0130.ets | 36 + .../UiComponentTextRefactorAdjustment0140.ets | 29 + .../UiComponentTextRefactorAdjustment0160.ets | 28 + .../UiComponentTextRefactorAdjustment0170.ets | 35 + .../UiComponentTextRefactorAdjustment0190.ets | 37 + .../UiComponentTextRefactorAdjustment0230.ets | 30 + .../UiComponentTextRefactorAdjustment0260.ets | 35 + .../UiComponentTextRefactorAdjustment0270.ets | 38 + .../UiComponentTextRefactorAdjustment0280.ets | 34 + .../UiComponentTextRefactorAdjustment0290.ets | 34 + .../UiComponentTextRefactorAdjustment0300.ets | 33 + .../UiComponentTextRefactorAdjustment0310.ets | 44 + .../UiComponentTextRefactorAdjustment0320.ets | 44 + .../UiComponentTextRefactorAdjustment0330.ets | 37 + .../UiComponentTextRefactorAdjustment0340.ets | 37 + .../UiComponentTextRefactorAdjustment0350.ets | 37 + .../UiComponentTextRefactorAdjustment0360.ets | 44 + .../UiComponentTextRefactorAdjustment0370.ets | 33 + .../UiComponentTextRefactorAdjustment0380.ets | 33 + .../UiComponentTextRefactorAdjustment0420.ets | 32 + .../UiComponentTextRefactorAdjustment0440.ets | 31 + .../UiComponentTextRefactorAdjustment0450.ets | 32 + .../UiComponentTextSearchEnterKeyType0010.ets | 31 + .../UiComponentTextSearchEnterKeyType0020.ets | 31 + .../UiComponentTextSearchEnterKeyType0030.ets | 31 + .../UiComponentTextSearchEnterKeyType0040.ets | 31 + .../UiComponentTextSearchEnterKeyType0050.ets | 31 + .../UiComponentTextSearchEnterKeyType0060.ets | 31 + .../UiComponentTextSearchEnterKeyType0070.ets | 31 + .../UiComponentTextSearchEnterKeyType0080.ets | 31 + .../UiComponentTextSearchEnterKeyType0090.ets | 31 + .../UiComponentTextSearchEnterKeyType0100.ets | 31 + .../resources/containerspan_click_error.png | Bin 0 -> 15905 bytes .../resources/containerspan_height_error.png | Bin 0 -> 37232 bytes .../resources/containerspan_width_error.png | Bin 0 -> 35731 bytes .../resources/span_null_param_error.png | Bin 0 -> 16861 bytes .../uicompare/entry/src/ohosTest/module.json5 | 24 + .../resources/base/element/string.json | 4 + .../resources/base/profile/test_pages.json | 574 +- .../uicompare/hvigor/hvigor-wrapper.js | 1 + .../uicompare/oh-package-lock.json5 | 15 + .../UiCompareTools_progress.py | 1 + .../excel/UiComponentTextCommonEmojiTest.xlsx | Bin 0 -> 11137 bytes ...ComponentTextCommonQuanXuanCaiDanTest.xlsx | Bin 0 -> 11357 bytes .../UiComponentTextCommonTextImproveTest.xlsx | Bin 0 -> 11105 bytes ...omponentTextCommonTextMinFontsizeTest.xlsx | Bin 0 -> 11256 bytes .../UiComponentTextCommonTextStyleTest.xlsx | Bin 0 -> 11330 bytes .../excel/UiComponentTextDecorationTest.xlsx | Bin 0 -> 11573 bytes .../UiComponentTextEditMeauOptionsTest.xlsx | Bin 0 -> 10847 bytes ...iComponentTextInputDeleteCallBackTest.xlsx | Bin 0 -> 10902 bytes .../excel/UiComponentTextMirrorTest.xlsx | Bin 0 -> 11100 bytes ...UiComponentTextRefactorAdjustmentTest.xlsx | Bin 0 -> 11000 bytes ...UiComponentTextSearchEnterKeyTypeTest.xlsx | Bin 0 -> 10682 bytes .../ui_compare_rh/uicompare_tools/run.bat | 6 +- 612 files changed, 66420 insertions(+), 19 deletions(-) create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentEditAbleTextThreeReplacementTest/UIComponentEditAbleTextThreeReplacement001.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentReverseAnalysisInterfaceTest/UIComponentReverseAnalysisInterface001.test.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextAffineTransformationInterfaceTest/UIComponentTextAffineTransformationInterface001.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextCommonHandleInterfaceTest/UIComponentTextCommonHandleInterface001.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextCommonSelectionStateTest/UIComponentTextCommonSelectionState.test.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextEditMenuOptionsTest/UIComponentTextEditMenuOptions.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextInputDeleteCallbackInterfaceTest/UIComponentTextInputDeleteCallbackInterface001.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextRefactorAdjustMentInterfaceTest/UIComponentTextRefactorAdjustMentInterface001.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSearchActionInterfaceTest/UIComponentTextSearchActionInterface001.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSearchInterfaceTest/UIComponentTextSearchInterface001.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSelectionActionTest/UIComponentTextSelectionAction.test.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSelectionInterfaceTest/UIComponentTextSelectionInterface.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonApplicationLevelFontsTest/UiComponentTextCommonApplicationLevelFontsTest.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonCustomKeyBoardIsSupportAvoidanceTest/UiComponentTextCommonCustomKeyBoardIsSupportAvoidanceTest.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonEmojiTest/UiComponentTextCommonEmojiTest.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonMenuAvoidTest/UiComponentTextCommonMenuAvoidTest.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonQuanXuanCaiDanTest/UiComponentTextCommonQuanXuanCaiDanTest.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonTextImproveTest/UiComponentTextCommonTextImprove.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonTextMinFontsizeTest/UiComponentTextCommonTextMinFontsize.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonTextStyleTest/UiComponentTextCommonTextStyle.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextDecorationTest/UiComponentTextDecorationTest.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextInputDeleteCallBackTest/UiComponentTextInputDeleteCallBackTest.test.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextInputReplacementTest/UiComponentTextInputReplacement001.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextMirrorTest/UiComponentTextMirrorTest.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextRefactorAdjustmentTest/UiComponentTextRefactorAdjustmentTest.test.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextSearchEnterKeyTypeTest/UiComponentTextSearchEnterKeyTypeTest.test.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentCommonAttrCom0080.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentCustomSpanInvailDate0110.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0340.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0630.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0730.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement1020.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextCopyAttribute0010.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize042.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize043.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize044.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize045.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize046.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize047.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize048.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentReverseAnalysisInterface/UIComponentReverseAnalysisInterface001.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentReverseAnalysisInterface/UIComponentReverseAnalysisInterface002.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement0210.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement0220.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface001.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface0010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface002.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface003.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface004.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface005.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface006.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface007.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface008.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface009.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface001.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface0010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface002.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface003.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface004.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface005.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface006.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface007.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface008.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface009.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0190.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0200.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0210.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_1.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_2.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_3.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0240_1.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0240_2.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0250.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0260.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0050.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0060.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0070.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0080.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0090.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0100.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0110.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0120.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0130.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0140.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0150.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0160.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0170.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0180.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0190.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0200.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0210.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0220.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0230.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0240.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0250.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0260.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0270.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0280.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0290.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0300.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0310.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0320.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0330.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0340.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0350.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0360.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0370.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0380.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0040.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0050.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0060.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0090.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0110.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0150.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0160.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0170.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0180.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0190.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0260.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface001.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0011.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0012.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0013.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0014.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0015.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface002.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface003.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface004.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface005.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface006.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface007.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface008.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface009.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface001.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface002.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface003.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface004.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface005.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface006.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface007.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface001.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface002.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface003.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface001.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0011.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0012.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0013.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0014.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface002.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0020.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface003.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0030.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface004.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0040.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface005.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface006.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface007.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface008.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface009.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0370.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0390.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0400.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0410.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0420.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0430.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0530.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Interface200.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol020.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol030.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol040.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol050.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol060.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol070.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol080.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0110.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0120.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0160.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0430.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0630.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface020.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface040.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonApplicationLevelFonts/UiComponentTextCommonApplicationLevelFonts0010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0020.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0030.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0040.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0050.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0060.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0070.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0080.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0090.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0100.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0110.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0120.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0130.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0150.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0160.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0170.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0200.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0210.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0220.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0230.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0240.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0250.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0260.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0270.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0280.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0290.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0300.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0310.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0320.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0330.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0340.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0360.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0370.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0380.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0410.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0420.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0430.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0440.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0450.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0460.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0470.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0480.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0490.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0500.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0510.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0520.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0530.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0540.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0550.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0570.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0580.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0590.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0600.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0610.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0620.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0650.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0660.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0020.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0030.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0040.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0050.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0060.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0070.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0080.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0090.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0100.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0110.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0120.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0140.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0150.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0160.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0180.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0200.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0210.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0220.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0230.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0240.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0250.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0270.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0020.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0030.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0040.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0050.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0060.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0070.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0080.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0090.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0100.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0110.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0120.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0130.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0140.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0150.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0160.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0170.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0180.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0190.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0200.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0210.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0220.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0230.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0250.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0260.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0270.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0280.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0290.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0300.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0310.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0320.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0330.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0340.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0350.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0360.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0370.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0380.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0390.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0400.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0410.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0420.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0430.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0440.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0450.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0460.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0470.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0480.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0490.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0500.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0510.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0520.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0530.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0540.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0020.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0030.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0040.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0050.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0060.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0070.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0080.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0090.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0100.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0110.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0120.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0130.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0140.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0150.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0160.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0170.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0180.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0190.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0200.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0210.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0220.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0230.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0240.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0250.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0260.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0270.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0280.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0290.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0300.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0310.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0320.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0330.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0340.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0350.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0360.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0370.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0380.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0390.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0400.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0410.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0020.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0030.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0040.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0050.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0060.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0070.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0080.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0090.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0100.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0110.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0120.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0130.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0140.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0150.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0160.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0170.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0180.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize008.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize009.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize011.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize012.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize013.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize014.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize015.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize016.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize017.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize018.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize019.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize020.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize021.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize022.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize023.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize024.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize025.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize026.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize027.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize028.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize029.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize030.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize031.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize032.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize033.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize034.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize035.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize036.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize037.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize038.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0210.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0220.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0320.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0330.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0340.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0350.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0360.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0730.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0740.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0750.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0760.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0770.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0780.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0790.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0800.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0810.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0820.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0830.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0840.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1150.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1160.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1170.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1450.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1460.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1470.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1850.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1860.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1870.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1880.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1890.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1910.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1920.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1930.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1940.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2040.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2050.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2060.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2070.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2120.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2130.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2140.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0020.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0030.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0040.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0050.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0060.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0070.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0080.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0090.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0100.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0110.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0120.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0130.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0140.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0150.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0160.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0170.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0180.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0190.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0200.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0210.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0220.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0230.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0240.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0250.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0260.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0270.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0280.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0290.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0300.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0310.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0320.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0330.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0360.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0380.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0390.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0400.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0410.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0420.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0430.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0440.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0450.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0460.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0470.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0480.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0490.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0500.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0510.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0520.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0530.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0540.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0550.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0560.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0570.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0580.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0600.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0610.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0620.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0630.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0640.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0650.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0660.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0670.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0680.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0690.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0710.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0720.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextEditMeauOptions/UiComponentTextEditMeauOptions0030.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0020.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0030.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0010.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0020.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0030.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0040.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0050.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0060.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0070.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0080.ets create mode 100755 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0090.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0040.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0050.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0060.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0070.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0080.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0090.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0100.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0110.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0120.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0130.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0140.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0150.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0160.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0170.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0180.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0190.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0200.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0020.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0050.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0110.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0120.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0130.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0140.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0160.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0170.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0190.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0230.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0260.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0270.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0280.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0290.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0300.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0310.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0320.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0330.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0340.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0350.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0360.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0370.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0380.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0420.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0440.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0450.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0010.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0020.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0030.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0040.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0050.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0060.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0070.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0080.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0090.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0100.ets create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/resources/containerspan_click_error.png create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/resources/containerspan_height_error.png create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/resources/containerspan_width_error.png create mode 100644 function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/resources/span_null_param_error.png create mode 100644 function/ui_compare_rh/uicompare/hvigor/hvigor-wrapper.js create mode 100644 function/ui_compare_rh/uicompare/oh-package-lock.json5 create mode 100644 function/ui_compare_rh/uicompare_tools/excel/UiComponentTextCommonEmojiTest.xlsx create mode 100644 function/ui_compare_rh/uicompare_tools/excel/UiComponentTextCommonQuanXuanCaiDanTest.xlsx create mode 100644 function/ui_compare_rh/uicompare_tools/excel/UiComponentTextCommonTextImproveTest.xlsx create mode 100644 function/ui_compare_rh/uicompare_tools/excel/UiComponentTextCommonTextMinFontsizeTest.xlsx create mode 100644 function/ui_compare_rh/uicompare_tools/excel/UiComponentTextCommonTextStyleTest.xlsx create mode 100644 function/ui_compare_rh/uicompare_tools/excel/UiComponentTextDecorationTest.xlsx create mode 100644 function/ui_compare_rh/uicompare_tools/excel/UiComponentTextEditMeauOptionsTest.xlsx create mode 100644 function/ui_compare_rh/uicompare_tools/excel/UiComponentTextInputDeleteCallBackTest.xlsx create mode 100644 function/ui_compare_rh/uicompare_tools/excel/UiComponentTextMirrorTest.xlsx create mode 100644 function/ui_compare_rh/uicompare_tools/excel/UiComponentTextRefactorAdjustmentTest.xlsx create mode 100644 function/ui_compare_rh/uicompare_tools/excel/UiComponentTextSearchEnterKeyTypeTest.xlsx diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/List.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/List.test.ets index 0860e123..9ffae012 100644 --- a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/List.test.ets +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/List.test.ets @@ -12,6 +12,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ +<<<<<<< HEAD import ComponentTextRicheditorFontfeatures from './ComponentTextRicheditorFontfeatureTest/ComponentTextRicheditorFontfeatures.test'; @@ -149,6 +150,57 @@ import UIComponentPopupBoxToastStyleInterface001 from './UIComponentPopupBoxToastStyleInterfaceTest/UIComponentPopupBoxToastStyleInterface001.test'; import UIComponentPopupBoxFullDialogInterface001 from './UIComponentPopupBoxFullDialogInterfaceTest/UIComponentPopupBoxFullDialogInterface001.test'; +import UiComponentTextCommonEmojiTest from "./UiComponentTextCommonEmojiTest/UiComponentTextCommonEmojiTest.test"; +import UiComponentTextCommonQuanXuanCaiDanTest + from "./UiComponentTextCommonQuanXuanCaiDanTest/UiComponentTextCommonQuanXuanCaiDanTest.test"; +import UiComponentTextCommonTextImprove + from "./UiComponentTextCommonTextImproveTest/UiComponentTextCommonTextImprove.test"; +import UiComponentTextCommonTextMinFontsize + from "./UiComponentTextCommonTextMinFontsizeTest/UiComponentTextCommonTextMinFontsize.test"; +import UiComponentTextCommonTextStyleTest + from "./UiComponentTextCommonTextStyleTest/UiComponentTextCommonTextStyle.test"; +import UiComponentTextDecorationTest from "./UiComponentTextDecorationTest/UiComponentTextDecorationTest.test"; +import UiComponentTextInputDeleteCallBackTest + from "./UiComponentTextInputDeleteCallBackTest/UiComponentTextInputDeleteCallBackTest.test"; +import UiComponentTextMirrorTest from "./UiComponentTextMirrorTest/UiComponentTextMirrorTest.test"; +import UiComponentTextRefactorAdjustmentTest + from "./UiComponentTextRefactorAdjustmentTest/UiComponentTextRefactorAdjustmentTest.test"; +import UiComponentTextSearchEnterKeyTypeTest + from "./UiComponentTextSearchEnterKeyTypeTest/UiComponentTextSearchEnterKeyTypeTest.test"; +import UIComponentTextSearchInterface001 + from './UIComponentTextSearchInterfaceTest/UIComponentTextSearchInterface001.test'; +import UIComponentTextSearchActionInterface001 + from './UIComponentTextSearchActionInterfaceTest/UIComponentTextSearchActionInterface001.test'; +import UIComponentTextInputDeleteCallbackInterface001 + from './UIComponentTextInputDeleteCallbackInterfaceTest/UIComponentTextInputDeleteCallbackInterface001.test'; +import UIComponentTextRefactorAdjustMentInterface001 + from './UIComponentTextRefactorAdjustMentInterfaceTest/UIComponentTextRefactorAdjustMentInterface001.test'; +import UIComponentTextSelectionAction from './UIComponentTextSelectionActionTest/UIComponentTextSelectionAction.test'; +import UIComponentTextCommonSelectionState + from './UIComponentTextCommonSelectionStateTest/UIComponentTextCommonSelectionState.test'; +import UIComponentTextEditMenuOptions from './UIComponentTextEditMenuOptionsTest/UIComponentTextEditMenuOptions.test' +import UIComponentTextAffineTransformationInterface001 + from './UIComponentTextAffineTransformationInterfaceTest/UIComponentTextAffineTransformationInterface001.test'; +import UIComponentReverseAnalysisInterface001 + from './UIComponentReverseAnalysisInterfaceTest/UIComponentReverseAnalysisInterface001.test'; +import UIComponentTextCommonHandleInterface001 + from './UIComponentTextCommonHandleInterfaceTest/UIComponentTextCommonHandleInterface001.test'; +import UiComponentTextCommonApplicationLevelFontsTest + from "./UiComponentTextCommonApplicationLevelFontsTest/UiComponentTextCommonApplicationLevelFontsTest.test"; +import UiComponentTextCommonCustomKeyBoardIsSupportAvoidanceTest + from "./UiComponentTextCommonCustomKeyBoardIsSupportAvoidanceTest/UiComponentTextCommonCustomKeyBoardIsSupportAvoidanceTest.test"; +import UiComponentTextCommonMenuAvoidTest + from "./UiComponentTextCommonMenuAvoidTest/UiComponentTextCommonMenuAvoidTest.test"; +import UIComponentTextSelectionInterface + from "./UIComponentTextSelectionInterfaceTest/UIComponentTextSelectionInterface.test"; +import UIComponentSettextselectionReplacement + from "./UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement.test"; +import UIComponentTextCopyAttributeReplacement + from "./UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement.test"; +import UIComponentEditAbleTextThreeReplacement001 + from './UIComponentEditAbleTextThreeReplacementTest/UIComponentEditAbleTextThreeReplacement001.test'; +import UiComponentTextInputReplacementTest001 + from "./UiComponentTextInputReplacementTest/UiComponentTextInputReplacement001.test"; export default function testsuite() { ComponentTextRicheditorFontfeatures(); @@ -239,6 +291,33 @@ export default function testsuite() { UIComponentPopupBoxAttribute(); UIComponentPopupBoxPromptToastSequence(); UIComponentPopupBoxSpecificationsPopup(); + UIComponentTextCommonHandleInterface001(); + UIComponentReverseAnalysisInterface001(); + UIComponentTextAffineTransformationInterface001(); + UIComponentTextRefactorAdjustMentInterface001(); + UIComponentTextInputDeleteCallbackInterface001(); + UIComponentTextSearchActionInterface001(); + UIComponentTextSearchInterface001(); + UiComponentTextCommonTextMinFontsize(); + UiComponentTextCommonTextImprove(); + UiComponentTextCommonTextStyleTest(); + UiComponentTextDecorationTest(); + UiComponentTextMirrorTest(); + UiComponentTextInputDeleteCallBackTest(); + UiComponentTextRefactorAdjustmentTest(); + UiComponentTextSearchEnterKeyTypeTest(); + UiComponentTextCommonEmojiTest(); + UiComponentTextCommonQuanXuanCaiDanTest(); + UIComponentTextSelectionAction(); + UIComponentTextCommonSelectionState(); + UIComponentTextEditMenuOptions(); + UiComponentTextCommonApplicationLevelFontsTest(); + UiComponentTextCommonCustomKeyBoardIsSupportAvoidanceTest(); + UiComponentTextCommonMenuAvoidTest(); + UIComponentTextSelectionInterface(); + + UIComponentSettextselectionReplacement(); + UIComponentTextCopyAttributeReplacement(); + UIComponentEditAbleTextThreeReplacement001(); + UiComponentTextInputReplacementTest001() } - - diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentEditAbleTextThreeReplacementTest/UIComponentEditAbleTextThreeReplacement001.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentEditAbleTextThreeReplacementTest/UIComponentEditAbleTextThreeReplacement001.test.ets new file mode 100755 index 00000000..9b52176e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentEditAbleTextThreeReplacementTest/UIComponentEditAbleTextThreeReplacement001.test.ets @@ -0,0 +1,421 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, MouseButton, ON } from '@ohos.UiTest' + +/* + * + * Settings.createWindow(config.url): + * 创建窗口,更改窗口基本配置,更改方式详见model/Settings createWindow方法 + * + * windowSnap.snapShot(globalThis.context): + * 窗口截屏&图片文件保存,存储在设备端 + * 存储文件固定,单挑用例执行后覆盖,用于自动化UI对比 + * 支持调试更改文件名为时间戳格式,更改model/snapShot createAndGetFile方法 注释L35,放开L32,L33 + * + * Logger日志使用方法: + * import Logger form './model/Logger' + * Logger.info(TAG,`config = ${config}, err = ${JSON.stringify(exception)}`) + * */ + +export default function UIComponentEditAbleTextThreeReplacement001() { + + describe('UIComponentEditAbleTextThreeReplacement001', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_0340 + * @tc.name SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_0340 + * @tc.desc customKeyBoard + */ + it('SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_0340', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_0340 start.`); + Settings.createWindow("testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0340") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentEditAbleTextThreeReplacement0340_textInput_001')) + await Utils.sleep(500) + await textInput.click() + await Utils.sleep(500) + let key0: Component = await driver.findComponent(ON.id('button_0')) + await Utils.sleep(1000) + await key0.click() + await Utils.sleep(500) + await driver.triggerKey(2081) + await Utils.sleep(1000) + await key0.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_0340 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_0630 + * @tc.name SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_0630 + * @tc.desc customKeyBoard + */ + it('SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_0630', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_0630 start.`); + Settings.createWindow("testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0630") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentEditAbleTextThreeReplacement0630_textInput_001')) + await Utils.sleep(500) + await textInput.click() + await Utils.sleep(500) + let key0: Component = await driver.findComponent(ON.id('button_0')) + await Utils.sleep(1000) + await key0.click() + await Utils.sleep(500) + await driver.triggerKey(2081) + await Utils.sleep(1000) + await key0.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_0630 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_0730 + * @tc.name SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_0730 + * @tc.desc customKeyBoard + */ + it('SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_0730', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_0730 start.`); + Settings.createWindow("testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0730") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentEditAbleTextThreeReplacement0730_textInput_001')) + await Utils.sleep(500) + await textInput.click() + await Utils.sleep(500) + let key0: Component = await driver.findComponent(ON.id('button_0')) + let keyA: Component = await driver.findComponent(ON.id('button_A')) + await Utils.sleep(1000) + await key0.click() + await Utils.sleep(500) + await keyA.click() + await Utils.sleep(500) + await driver.triggerKey(2081) + await Utils.sleep(1000) + await keyA.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_0730 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_1020 + * @tc.name SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_1020 + * @tc.desc customKeyBoard + */ + it('SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_1020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_1020 start.`); + Settings.createWindow("testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement1020") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentEditAbleTextThreeReplacement1020_rich_001')) + await Utils.sleep(500) + await textInput.click() + await Utils.sleep(500) + let key0: Component = await driver.findComponent(ON.id('button_0')) + await Utils.sleep(1000) + await key0.click() + await Utils.sleep(500) + await driver.triggerKey(2081) + await Utils.sleep(1000) + await key0.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_STATESTYLES_INTERFACE_EDITABLETEXTTHREE_1020 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_COMMONATTR_COM_0080 + * @tc.name SUB_ACE_UI_COMPONENT_COMMONATTR_COM_0080 + * @tc.desc Hyperlink notSet color + */ + it('SUB_ACE_UI_COMPONENT_COMMONATTR_COM_0080', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_COMMONATTR_COM_0080 start.`); + Settings.createWindow("testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentCommonAttrCom0080") + await Utils.sleep(2000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_COMMONATTR_COM_0080 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_CUSTOMSPAN_INVAILDATE_0110 + * @tc.name SUB_ACE_UI_COMPONENT_CUSTOMSPAN_INVAILDATE_0110 + * @tc.desc customKeyBoard + */ + it('SUB_ACE_UI_COMPONENT_CUSTOMSPAN_INVAILDATE_0110', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_CUSTOMSPAN_INVAILDATE_0110 start.`); + Settings.createWindow("testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentCustomSpanInvailDate0110") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentCustomSpanInvailDate0110_button_01')) + await Utils.sleep(500) + await button.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_CUSTOMSPAN_INVAILDATE_0110 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_042 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_042 + * @tc.desc minFontSize + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_042', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_042 start.`); + Settings.createWindow("testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize042") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textArea: Component = + await driver.findComponent(ON.id('UIComponentTextMinFontSize042_textArea_001')) + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextMinFontSize042_textInput_001')) + await Utils.sleep(500) + let point1 = await textArea.getBoundsCenter() + await Utils.sleep(500) + await driver.inputText({ + x: 200, y: point1.y + }, "ABC priorities. Sometimes, a significant change") + await Utils.sleep(500) + let point2 = await textInput.getBoundsCenter() + await Utils.sleep(500) + await driver.inputText({ + x: 200, y: point2.y + }, "ABC priorities. Sometimes, a significant change Change,a constant ") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_042 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_043 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_043 + * @tc.desc minFontSize + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_043', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_043 start.`); + Settings.createWindow("testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize043") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textArea: Component = + await driver.findComponent(ON.id('UIComponentTextMinFontSize043_textArea_001')) + let button: Component = + await driver.findComponent(ON.id('UIComponentTextMinFontSize043_button_001')) + await Utils.sleep(200) + let point1 = await textArea.getBoundsCenter() + await Utils.sleep(200) + await driver.inputText({ + x: 200, y: point1.y + }, "ABC priorities. Sometimes, a significant change") + await Utils.sleep(500) + await button.click() + await Utils.sleep(500) + await driver.triggerKey(2071) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_043 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_044 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_044 + * @tc.desc minFontSize + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_044', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_044 start.`); + Settings.createWindow("testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize044") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textArea: Component = + await driver.findComponent(ON.id('UIComponentTextMinFontSize044_textArea_001')) + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextMinFontSize044_textInput_001')) + await Utils.sleep(500) + let point1 = await textArea.getBoundsCenter() + await Utils.sleep(500) + await driver.inputText({ + x: 200, y: point1.y + }, "ABC priorities. Sometimes, a significant change") + await Utils.sleep(500) + let point2 = await textInput.getBoundsCenter() + await Utils.sleep(500) + await driver.inputText({ + x: 200, y: point2.y + }, "ABC priorities. Sometimes, a significant change Change,a constant ") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_044 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_045 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_045 + * @tc.desc minFontSize + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_045', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_045 start.`); + Settings.createWindow("testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize045") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textArea: Component = + await driver.findComponent(ON.id('UIComponentTextMinFontSize045_textArea_001')) + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextMinFontSize045_textInput_001')) + await Utils.sleep(500) + let point1 = await textArea.getBoundsCenter() + await Utils.sleep(500) + await driver.inputText({ + x: 200, y: point1.y + }, "ABC priorities. Sometimes, a significant change") + await Utils.sleep(500) + let point2 = await textInput.getBoundsCenter() + await Utils.sleep(500) + await driver.inputText({ + x: 200, y: point2.y + }, "ABC priorities. Sometimes, a significant change Change,a constant ") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_045 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_046 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_046 + * @tc.desc minFontSize + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_046', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_046 start.`); + Settings.createWindow("testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize046") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textArea: Component = + await driver.findComponent(ON.id('UIComponentTextMinFontSize046_textArea_001')) + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextMinFontSize046_textInput_001')) + await Utils.sleep(500) + let point1 = await textArea.getBoundsCenter() + await Utils.sleep(500) + await driver.inputText({ + x: 200, y: point1.y + }, "ABC priorities. Sometimes, a significant change") + await Utils.sleep(500) + let point2 = await textInput.getBoundsCenter() + await Utils.sleep(500) + await driver.inputText({ + x: 200, y: point2.y + }, "ABC priorities. Sometimes, a significant change Change,a constant ") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_046 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_047 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_047 + * @tc.desc minFontSize + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_047', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_047 start.`); + Settings.createWindow("testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize047") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextMinFontSize047_textInput_001')) + await Utils.sleep(500) + let point2 = await textInput.getBoundsCenter() + await Utils.sleep(500) + await driver.inputText({ + x: 200, y: point2.y + }, "ABC priorities. Sometimes, a significant change Change,a constant ") + await Utils.sleep(500) + await driver.inputText({ + x: 200, y: point2.y + }, "ABC priorities. Sometimes, a significant change Change,a constant ") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_047 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_048 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_048 + * @tc.desc minFontSize + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_048', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_048 start.`); + Settings.createWindow("testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize048") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textArea: Component = + await driver.findComponent(ON.id('UIComponentTextMinFontSize048_textArea_001')) + await Utils.sleep(500) + let point2 = await textArea.getBoundsCenter() + await Utils.sleep(500) + await driver.inputText({ + x: 200, y: point2.y + }, "ABC priorities. Sometimes, a significant change Change,a constant ") + await Utils.sleep(500) + await driver.inputText({ + x: 200, y: point2.y + }, ",a constant and inevitable,every change brings the potential") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_048 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentReverseAnalysisInterfaceTest/UIComponentReverseAnalysisInterface001.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentReverseAnalysisInterfaceTest/UIComponentReverseAnalysisInterface001.test.ets new file mode 100644 index 00000000..42069a95 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentReverseAnalysisInterfaceTest/UIComponentReverseAnalysisInterface001.test.ets @@ -0,0 +1,112 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, MouseButton, ON } from '@ohos.UiTest' + +/* + * + * Settings.createWindow(config.url): + * 创建窗口,更改窗口基本配置,更改方式详见model/Settings createWindow方法 + * + * windowSnap.snapShot(globalThis.context): + * 窗口截屏&图片文件保存,存储在设备端 + * 存储文件固定,单挑用例执行后覆盖,用于自动化UI对比 + * 支持调试更改文件名为时间戳格式,更改model/snapShot createAndGetFile方法 注释L35,放开L32,L33 + * + * Logger日志使用方法: + * import Logger form './model/Logger' + * Logger.info(TAG,`config = ${config}, err = ${JSON.stringify(exception)}`) + * */ + +export default function UIComponentReverseAnalysisInterface001() { + + describe('UIComponentReverseAnalysisInterface001', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_REVERSEANALYSIS_0020 + * @tc.name SUB_ACE_UI_COMPONENT_REVERSEANALYSIS_0020 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_REVERSEANALYSIS_0020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_REVERSEANALYSIS_0020 start.`); + Settings.createWindow("testability/pages/UIComponentReverseAnalysisInterface/UIComponentReverseAnalysisInterface001") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentReverseAnalysisInterface001_button_001')) + let textInput: Component = + await driver.findComponent(ON.id('UIComponentReverseAnalysisInterface001_textInput_001')) + await Utils.sleep(500) + for (let index = 0; index < 3; index++) { + await Utils.sleep(500) + await button?.click() + await textInput?.longClick() + } + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_REVERSEANALYSIS_0020 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_REVERSEANALYSIS_0030 + * @tc.name SUB_ACE_UI_COMPONENT_REVERSEANALYSIS_0030 + * @tc.desc navigation set customKey + */ + it('SUB_ACE_UI_COMPONENT_REVERSEANALYSIS_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_REVERSEANALYSIS_0030 start.`); + Settings.createWindow("testability/pages/UIComponentReverseAnalysisInterface/UIComponentReverseAnalysisInterface002") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentReverseAnalysisInterface002_button_001')) + let textInput: Component = + await driver.findComponent(ON.id('UIComponentReverseAnalysisInterface002_textInput_001')) + await Utils.sleep(1000) + await textInput?.longClick() + await Utils.sleep(500) + await button?.click() + await Utils.sleep(500) + await driver?.pressBack() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_REVERSEANALYSIS_0030 finish.`); + done() + }) + + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement.test.ets new file mode 100755 index 00000000..65a529ca --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement.test.ets @@ -0,0 +1,146 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, MouseButton, ON } from '@ohos.UiTest' + +export default function UIComponentSettextselectionReplacement() { + + describe('UIComponentSettextselectionReplacement', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0210 + * @tc.name SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0210 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0210', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0210 start.`); + Settings.createWindow("testability/pages/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement0210"); + await Utils.sleep(1000); + let driver = Driver.create(); + let search = await driver.findComponent(ON.id('search')); + await search.click(); + await Utils.sleep(1000); + let button = await driver.findComponent(ON.id('ch1')); + await button.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0210 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0210_1 + * @tc.name SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0210_1 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0210_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0210_1 start.`); + Settings.createWindow("testability/pages/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement0210"); + await Utils.sleep(1000); + let driver = Driver.create(); + let search = await driver.findComponent(ON.id('search')); + await search.click(); + await Utils.sleep(1000); + let button = await driver.findComponent(ON.id('ch2')); + await button.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0210_1 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0210_2 + * @tc.name SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0210_2 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0210_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0210_2 start.`); + Settings.createWindow("testability/pages/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement0210"); + await Utils.sleep(1000); + let driver = Driver.create(); + let search = await driver.findComponent(ON.id('search')); + await search.click(); + await Utils.sleep(1000); + let button = await driver.findComponent(ON.id('ch3')); + await button.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0210_2 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0220 + * @tc.name SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0220 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0220', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0220 start.`); + Settings.createWindow("testability/pages/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement0220"); + await Utils.sleep(1000); + let driver = Driver.create(); + let search = await driver.findComponent(ON.id('search')); + await search.doubleClick(); + await Utils.sleep(1000); + await search.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0220 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0230 + * @tc.name SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0230 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0230', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0230 start.`); + Settings.createWindow("testability/pages/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement0220"); + await Utils.sleep(1000); + let driver = Driver.create(); + let search = await driver.findComponent(ON.id('search')); + await search.click(); + await Utils.sleep(1000); + await search.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SETTEXTSELECTION_0230 finish.`); + done(); + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextAffineTransformationInterfaceTest/UIComponentTextAffineTransformationInterface001.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextAffineTransformationInterfaceTest/UIComponentTextAffineTransformationInterface001.test.ets new file mode 100644 index 00000000..d06d222d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextAffineTransformationInterfaceTest/UIComponentTextAffineTransformationInterface001.test.ets @@ -0,0 +1,358 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, MouseButton, ON } from '@ohos.UiTest' + +/* + * + * Settings.createWindow(config.url): + * 创建窗口,更改窗口基本配置,更改方式详见model/Settings createWindow方法 + * + * windowSnap.snapShot(globalThis.context): + * 窗口截屏&图片文件保存,存储在设备端 + * 存储文件固定,单挑用例执行后覆盖,用于自动化UI对比 + * 支持调试更改文件名为时间戳格式,更改model/snapShot createAndGetFile方法 注释L35,放开L32,L33 + * + * Logger日志使用方法: + * import Logger form './model/Logger' + * Logger.info(TAG,`config = ${config}, err = ${JSON.stringify(exception)}`) + * */ + +export default function UIComponentTextAffineTransformationInterface001() { + + describe('UIComponentTextAffineTransformationInterface001', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT _COMMON_AFFINE_TRANSFORMATION_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT _COMMON_AFFINE_TRANSFORMATION_0010 + * @tc.desc text test scale(ScaleOptions)属性的值设置为{x:2,y:0.5.z:5} + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0010 start.`); + Settings.createWindow("testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface001") + let driver: Driver = Driver.create() + await Utils.sleep(1000) + let scaleButton: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface001_button_001')) + let text: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface001_text_001')) + await Utils.sleep(1000) + await text?.longClick() + await Utils.sleep(1000) + await scaleButton?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0010 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT _COMMON_AFFINE_TRANSFORMATION_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT _COMMON_AFFINE_TRANSFORMATION_0040 + * @tc.desc text test scale(ScaleOptions)属性的值设置为{x:2,y:0.5.z:5,centerX:'0%',centerY:'0%'} + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0040 start.`); + Settings.createWindow("testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface002") + let driver: Driver = Driver.create() + await Utils.sleep(1000) + let scaleButton: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface002_button_001')) + let text: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface002_text_001')) + await Utils.sleep(1000) + await text?.longClick() + await Utils.sleep(1000) + await scaleButton?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0040 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT _COMMON_AFFINE_TRANSFORMATION_0050 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT _COMMON_AFFINE_TRANSFORMATION_0050 + * @tc.desc textInput test scale(ScaleOptions)属性的值设置为{x:2,y:0.5.z:5,centerX:'0%',centerY:'0%'} + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0050 start.`); + Settings.createWindow("testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface003") + let driver: Driver = Driver.create() + await Utils.sleep(1000) + let scaleButton: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface003_button_001')) + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface003_textInput_001')) + await Utils.sleep(1000) + await textInput?.longClick() + await Utils.sleep(1000) + await scaleButton?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0050 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0100 + * @tc.desc text test translate(TranslateOptions)属性的值设置为{x:100,y:10} + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0100 start.`); + Settings.createWindow("testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface004") + let driver: Driver = Driver.create() + await Utils.sleep(1000) + let scaleButton: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface004_button_001')) + let text: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface004_text_001')) + await Utils.sleep(1000) + await text?.longClick() + await Utils.sleep(1000) + await scaleButton?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0100 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0130 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0130 + * @tc.desc text test transform(Matrix4Transit) + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0130', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0130 start.`); + Settings.createWindow("testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface005") + let driver: Driver = Driver.create() + await Utils.sleep(1000) + let scaleButton: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface005_button_001')) + let text: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface005_text_001')) + await Utils.sleep(1000) + await text?.longClick() + await Utils.sleep(1000) + await scaleButton?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0130 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0430 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0430 + * @tc.desc text test transform(Matrix4Transit) + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0430', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0430 start.`); + Settings.createWindow("testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface006") + let driver: Driver = Driver.create() + await Utils.sleep(1000) + let scaleButton: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface006_button_001')) + let text: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface006_text_001')) + await Utils.sleep(1000) + let point = await text?.getBoundsCenter() + await Utils.sleep(500) + await driver?.drag(point.x, point.y, point.x - 40, point.y) + await Utils.sleep(1000) + await scaleButton?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0430 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0440 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0440 + * @tc.desc text test transform(Matrix4Transit) + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0440', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0440 start.`); + Settings.createWindow("testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface007") + let driver: Driver = Driver.create() + await Utils.sleep(1000) + let scaleButton: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface007_button_001')) + let text: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface007_textInput_001')) + await Utils.sleep(1000) + await text?.longClick() + // let point = await textInput?.getBoundsCenter() + // await Utils.sleep(500) + // await driver?.drag(0, point.y, 60, point.y) + await Utils.sleep(1000) + await scaleButton?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0440 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0720 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0720 + * @tc.desc text test transform(Matrix4Transit) + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0720', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0720 start.`); + Settings.createWindow("testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface008") + let driver: Driver = Driver.create() + await Utils.sleep(1000) + let scaleButton: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface008_button_002')) + let setSelectButton: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface008_button_001')) + let text: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface008_text_001')) + await Utils.sleep(1000) + await setSelectButton?.click() + await Utils.sleep(1000) + await text?.longClick() + await Utils.sleep(1000) + await scaleButton?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0720 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0730 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0730 + * @tc.desc text test transform(Matrix4Transit) + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0730', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0730 start.`); + Settings.createWindow("testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface009") + let driver: Driver = Driver.create() + await Utils.sleep(1000) + let scaleButton: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface009_button_002')) + let setSelectButton: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface009_button_001')) + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface009_textInput_001')) + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(500) + await setSelectButton?.click() + await Utils.sleep(1000) + await textInput?.longClick() + await Utils.sleep(1000) + await scaleButton?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0730 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0740 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0740 + * @tc.desc text test transform(Matrix4Transit) + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0740', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0740 start.`); + Settings.createWindow("testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface009") + let driver: Driver = Driver.create() + await Utils.sleep(1000) + let scaleButton: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface009_button_002')) + let setSelectButton: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface009_button_001')) + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface009_textInput_001')) + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(500) + await setSelectButton?.click() + await Utils.sleep(1000) + await textInput?.click() + await Utils.sleep(200) + await textInput?.click() + await Utils.sleep(1000) + await scaleButton?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0740 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0790 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0790 + * @tc.desc text test transform(Matrix4Transit) + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0790', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0740 start.`); + Settings.createWindow("testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface0010") + let driver: Driver = Driver.create() + await Utils.sleep(1000) + let scaleButton: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface0010_button_002')) + let enableDataDetector: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface0010_button_001')) + let text: Component = + await driver.findComponent(ON.id('UIComponentTextAffineTransformationInterface0010_text_001')) + await Utils.sleep(500) + await enableDataDetector?.click() + await Utils.sleep(1000) + await text?.longClick() + await Utils.sleep(1000) + await scaleButton?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_AFFINE_TRANSFORMATION_0790 finish.`); + done() + }) + + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextCommonHandleInterfaceTest/UIComponentTextCommonHandleInterface001.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextCommonHandleInterfaceTest/UIComponentTextCommonHandleInterface001.test.ets new file mode 100644 index 00000000..e3c3dcfc --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextCommonHandleInterfaceTest/UIComponentTextCommonHandleInterface001.test.ets @@ -0,0 +1,382 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, MouseButton, ON } from '@ohos.UiTest' + +/* + * + * Settings.createWindow(config.url): + * 创建窗口,更改窗口基本配置,更改方式详见model/Settings createWindow方法 + * + * windowSnap.snapShot(globalThis.context): + * 窗口截屏&图片文件保存,存储在设备端 + * 存储文件固定,单挑用例执行后覆盖,用于自动化UI对比 + * 支持调试更改文件名为时间戳格式,更改model/snapShot createAndGetFile方法 注释L35,放开L32,L33 + * + * Logger日志使用方法: + * import Logger form './model/Logger' + * Logger.info(TAG,`config = ${config}, err = ${JSON.stringify(exception)}`) + * */ + +export default function UIComponentTextCommonHandleInterface001() { + + describe('UIComponentTextCommonHandleInterface001', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0010 + * @tc.desc swiper vertical为false + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0010 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface001") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let text: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface001_text_001')) + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface001_textInput_001')) + let textArea: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface001_textArea_001')) + let button: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface001_button_001')) + await Utils.sleep(500); + await button?.click() + await Utils.sleep(500) + await text?.longClick() + await Utils.sleep(500); + let selectAll = await driver.findComponent(ON.text('全选')) + await selectAll?.click() + // await Utils.sleep(500); + + // await button?.click() + await Utils.sleep(1500) + windowSnap.snapShot() + await Utils.sleep(2000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0010 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0020 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0020 + * @tc.desc swiper vertical为false + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0020 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface002") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let text: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface002_text_001')) + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface002_textInput_001')) + let textArea: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface002_textArea_001')) + let button: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface002_button_001')) + await Utils.sleep(500); + await button?.click() + await Utils.sleep(500) + await text?.longClick() + await Utils.sleep(500); + let selectAll = await driver.findComponent(ON.text('全选')) + await selectAll?.click() + await Utils.sleep(3000); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0020 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0070 + * @tc.desc List的listDirection为Vertical + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0070 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface003") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface003_textInput_001')) + await Utils.sleep(500) + await textInput?.longClick() + await Utils.sleep(500); + let selectAll = await driver.findComponent(ON.text('全选')) + await selectAll?.click() + await Utils.sleep(500); + await driver?.mouseScroll({ + x: 100, y: 200 + }, true, 40, MouseButton.MOUSE_BUTTON_LEFT, 1000) + await Utils.sleep(500); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0070 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0080 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0080 + * @tc.desc List的listDirection为Horizontal + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0080', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0080 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface004") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface004_textInput_001')) + let button: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface004_button_001')) + await Utils.sleep(500) + await textInput?.longClick() + await Utils.sleep(500); + let selectAll = await driver.findComponent(ON.text('全选')) + await selectAll?.click() + await Utils.sleep(1000); + await button?.click() + await Utils.sleep(1000); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0080 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0090 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0090 + * @tc.desc WaterFlow的layoutDirection为Column + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0090', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0090 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface005") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface005_textInput_001')) + await Utils.sleep(500) + await textInput?.longClick() + await Utils.sleep(500); + let selectAll = await driver.findComponent(ON.text('全选')) + await selectAll?.click() + await Utils.sleep(500); + await driver?.mouseScroll({ + x: 100, y: 400 + }, true, 10, MouseButton.MOUSE_BUTTON_LEFT, 1000) + await Utils.sleep(2000); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0090 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0100 + * @tc.desc WaterFlow的layoutDirection为Row + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0100 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface006") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface006_textInput_001')) + await Utils.sleep(500) + await textInput?.longClick() + await Utils.sleep(500); + let selectAll = await driver.findComponent(ON.text('全选')) + await selectAll?.click() + await Utils.sleep(500); + await driver?.drag(200, 300, 50, 300, 1000) + await Utils.sleep(500); + await driver?.drag(50, 300, 200, 300, 1000) + await Utils.sleep(1500); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0100 finish.`); + done() + }) + + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0120 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0120 + * @tc.desc Grid的layoutDirection为Column + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0120 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface0010") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface0010_textInput_001')) + let scrollButton: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface0010_button_001')) + let typeButton: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface0010_button_002')) + await Utils.sleep(500) + await typeButton?.click() //change Column + await Utils.sleep(500) + await textInput?.longClick() + await Utils.sleep(500); + let selectAll = await driver.findComponent(ON.text('全选')) + await selectAll?.click() + await Utils.sleep(500); + for (let index = 0; index < 3; index++) { + await Utils.sleep(500); + await scrollButton?.click() + } + await Utils.sleep(500); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0120 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0130 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0130 + * @tc.desc Grid的layoutDirection为Row + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0130', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0130 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface0010") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface0010_textInput_001')) + let scrollButton: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface0010_button_001')) + await Utils.sleep(500) + await textInput?.longClick() + await Utils.sleep(500); + let selectAll = await driver.findComponent(ON.text('全选')) + await selectAll?.click() + await Utils.sleep(500); + for (let index = 0; index < 3; index++) { + await Utils.sleep(500); + await scrollButton?.click() + } + await Utils.sleep(500); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0130 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0140 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0140 + * @tc.desc Scroll的ScrollDirection为Vertical + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0140', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0140 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface007") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface007_textInput_001')) + await Utils.sleep(500) + await textInput?.longClick() + await Utils.sleep(500); + let selectAll = await driver.findComponent(ON.text('全选')) + await selectAll?.click() + await Utils.sleep(500); + await driver?.mouseScroll({ + x: 100, y: 200 + }, true, 40, MouseButton.MOUSE_BUTTON_LEFT, 1000) + await Utils.sleep(500); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0140 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0150 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0150 + * @tc.desc Scroll的ScrollDirection为Horizontal + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0150', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0150 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface008") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface008_textInput_001')) + let button: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface008_button_001')) + await Utils.sleep(500) + await textInput?.longClick() + await Utils.sleep(500); + let selectAll = await driver.findComponent(ON.text('全选')) + await selectAll?.click() + await Utils.sleep(1000); + await button?.click() + await Utils.sleep(1000); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0150 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0180 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0180 + * @tc.desc setOrientation + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0180', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0180 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface009") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextCommonHandleInterface009_textInput_001')) + await Utils.sleep(500) + await textInput?.longClick() + await Utils.sleep(500); + let selectAll = await driver.findComponent(ON.text('全选')) + await selectAll?.click() + await Utils.sleep(1000); + Settings.changeOrientation() + await Utils.sleep(1000); + Settings.changeOrientation() + await Utils.sleep(1000); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_HANDLE_0180 finish.`); + done() + }) + + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextCommonSelectionStateTest/UIComponentTextCommonSelectionState.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextCommonSelectionStateTest/UIComponentTextCommonSelectionState.test.ets new file mode 100644 index 00000000..b401011a --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextCommonSelectionStateTest/UIComponentTextCommonSelectionState.test.ets @@ -0,0 +1,943 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton, UiWindow } from '@ohos.UiTest' + +export default function UIComponentTextCommonSelectionState() { + + describe('UIComponentTextCommonSelectionState', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return; + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0010 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0010 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_tx')); + await Utils.sleep(100); + await text.longClick(); + await Utils.sleep(500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0010 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0020 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0020 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0020 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_txArea')); + await Utils.sleep(300); + let point = await text.getBoundsCenter(); + await Utils.sleep(1000); + await driver.longClick(point.x, point.y); + await Utils.sleep(500); + await driver.triggerCombineKeys(2072, 2019); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0020 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0030 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0030 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0030 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_txArea')); + await Utils.sleep(100); + let point = await text.getBoundsCenter(); + await Utils.sleep(500); + await driver.drag(point.x, point.y, point.x + 50, point.y + 20, 400); + await Utils.sleep(500); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_RIGHT); + await Utils.sleep(500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0030 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0040 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0040 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_txArea')); + await Utils.sleep(100); + let point = await text.getBoundsCenter(); + await Utils.sleep(500); + await driver.mouseDrag({ + x: point.x - 20, y: point.y + }, { + x: point.x + 50, y: point.y + 20 + }, 400); + await Utils.sleep(500); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_RIGHT); + await Utils.sleep(500); + await driver.triggerCombineKeys(2072, 2019); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0040 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0050 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0050 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0050 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_txArea')); + await Utils.sleep(500); + let point = await text.getBounds(); + await Utils.sleep(1000); + await driver.triggerKey(2081) + await Utils.sleep(1000); + await driver.longClick(point.left + 50, point.top + 30); + await Utils.sleep(1500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1500); + await driver.triggerKey(2082); + await Utils.sleep(1000); + await driver.longClick(point.left + 80, point.top + 30); + await Utils.sleep(1500); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await paste.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0050 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0060 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0060 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0060 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_txArea')); + await Utils.sleep(500); + let point = await text.getBounds(); + await Utils.sleep(1000); + await driver.triggerKey(2081) + await Utils.sleep(1000); + await driver.longClick(point.left + 50, point.top + 30); + await Utils.sleep(1500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(500); + await driver.triggerKey(2082); + await Utils.sleep(1000); + await driver.longClick(point.left + 80, point.top + 30); + await Utils.sleep(1000); + await driver.triggerCombineKeys(2072, 2038); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0060 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0070 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0070 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_txArea')); + await Utils.sleep(500); + let point = await text.getBounds(); + await Utils.sleep(1000); + await driver.triggerKey(2081) + await Utils.sleep(1000); + await driver.longClick(point.left + 50, point.top + 30); + await Utils.sleep(1500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + await driver.triggerKey(2082); + await Utils.sleep(1000); + await driver.mouseDrag({ + x: point.left + 30, y: point.bottom - 30 + }, { + x: point.right - 10, y: point.bottom + }); + await Utils.sleep(1000); + await driver.mouseClick({ + x: point.left + 80, y: point.top + 30 + }, MouseButton.MOUSE_BUTTON_RIGHT); + await Utils.sleep(1000); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await paste.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0070 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0080 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0080 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0080', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0080 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_txArea')); + await Utils.sleep(500); + let point = await text.getBoundsCenter(); + let point1 = await text.getBounds(); + await Utils.sleep(1000); + await driver.triggerKey(2081) + await Utils.sleep(1000); + await driver.longClick(point1.left + 50, point1.top + 30); + await Utils.sleep(1500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(500); + await driver.triggerKey(2082); + // let point = await text.getBoundsCenter(); + await Utils.sleep(500); + await driver.mouseDrag({ + x: point.x, y: point.y + }, { + x: point.x + 80, y: point.y + 10 + }); + await Utils.sleep(500); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_RIGHT); + await Utils.sleep(1000); + await driver.triggerCombineKeys(2072, 2038); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0080 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0090 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0090 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0090', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0090 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_txArea')); + await Utils.sleep(500); + let point = await text.getBounds(); + await Utils.sleep(1000); + await driver.triggerKey(2081) + await Utils.sleep(1000); + await driver.longClick(point.left + 50, point.top + 30); + await Utils.sleep(1500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(500); + await driver.triggerKey(2082); + await Utils.sleep(1000); + await driver.longClick(point.left + 80, point.top + 30); + await Utils.sleep(1500); + let cut: Component = await driver.findComponent(ON.text('剪切')); + await cut.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0090 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0100 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0100 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_txArea')); + await Utils.sleep(100); + let point = await text.getBoundsCenter(); + await Utils.sleep(500); + await driver.drag(point.x, point.y, point.x + 80, point.y + 10); + await Utils.sleep(500); + await driver.triggerCombineKeys(2072, 2040); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0100 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0110 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0110 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0110', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0110 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_txArea')); + await Utils.sleep(100); + let point = await text.getBoundsCenter(); + await Utils.sleep(500); + await driver.mouseDrag({ + x: point.x, y: point.y + }, { + x: point.x + 80, y: point.y + 10 + }); + await Utils.sleep(500); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_RIGHT); + await Utils.sleep(500); + let cut: Component = await driver.findComponent(ON.text('剪切')); + await cut.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0110 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0120 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0120 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0120 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_txArea')); + await Utils.sleep(100); + let point = await text.getBoundsCenter(); + await Utils.sleep(500); + await driver.mouseDrag({ + x: point.x, y: point.y + }, { + x: point.x + 80, y: point.y + 10 + }); + await Utils.sleep(500); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_RIGHT); + await Utils.sleep(500); + await driver.triggerCombineKeys(2072, 2040); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0120 finish.`); + done(); + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0130 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0130 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0130', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0130 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_txArea')); + await Utils.sleep(500); + let point = await text.getBoundsCenter(); + await Utils.sleep(500); + await driver.drag(point.x, point.y, point.x + 80, point.y + 10); + await Utils.sleep(500); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0130 finish.`); + done(); + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0140 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0140 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0140', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0140 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_txArea')); + await Utils.sleep(100); + let point = await text.getBoundsCenter(); + await Utils.sleep(500); + await driver.mouseDrag({ + x: point.x, y: point.y + }, { + x: point.x + 80, y: point.y + 10 + }); + await Utils.sleep(500); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_RIGHT); + await Utils.sleep(500); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0140 finish.`); + done(); + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0150 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0150 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0150', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0090 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_txArea')); + await Utils.sleep(500); + let point = await text.getBounds(); + await Utils.sleep(1000); + await driver.triggerKey(2081) + await Utils.sleep(1000); + await driver.longClick(point.left + 50, point.top + 30); + await Utils.sleep(1500); + await Settings.changeOrientation(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + await Settings.changeOrientation(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0150 finish.`); + done(); + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0160 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0160 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0160', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0140 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0010_tx')); + await Utils.sleep(100); + let point = await text.getBoundsCenter(); + await Utils.sleep(500); + await driver.mouseDrag({ + x: point.x, y: point.y + }, { + x: point.x + 80, y: point.y + 10 + }); + await Utils.sleep(500); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_RIGHT); + await Utils.sleep(500); + await Settings.changeOrientation(); + await Utils.sleep(1500); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0160 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0190 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0190 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0190', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0190 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0190") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('textCommonSelectionState0190_btn')); + await Utils.sleep(500); + await btn.click(); + await Utils.sleep(1500); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0190 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0200 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0200 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0200', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0200 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0200") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let txArea: Component = await driver.findComponent(ON.id('textCommonSelectionState0200_txInput')); + let opBtn: Component = await driver.findComponent(ON.id('textCommonSelectionState0200_opBtn')); + let selOpbtn: Component = await driver.findComponent(ON.id('textCommonSelectionState0200_selectBtn')); + await Utils.sleep(500); + await txArea.click(); + await Utils.sleep(500); + await opBtn.click(); + await Utils.sleep(500); + await opBtn.click(); + await Utils.sleep(500); + await selOpbtn.click(); + await Utils.sleep(1500); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0200 finish.`); + done(); + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0230_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0230_1 + * @tc.desc search:todo scroll&select + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0230_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0230_1 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_1") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textCommonSelectionState0230_txInput')); + let btn = await driver.findComponent(ON.id('textCommonSelectionState0230_1_btn')); + await Utils.sleep(300); + for (let index = 0; index < 2; index++) { + await textInput.longClick(); + await Utils.sleep(200); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy?.click(); + await Utils.sleep(200); + await driver.triggerKey(2049); + await Utils.sleep(200); + + await textInput.longClick(); + await Utils.sleep(200); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await paste?.click(); + await Utils.sleep(200); + await driver.triggerKey(2049); + await Utils.sleep(200); + + await textInput.longClick(); + await Utils.sleep(200); + let cut: Component = await driver.findComponent(ON.text('剪切')); + await cut?.click(); + await Utils.sleep(200); + await driver.triggerKey(2049); + await Utils.sleep(200); + + await textInput.longClick(); + await Utils.sleep(200); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll?.click(); + await Utils.sleep(200); + await driver.triggerKey(2049); + + await btn.click(); + await Utils.sleep(200); + } + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0230_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0230_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0230_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0230_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0230_2 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_2") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textCommonSelectionState0230_txArea')); + let btn = await driver.findComponent(ON.id('textCommonSelectionState0230_2_btn')); + await Utils.sleep(300); + for (let index = 0; index < 2; index++) { + await textInput.longClick(); + await Utils.sleep(200); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy?.click(); + await Utils.sleep(200); + await driver.triggerKey(2049); + await Utils.sleep(200); + + await textInput.longClick(); + await Utils.sleep(200); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await paste?.click(); + await Utils.sleep(200); + await driver.triggerKey(2049); + await Utils.sleep(200); + + await textInput.longClick(); + await Utils.sleep(200); + let cut: Component = await driver.findComponent(ON.text('剪切')); + await cut?.click(); + await Utils.sleep(200); + await driver.triggerKey(2049); + await Utils.sleep(200); + + await textInput.longClick(); + await Utils.sleep(200); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll?.click(); + await Utils.sleep(200); + await driver.triggerKey(2049); + + await btn.click(); + await Utils.sleep(200); + } + await Utils.sleep(500); + windowSnap.snapShot(); + await Utils.sleep(500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0230_2 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0230_3 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0230_3 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0230_3', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0230_3 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_3") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('textSelectionOptimization0230_search')); + let btn = await driver.findComponent(ON.id('textCommonSelectionState0230_3_btn')); + await Utils.sleep(300); + for (let index = 0; index < 2; index++) { + await search.longClick(); + await Utils.sleep(200); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy?.click(); + await Utils.sleep(200); + await driver.triggerKey(2049); + await Utils.sleep(200); + + await search.longClick(); + await Utils.sleep(200); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await paste?.click(); + await Utils.sleep(200); + await driver.triggerKey(2049); + await Utils.sleep(200); + + await search.longClick(); + await Utils.sleep(200); + let cut: Component = await driver.findComponent(ON.text('剪切')); + await cut?.click(); + await Utils.sleep(200); + await driver.triggerKey(2049); + await Utils.sleep(200); + + await search.longClick(); + await Utils.sleep(200); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll?.click(); + await Utils.sleep(200); + await driver.triggerKey(2049); + + await btn.click(); + await Utils.sleep(200); + } + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0230_3 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0240_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0240_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0240_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0240_1 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0240_1") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textCommonSelectionState0240_txInput')); + await Utils.sleep(500); + await textInput.longClick(); + await Utils.sleep(500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy?.click(); + await Utils.sleep(500); + await driver.triggerKey(2049); + await Utils.sleep(500); + + await textInput.longClick(); + await Utils.sleep(500); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await paste?.click(); + await Utils.sleep(500); + await driver.triggerKey(2049); + await Utils.sleep(500); + + await textInput.longClick(); + await Utils.sleep(500); + let cut: Component = await driver.findComponent(ON.text('剪切')); + await cut?.click(); + await Utils.sleep(500); + await driver.triggerKey(2049); + await Utils.sleep(500); + + await textInput.longClick(); + await Utils.sleep(500); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll?.click(); + + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0240_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0240_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0240_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0240_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0240_2 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0240_2") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textCommonSelectionState0240_txArea')); + await Utils.sleep(500); + await textArea.longClick(); + await Utils.sleep(500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy?.click(); + await Utils.sleep(500); + await driver.triggerKey(2049); + await Utils.sleep(500); + + await textArea.longClick(); + await Utils.sleep(500); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await paste?.click(); + await Utils.sleep(500); + await driver.triggerKey(2049); + await Utils.sleep(500); + + await textArea.longClick(); + await Utils.sleep(500); + let cut: Component = await driver.findComponent(ON.text('剪切')); + await cut?.click(); + await Utils.sleep(500); + await driver.triggerKey(2049); + await Utils.sleep(500); + + await textArea.longClick(); + await Utils.sleep(500); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll?.click(); + + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0240_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0250 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0250 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0250', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0250 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0250") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('textCommonSelectionState0250_tx')); + await Utils.sleep(500); + await text.longClick(); + await Utils.sleep(500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy?.click(); + await Utils.sleep(500); + await driver.triggerKey(2049); + await Utils.sleep(500); + + await text.longClick(); + await Utils.sleep(500); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll?.click(); + await Utils.sleep(500); + + await Utils.sleep(1500); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0250 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0260 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0260 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0260', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0260 start.`); + Settings.createWindow("testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0260") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let richEd: Component = await driver.findComponent(ON.id('textCommonSelectionState0260_richEd')); + await Utils.sleep(500); + await richEd.longClick(); + await Utils.sleep(500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy?.click(); + await Utils.sleep(500); + await driver.triggerKey(2082); + await Utils.sleep(500); + + await richEd.longClick(); + await Utils.sleep(500); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await paste?.click(); + await Utils.sleep(500); + await driver.triggerKey(2082); + await Utils.sleep(500); + + await richEd.longClick(); + await Utils.sleep(500); + let cut: Component = await driver.findComponent(ON.text('剪切')); + await cut?.click(); + await Utils.sleep(500); + await driver.triggerKey(2082); + await Utils.sleep(500); + + + await richEd.longClick(); + await Utils.sleep(500); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll?.click(); + await Utils.sleep(500); + + await Utils.sleep(1500); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_SELECTION_STATE_0260 finish.`); + done(); + }) + }) +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement.test.ets new file mode 100755 index 00000000..172655ca --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement.test.ets @@ -0,0 +1,1154 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, MouseButton, ON } from '@ohos.UiTest' + +export default function UIComponentTextCopyAttributeReplacement() { + + describe('UIComponentTextCopyAttributeReplacement', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0060 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0060 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0060 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0060"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0060')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0060 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0070 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0070 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0070 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0070"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0070')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0070 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0080 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0080 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0080', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0080 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0080"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0080')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0080 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0090 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0090 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0090', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0090 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0090"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0090')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0090 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0100 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0100 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0100 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0100"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0100')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0100 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0110 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0110 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0110', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0110 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0110"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0110')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0110 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0120 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0120 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0120 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0120"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0120')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0120 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0130 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0130 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0130', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0130 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0130"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0130')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0130 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0140 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0140 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0140', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0140 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0140"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0140')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0140 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0150 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0/* + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0150', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0150 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0150"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0150')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0150 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0160 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0160 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0160', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0160 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0160"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0160')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0160 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0170 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0170 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0170', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0170 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0170"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0170')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0170 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0180 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0180 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0180', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0180 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0180"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0180')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0180 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0190 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0190 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0190', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0190 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0190"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0190')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0190 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0200 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0200 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0200', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0200 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0200"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0200')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0200 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0210 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0210 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0210', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0210 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0210"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0210')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0210 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0220 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0220 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0220', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0220 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0220"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0220')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0220 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0370 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0370 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0370', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0370 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0370"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0370')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0370 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0380 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0380 + * @tc.desc scroll + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0380', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0380 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0380"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text = await driver.findComponent(ON.id('UIComponentTextCopyAttributeReplacement0380')); + await text.longClick(); + await Utils.sleep(1000); + let copy = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + let read = await driver.findComponent(ON.id('read')); + await read.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0380 finish.`); + done(); + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0230 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0230 + * @tc.desc TextArea组件,设置启用自动填充。 +*/ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0230', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0230 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0230"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text: Component = await driver.findComponent(ON.id('text')) + await Utils.sleep(1000); + text.longClick() + await Utils.sleep(2000); + let allSelect: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(200); + allSelect.click() + await Utils.sleep(1000); + + let copy: Component = await driver.findComponent(ON.text('复制')) + await Utils.sleep(200); + copy.click() + await Utils.sleep(1000); + + let getData: Component = await driver.findComponent(ON.id('getData')) + await Utils.sleep(200); + getData.click() + await Utils.sleep(1500); + + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0230 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0240 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0240 + * @tc.desc Text组件包含span子组件设置文本字符间距 + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0240', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0240 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0240"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text: Component = await driver.findComponent(ON.id('text')) + await Utils.sleep(1000); + text.longClick() + await Utils.sleep(2000); + let allSelect: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(200); + allSelect.click() + await Utils.sleep(1000); + + let copy: Component = await driver.findComponent(ON.text('复制')) + await Utils.sleep(200); + copy.click() + await Utils.sleep(1000); + + let getData: Component = await driver.findComponent(ON.id('getData')) + await Utils.sleep(200); + getData.click() + await Utils.sleep(1500); + + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0240 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0250 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0250 + * @tc.desc Text组件包含span子组件设置文本行高 + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0250', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0250 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0250"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text: Component = await driver.findComponent(ON.id('text')) + await Utils.sleep(1000); + text.longClick() + await Utils.sleep(2000); + let allSelect: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(200); + allSelect.click() + await Utils.sleep(1000); + + let copy: Component = await driver.findComponent(ON.text('复制')) + await Utils.sleep(200); + copy.click() + await Utils.sleep(1000); + + let getData: Component = await driver.findComponent(ON.id('getData')) + await Utils.sleep(200); + getData.click() + await Utils.sleep(1500); + + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0250 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0260 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0260 + * @tc.desc Text组件包含span子组件设置文本行间距 + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0260', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0260 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0260"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text: Component = await driver.findComponent(ON.id('text')) + await Utils.sleep(1000); + text.longClick() + await Utils.sleep(2000); + let allSelect: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(200); + allSelect.click() + await Utils.sleep(1000); + + let copy: Component = await driver.findComponent(ON.text('复制')) + await Utils.sleep(200); + copy.click() + await Utils.sleep(1000); + + let getData: Component = await driver.findComponent(ON.id('getData')) + await Utils.sleep(200); + getData.click() + await Utils.sleep(1500); + + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0260 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0270 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0270 + * @tc.desc Text组件包含span子组件设置文本基线偏移量文本基线偏移量 + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0270', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0270 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0270"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text: Component = await driver.findComponent(ON.id('text')) + await Utils.sleep(1000); + text.longClick() + await Utils.sleep(2000); + let allSelect: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(200); + allSelect.click() + await Utils.sleep(1000); + + let copy: Component = await driver.findComponent(ON.text('复制')) + await Utils.sleep(200); + copy.click() + await Utils.sleep(1000); + + let getData: Component = await driver.findComponent(ON.id('getData')) + await Utils.sleep(200); + getData.click() + await Utils.sleep(1500); + + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0270 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0280 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0280 + * @tc.desc Text组件包含span子组件设置文本超长显示方式 + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0280', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0280 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0280"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text: Component = await driver.findComponent(ON.id('text')) + await Utils.sleep(1000); + text.longClick() + await Utils.sleep(2000); + let allSelect: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(200); + allSelect.click() + await Utils.sleep(1000); + + let copy: Component = await driver.findComponent(ON.text('复制')) + await Utils.sleep(200); + copy.click() + await Utils.sleep(1000); + + let getData: Component = await driver.findComponent(ON.id('getData')) + await Utils.sleep(200); + getData.click() + await Utils.sleep(1500); + + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0280 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0290 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0290 + * @tc.desc Text组件包含span子组件设置对齐方式 + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0290', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0290 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0290"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text: Component = await driver.findComponent(ON.id('text')) + await Utils.sleep(1000); + text.longClick() + await Utils.sleep(2000); + let allSelect: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(200); + allSelect.click() + await Utils.sleep(1000); + + let copy: Component = await driver.findComponent(ON.text('复制')) + await Utils.sleep(200); + copy.click() + await Utils.sleep(1000); + + let getData: Component = await driver.findComponent(ON.id('getData')) + await Utils.sleep(200); + getData.click() + await Utils.sleep(1500); + + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0290 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0300 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0300 + * @tc.desc Text组件包含span子组件设置文本最大行数 + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0300', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0300 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0300"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text: Component = await driver.findComponent(ON.id('text')) + await Utils.sleep(1000); + text.longClick() + await Utils.sleep(2000); + let allSelect: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(200); + allSelect.click() + await Utils.sleep(1000); + + let copy: Component = await driver.findComponent(ON.text('复制')) + await Utils.sleep(200); + copy.click() + await Utils.sleep(1000); + + let getData: Component = await driver.findComponent(ON.id('getData')) + await Utils.sleep(200); + getData.click() + await Utils.sleep(1500); + + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0300 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0310 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0310 + * @tc.desc Text组件包含span子组件不设置文本最大行数 + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0310', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0310 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0310"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text: Component = await driver.findComponent(ON.id('text')) + await Utils.sleep(1000); + text.longClick() + await Utils.sleep(2000); + let allSelect: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(200); + allSelect.click() + await Utils.sleep(1000); + + let copy: Component = await driver.findComponent(ON.text('复制')) + await Utils.sleep(200); + copy.click() + await Utils.sleep(1000); + + let getData: Component = await driver.findComponent(ON.id('getData')) + await Utils.sleep(200); + getData.click() + await Utils.sleep(1500); + + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0310 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0320 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0320 + * @tc.desc Text组件包含span子组件设置首行文本缩进 + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0320', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0320 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0320"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text: Component = await driver.findComponent(ON.id('text')) + await Utils.sleep(1000); + text.longClick() + await Utils.sleep(2000); + let allSelect: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(200); + allSelect.click() + await Utils.sleep(1000); + + let copy: Component = await driver.findComponent(ON.text('复制')) + await Utils.sleep(200); + copy.click() + await Utils.sleep(1000); + + let getData: Component = await driver.findComponent(ON.id('getData')) + await Utils.sleep(200); + getData.click() + await Utils.sleep(1500); + + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0320 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0330 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0330 + * @tc.desc Text组件包含span子组件设置文本断行 + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0330', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0330 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0330"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text: Component = await driver.findComponent(ON.id('text')) + await Utils.sleep(1000); + text.longClick() + await Utils.sleep(2000); + let allSelect: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(200); + allSelect.click() + await Utils.sleep(1000); + + let copy: Component = await driver.findComponent(ON.text('复制')) + await Utils.sleep(200); + copy.click() + await Utils.sleep(1000); + + let getData: Component = await driver.findComponent(ON.id('getData')) + await Utils.sleep(200); + getData.click() + await Utils.sleep(1500); + + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0330 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0340 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0340 + * @tc.desc Text组件包含span子组件设置文本省略位置 + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0340', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0340 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0340"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text: Component = await driver.findComponent(ON.id('text')) + await Utils.sleep(1000); + text.longClick() + await Utils.sleep(2000); + let allSelect: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(200); + allSelect.click() + await Utils.sleep(1000); + + let copy: Component = await driver.findComponent(ON.text('复制')) + await Utils.sleep(200); + copy.click() + await Utils.sleep(1000); + + let getData: Component = await driver.findComponent(ON.id('getData')) + await Utils.sleep(200); + getData.click() + await Utils.sleep(1500); + + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0340 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0350 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0350 + * @tc.desc Text组件包含span子组件设置文本折行 + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0350', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0350 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0350"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text: Component = await driver.findComponent(ON.id('text')) + await Utils.sleep(1000); + text.longClick() + await Utils.sleep(2000); + let allSelect: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(200); + allSelect.click() + await Utils.sleep(1000); + + let copy: Component = await driver.findComponent(ON.text('复制')) + await Utils.sleep(200); + copy.click() + await Utils.sleep(1000); + + let getData: Component = await driver.findComponent(ON.id('getData')) + await Utils.sleep(200); + getData.click() + await Utils.sleep(1500); + + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0350 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0360 + * @tc.name SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0360 + * @tc.desc Text组件包含span子组件设置背景颜色 + */ + it('SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0360', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0360 start.`); + Settings.createWindow("testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0360"); + await Utils.sleep(1500); + let driver = Driver.create(); + let allow: Component = await driver.findComponent(ON.text('仅本次允许')) + if (allow) { + allow.click() + await Utils.sleep(1000); + } + let text: Component = await driver.findComponent(ON.id('text')) + await Utils.sleep(1000); + text.longClick() + await Utils.sleep(2000); + let allSelect: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(200); + allSelect.click() + await Utils.sleep(1000); + + let copy: Component = await driver.findComponent(ON.text('复制')) + await Utils.sleep(200); + copy.click() + await Utils.sleep(1000); + + let read = await driver.findComponent(ON.id('getData')); + await read.click(); + await Utils.sleep(1500); + + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_Text_Copy_Attribute_0360 finish.`); + done() + }) + + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextEditMenuOptionsTest/UIComponentTextEditMenuOptions.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextEditMenuOptionsTest/UIComponentTextEditMenuOptions.test.ets new file mode 100644 index 00000000..5e843eb0 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextEditMenuOptionsTest/UIComponentTextEditMenuOptions.test.ets @@ -0,0 +1,501 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton, UiWindow } from '@ohos.UiTest' + +export default function UIComponentTextEditMenuOptions() { + + describe('UIComponentTextEditMenuOptions', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0030 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0030 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0030 start.`); + Settings.createWindow("testability/pages/UiComponentTextEditMeauOptions/UiComponentTextEditMeauOptions0030") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextEditMeauOptions0030text')); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0030 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0040 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0040 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0040") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0040_txArea')); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(500); + let selectMoreOrBackButton: Component = await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await selectMoreOrBackButton.click(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0040 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0050 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0050 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0050 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0050") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0050_txArea')); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(500); + let selectMoreOrBackButton: Component = await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await selectMoreOrBackButton.click(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0050 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0060 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0060 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0060 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0060_txArea')); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(500); + let selectMoreOrBackButton: Component = await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await selectMoreOrBackButton.click(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0060 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0070 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0070 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0060_txArea')); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(500); + for (let index = 0; index < 5; index++) { + let selectMoreOrBackButton: Component = await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await Utils.sleep(300); + await selectMoreOrBackButton.click(); + await Utils.sleep(500); + } + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0070 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0080 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0080 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0080', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0080 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0060_txArea')); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(500); + let selectMoreOrBackButton: Component = await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await Utils.sleep(500); + let point = await selectMoreOrBackButton.getBounds(); + await selectMoreOrBackButton.click(); + await Utils.sleep(1000); + await driver.click(point.right + 30, point.top - 20) + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0080 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0090 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0090 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0090', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0090 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0090") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0090_txArea')); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(500); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll.click(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0090 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0100 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0100 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0060_txArea')); + let point = await textArea.getBoundsCenter(); + await driver.drag(point.x - 100, point.y, point.x, point.y + 50) + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMEAUOPTIONS_0100 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITIMENUOPTIONS_0110 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITIMENUOPTIONS_0110 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITIMENUOPTIONS_0110', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITIMENUOPTIONS_0110 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0110_txArea')); + await Utils.sleep(500); + await textArea.longClick(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITIMENUOPTIONS_0110 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0120 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0120 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0120 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0110_txArea')); + await Utils.sleep(500); + await textArea.longClick(); + await Utils.sleep(500); + await driver.triggerKey(2082); + await Utils.sleep(1000); + Settings.switchLocales(); + await Utils.sleep(500); + await textArea.longClick(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0120 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITIENUOPTIONS_0140 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITIENUOPTIONS_0140 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITIENUOPTIONS_0140', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITIENUOPTIONS_0140 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0110_txArea')); + await Utils.sleep(500); + await textArea.longClick(); + await Utils.sleep(500); + let selectMoreOrBackButton2: Component = await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await selectMoreOrBackButton2.click(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITIENUOPTIONS_0140 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0150 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0150 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0150', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0150 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0150") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0150_txArea')); + await Utils.sleep(500); + await textArea.longClick(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0150 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0160 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0160 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0160', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0160 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0160") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0160_txArea')); + await Utils.sleep(500); + await textArea.longClick(); + await Utils.sleep(500); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll.click(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0160 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0170 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0170 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0170', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0170 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0170") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0170_txArea')); + await Utils.sleep(500); + await textArea.longClick(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0170 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0180 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0180 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0180', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0170 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0180") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textEditMenuOptions0180_txInput')); + await Utils.sleep(500); + await textInput.click(); + await Utils.sleep(500); + await textInput.doubleClick(); + await Utils.sleep(1000); + await textInput.longClick(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0180 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0190 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0190 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0190', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0190 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0190") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textEditMenuOptions0190_txInput')); + await Utils.sleep(500); + await textInput.longClick(); + await Utils.sleep(500); + let selectMoreOrBackButton2: Component= await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await selectMoreOrBackButton2.click(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0190 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0200 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0200 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0200', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0200 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0180") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0180_txArea')); + await Utils.sleep(500); + await textArea.click(); + await Utils.sleep(500); + await textArea.click(); + await Utils.sleep(500); + await driver.triggerKey(2082); + await Utils.sleep(500); + await textArea.longClick(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0200 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0220 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0220 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0220', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0220 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0180") + await Utils.sleep(500); + let driver: Driver = Driver.create(); + await driver.delayMs(500); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0180_txArea')); + await Utils.sleep(500); + await textArea.longClick(); + await Utils.sleep(500); + let selectMoreOrBackButton2: Component= await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await selectMoreOrBackButton2.click(); + await Utils.sleep(500); + await Settings.changeOrientation(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(500); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0220 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0230 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0230 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0230', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0230 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0180") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0180_txArea')); + await Utils.sleep(500); + let point = await textArea.getBoundsCenter(); + await driver.mouseClick(point, MouseButton.MOUSE_BUTTON_RIGHT); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0230 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0260 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0260 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0260', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0260 start.`); + Settings.createWindow("testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0260") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textEditMenuOptions0260_tx')); + await Utils.sleep(500); + await textArea.longClick(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_EDITMENUOPTIONS_0260 finish.`); + done(); + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextInputDeleteCallbackInterfaceTest/UIComponentTextInputDeleteCallbackInterface001.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextInputDeleteCallbackInterfaceTest/UIComponentTextInputDeleteCallbackInterface001.test.ets new file mode 100644 index 00000000..70aefe31 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextInputDeleteCallbackInterfaceTest/UIComponentTextInputDeleteCallbackInterface001.test.ets @@ -0,0 +1,691 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, MouseButton, ON } from '@ohos.UiTest' + +/* + * SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0040:onWillInsert 文档测试 + * + * Settings.createWindow(config.url): + * 创建窗口,更改窗口基本配置,更改方式详见model/Settings createWindow方法 + * + * windowSnap.snapShot(globalThis.context): + * 窗口截屏&图片文件保存,存储在设备端 + * 存储文件固定,单挑用例执行后覆盖,用于自动化UI对比 + * 支持调试更改文件名为时间戳格式,更改model/snapShot createAndGetFile方法 注释L35,放开L32,L33 + * + * Logger日志使用方法: + * import Logger form './model/Logger' + * Logger.info(TAG,`config = ${config}, err = ${JSON.stringify(exception)}`) + * */ + +export default function UIComponentTextInputDeleteCallbackInterface001() { + + describe('UIComponentTextInputDeleteCallbackInterface001', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0040 + * @tc.desc textInput test onWillInsert return false + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0040 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface001") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface001_textInput_001')) + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(500) + await driver?.inputText({ + x: 200, y: 50 + }, "T") + await Utils.sleep(500) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0040 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0050 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0050 + * @tc.desc textInput test onWillInsert return true + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0050 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface002") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface002_textInput_001')) + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(500) + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await driver?.inputText({ + x: 80, y: point.y + }, "T") + await Utils.sleep(500) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0050 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0060 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0060 + * @tc.desc textInput test onWillInsert return false + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0060 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface001") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface001_textInput_001')) + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(500) + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await driver?.inputText({ + x: 80, y: point.y + }, "T") + await Utils.sleep(500) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0060 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0070 + * @tc.desc textInput test onWillInsert return true + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0070 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface002") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface002_textInput_001')) + await Utils.sleep(500) + await textInput?.longClick() + await Utils.sleep(500) + let selectAll: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(500) + await selectAll?.click() + await Utils.sleep(500) + await driver?.inputText({ + x: 20, y: 50 + }, "T") + await Utils.sleep(500) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0070 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0080 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0080 + * @tc.desc textInput test onWillInsert return false + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0080', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0080 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface001") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface001_textInput_001')) + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(500) + //ctrl + a + await driver?.triggerCombineKeys(2072, 2017) + await Utils.sleep(500) + + await driver?.inputText({ + x: 200, y: 50 + }, "T") + await Utils.sleep(500) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0080 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0090 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0090 + * @tc.desc textInput test onDidInsert + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0090', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0090 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface003") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface003_textInput_001')) + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(500) + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await driver?.inputText({ + x: 80, y: point.y + }, "T") + await Utils.sleep(500) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0090 finish.`); + done() + }) + + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0100 + * @tc.desc textInput test onDidInsert + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0100 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface003") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface003_textInput_001')) + await Utils.sleep(500) + await textInput?.longClick() + await Utils.sleep(500) + let selectAll: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(500) + await selectAll?.click() + await Utils.sleep(500) + await driver?.inputText({ + x: 20, y: 50 + }, "T") + await Utils.sleep(500) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0100 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0110 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0110 + * @tc.desc textInput test onWillDelete return true + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0110', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0110 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface004") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface004_textInput_001')) + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(500) + await driver?.triggerKey(2055) + await Utils.sleep(500) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0110 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0120 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0120 + * @tc.desc textInput test onWillDelete return false + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0120 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface005") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface005_textInput_001')) + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(1000) + await driver?.triggerKey(2055) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0120 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0130 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0130 + * @tc.desc textInput test onWillDelete return true & select Text + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0130', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0130 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface004") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface004_textInput_001')) + await Utils.sleep(500) + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await driver?.drag(20, point.y, 80, point.y) + await Utils.sleep(1000) + await driver?.triggerKey(2055) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0130 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0140 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0140 + * @tc.desc textInput test onWillDelete return false & select Text + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0140', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0140 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface005") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface005_textInput_001')) + await Utils.sleep(500) + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await driver?.drag(20, point.y, 80, point.y) + await Utils.sleep(1000) + await driver?.triggerKey(2055) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0140 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0150 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0150 + * @tc.desc textInput test onDidDelete + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0150', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0150 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface006") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface006_textInput_001')) + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(1000) + await driver?.triggerKey(2055) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0150 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0160 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0160 + * @tc.desc textInput test onDidDelete & select Text + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0160', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0160 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface006") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface006_textInput_001')) + await Utils.sleep(500) + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await driver?.drag(20, point.y, 80, point.y) + await Utils.sleep(1000) + await driver?.triggerKey(2055) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0160 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0170 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0170 + * @tc.desc textInput test all event & willInsert return true & onWillDelete return true + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0170', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0170 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface007") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface007_textInput_001')) + await Utils.sleep(500) + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await driver?.drag(20, point.y, 80, point.y) + await Utils.sleep(1000) + await driver?.inputText({ + x: 40, y: point.y + }, "T") + await Utils.sleep(1000) + await driver?.triggerKey(2055) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0170 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0180 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0180 + * @tc.desc textInput test all event & willInsert return false & onWillDelete return true + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0180', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0180 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface008") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface008_textInput_001')) + await Utils.sleep(500) + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await driver?.drag(20, point.y, 80, point.y) + await Utils.sleep(1000) + await driver?.inputText({ + x: 40, y: point.y + }, "T") + await Utils.sleep(1000) + await driver?.triggerKey(2055) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0180 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0190 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0190 + * @tc.desc textInput test all event & willInsert return true & onWillDelete return false + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0190', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0190 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface009") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface009_textInput_001')) + await Utils.sleep(500) + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await driver?.drag(20, point.y, 80, point.y) + await Utils.sleep(1000) + await driver?.inputText({ + x: 40, y: point.y + }, "T") + await Utils.sleep(1000) + await driver?.triggerKey(2055) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0190 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0200 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0200 + * @tc.desc textInput test all event & willInsert return false & onWillDelete return false + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0200', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0190 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0010") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface0010_textInput_001')) + await Utils.sleep(500) + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await driver?.drag(20, point.y, 80, point.y) + await Utils.sleep(1000) + await driver?.inputText({ + x: 40, y: point.y + }, "T") + await Utils.sleep(1000) + await driver?.triggerKey(2055) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0200 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0210 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0210 + * @tc.desc textInput test all event & textIndent and type + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0210', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0210 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0011") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface0011_textInput_001')) + let button: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface0011_button_001')) + await Utils.sleep(500) + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(500) + await driver?.triggerKey(2055) + await Utils.sleep(500) + await driver?.inputText({ + x: 40, y: point.y + }, "T") + await Utils.sleep(500) + await button?.click() + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(500) + await driver?.triggerKey(2055) + await Utils.sleep(500) + await driver?.inputText({ + x: 80, y: point.y + }, "T") + await Utils.sleep(500) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0210 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0220 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0220 + * @tc.desc textInput test all event & textFlow and style + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0220', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0220 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0012") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface0012_textInput_001')) + let button: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface0012_button_001')) + await Utils.sleep(500) + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(500) + await driver?.triggerKey(2055) + await Utils.sleep(500) + await driver?.inputText({ + x: 40, y: point.y + }, "T") + await Utils.sleep(500) + await button?.click() + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(500) + await driver?.triggerKey(2055) + await Utils.sleep(500) + await driver?.inputText({ + x: 40, y: point.y + }, "T") + await Utils.sleep(500) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0220 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0230 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0230 + * @tc.desc textInput test all event & darg 、 change text 、delete + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0230', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0230 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface007") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface007_textInput_001')) + await Utils.sleep(500) + await textInput?.longClick() + await Utils.sleep(500) + let selectAll: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(500) + await selectAll?.click() + await Utils.sleep(500) + let cut: Component = await driver.findComponent(ON.text('剪切')) + await Utils.sleep(500) + await cut?.click() + await Utils.sleep(500) + await driver?.triggerCombineKeys(2072, 2038) + await Utils.sleep(500) + windowSnap.snapShot() + await Utils.sleep(500) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0230 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0250 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0250 + * @tc.desc textInput test all event & [A-Z] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0250', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0250 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0013") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface0013_textInput_001')) + await Utils.sleep(500) + await textInput?.inputText("15") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0230 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0260 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0260 + * @tc.desc textInput test all event & \n + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0260', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0260 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0014") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface0014_textInput_001')) + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(500) + for (let index = 0; index < 4; index++) { + await Utils.sleep(500) + await driver?.triggerKey(2054) + } + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0260 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0290 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0290 + * @tc.desc textInput test all event & modifer + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0290', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0290 start.`); + Settings.createWindow("testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0015") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextInputDeleteCallbackInterface0015_textInput_001')) + await Utils.sleep(500) + await textInput?.inputText("T") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0290 finish.`); + done() + }) + + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextRefactorAdjustMentInterfaceTest/UIComponentTextRefactorAdjustMentInterface001.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextRefactorAdjustMentInterfaceTest/UIComponentTextRefactorAdjustMentInterface001.test.ets new file mode 100644 index 00000000..e3b9fc91 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextRefactorAdjustMentInterfaceTest/UIComponentTextRefactorAdjustMentInterface001.test.ets @@ -0,0 +1,698 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, MouseButton, ON } from '@ohos.UiTest' + +/* + * Settings.createWindow(config.url): + * 创建窗口,更改窗口基本配置,更改方式详见model/Settings createWindow方法 + * + * windowSnap.snapShot(globalThis.context): + * 窗口截屏&图片文件保存,存储在设备端 + * 存储文件固定,单挑用例执行后覆盖,用于自动化UI对比 + * 支持调试更改文件名为时间戳格式,更改model/snapShot createAndGetFile方法 注释L35,放开L32,L33 + * + * Logger日志使用方法: + * import Logger form './model/Logger' + * Logger.info(TAG,`config = ${config}, err = ${JSON.stringify(exception)}`) + * */ + +export default function UIComponentTextRefactorAdjustMentInterface001() { + + describe('UIComponentTextRefactorAdjustMentInterface001', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0030 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0030 + * @tc.desc doc. + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0030 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface001") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface001_textInput_001')) + await Utils.sleep(500) + await textInput?.longClick() + await Utils.sleep(500) + let selectAll: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(500) + await selectAll?.click() + await Utils.sleep(500) + await textInput?.click() + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await driver?.drag(point.x, point.y, 0, point.y) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0030 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0040 + * @tc.desc driver inputText + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0040 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface002") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface002_textInput_001')) + await Utils.sleep(500) + await textInput?.click() + await Utils.sleep(500) + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await driver?.inputText({ + x: 50, y: point.y + }, "输入文本") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0040 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0070 + * @tc.desc mouseClick. + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0070 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface003") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface003_textInput_001')) + let textInputTwo: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface003_textInput_002')) + await Utils.sleep(500) + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await driver?.mouseClick({ + x: point.x - 100, y: point.y + }, MouseButton.MOUSE_BUTTON_RIGHT) + await Utils.sleep(1000) + let pointTwo = await textInputTwo?.getBoundsCenter() + await Utils.sleep(500) + await driver?.mouseClick({ + x: pointTwo.x - 100, y: pointTwo.y + }, MouseButton.MOUSE_BUTTON_LEFT) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(500) + await driver?.click(50, 200) + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0070 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0090 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0090 + * @tc.desc Multiple selections + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0090', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0090 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface003") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface003_textInput_001')) + let textInputTwo: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface003_textInput_002')) + await Utils.sleep(500) + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await driver?.drag(point.x - 100, point.y, 0, point.y) + await Utils.sleep(1000) + await textInputTwo?.click() + await Utils.sleep(500) + let pointTwo = await textInputTwo?.getBoundsCenter() + await Utils.sleep(500) + await driver?.drag(pointTwo.x - 100, pointTwo.y, 0, pointTwo.y) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0090 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0100 + * @tc.desc mouse select all + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0100 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface003") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface003_textInput_001')) + let textInputTwo: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface003_textInput_002')) + await Utils.sleep(500) + await textInput?.longClick() + let point = await textInput?.getBoundsCenter() + await Utils.sleep(1000) + await driver?.mouseClick({ + x: point.x + 100, y: point.y + 60 + }, MouseButton.MOUSE_BUTTON_LEFT) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(500) + await driver?.click(50, 200) + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0100 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0150 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0150 + * @tc.desc mouse darg change point + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0150', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0150 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface003") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface003_textInput_001')) + let textInputTwo: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface003_textInput_002')) + await Utils.sleep(500) + await textInput?.longClick() + let point = await textInput?.getBoundsCenter() + await Utils.sleep(1000) + await driver?.drag(point.x, point.y, point.x - 80, point.y) + await Utils.sleep(500) + await textInput?.longClick() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0150 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0180 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0180 + * @tc.desc mouse darg change point + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0180', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0180 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface003") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface003_textInput_001')) + let textInputTwo: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface003_textInput_002')) + await Utils.sleep(500) + await textInput?.longClick() + let point = await textInput?.getBoundsCenter() + await Utils.sleep(1000) + await driver?.drag(point.x, point.y, point.x - 80, point.y) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0180 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0200 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0200 + * @tc.desc mouse darg change point & inputtext + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0200', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0200 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface003") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface003_textInput_001')) + let textInputTwo: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface003_textInput_002')) + await Utils.sleep(500) + await textInput?.longClick() + let point = await textInput?.getBoundsCenter() + await Utils.sleep(1000) + await driver?.drag(point.x, point.y, point.x - 80, point.y) + await Utils.sleep(500) + await driver?.inputText({ + x: point.x - 80, y: point.y + }, "插入文本") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0200 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0220 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0220 + * @tc.desc mouse darg change point & inputtext + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0220', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0220 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface003") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface003_textInput_001')) + let textInputTwo: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface003_textInput_002')) + await Utils.sleep(500) + await textInput?.longClick() + let selectAll: Component = await driver.findComponent(ON.text('全选')) + await Utils.sleep(500) + await selectAll?.click() + await Utils.sleep(500) + let cutAll: Component = await driver.findComponent(ON.text('剪切')) + await Utils.sleep(500) + await cutAll.click() + let point = await textInput?.getBoundsCenter() + await Utils.sleep(500) + await driver?.doubleClick(0, point.y) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0220 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0460 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0460 + * @tc.desc darg + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0460', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0460 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface003") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let textInput: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface003_textInput_002')) + await Utils.sleep(500) + await textInput?.longClick() + await Utils.sleep(1000) + await textInput?.longClick() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0460 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_01 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_01 + * @tc.desc deleteSpans[0,1] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_01', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_01 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface004") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface004_button_001')) + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_01 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_02 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_02 + * @tc.desc deleteSpans[1,2] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_02', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_02 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface004") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface004_button_002')) + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_02 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_03 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_03 + * @tc.desc deleteSpans[100,101] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_03', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_03 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface004") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface004_button_003')) + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_03 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_04 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_04 + * @tc.desc deleteSpans[2,1] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_04', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_04 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface004") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface004_button_004')) + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_04 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_05 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_05 + * @tc.desc deleteSpans[-1,-1] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_05', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_05 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface004") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface004_button_005')) + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9992_05 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9993 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9993 + * @tc.desc getParagraphs + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9993', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9993 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface005") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface005_button_01')) + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9993 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_01 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_01 + * @tc.desc select[0,1] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_01', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_01 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface006") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface006_button_001')) + let rich: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface006_richEditor_001')) + await Utils.sleep(1000) + await rich?.click() + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_01 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_02 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_02 + * @tc.desc select[1,2] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_02', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_02 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface006") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface006_button_002')) + let rich: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface006_richEditor_001')) + await Utils.sleep(1000) + await rich?.click() + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_02 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_03 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_03 + * @tc.desc select[100,101] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_03', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_03 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface006") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface006_button_003')) + let rich: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface006_richEditor_001')) + await Utils.sleep(1000) + await rich?.click() + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_03 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_04 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_04 + * @tc.desc select[2,1] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_04', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_04 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface006") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface006_button_004')) + let rich: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface006_richEditor_001')) + await Utils.sleep(1000) + await rich?.click() + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_04 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_05 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_05 + * @tc.desc select[-1,-1] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_05', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_05 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface006") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface006_button_005')) + let rich: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface006_richEditor_001')) + await Utils.sleep(1000) + await rich?.click() + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9994_05 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_01 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_01 + * @tc.desc toStyledString[0,1] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_01', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_01 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface007") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface007_button_001')) + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_01 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_02 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_02 + * @tc.desc toStyledString[1,2] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_02', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_02 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface007") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface007_button_002')) + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_02 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_03 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_03 + * @tc.desc toStyledString[100,101] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_03', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_03 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface007") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface007_button_003')) + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_03 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_04 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_04 + * @tc.desc toStyledString[2,1] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_04', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_04 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface007") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface007_button_004')) + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_04 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_05 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_05 + * @tc.desc toStyledString[-1,-1] + */ + it('SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_05', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_05 start.`); + Settings.createWindow("testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface007") + await Utils.sleep(500) + let driver: Driver = Driver.create() + let button: Component = + await driver.findComponent(ON.id('UIComponentTextRefactorAdjustMentInterface007_button_005')) + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_RICHEDITOR_INTERFACE_9995_05 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSearchActionInterfaceTest/UIComponentTextSearchActionInterface001.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSearchActionInterfaceTest/UIComponentTextSearchActionInterface001.test.ets new file mode 100644 index 00000000..1528abb4 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSearchActionInterfaceTest/UIComponentTextSearchActionInterface001.test.ets @@ -0,0 +1,184 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, MouseButton, ON } from '@ohos.UiTest' + +/* + * SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0010:设置文本颜色 + * + * Settings.createWindow(config.url): + * 创建窗口,更改窗口基本配置,更改方式详见model/Settings createWindow方法 + * + * windowSnap.snapShot(globalThis.context): + * 窗口截屏&图片文件保存,存储在设备端 + * 存储文件固定,单挑用例执行后覆盖,用于自动化UI对比 + * 支持调试更改文件名为时间戳格式,更改model/snapShot createAndGetFile方法 注释L35,放开L32,L33 + * + * Logger日志使用方法: + * import Logger form './model/Logger' + * Logger.info(TAG,`config = ${config}, err = ${JSON.stringify(exception)}`) + * */ + +export default function UIComponentTextSearchActionInterface001() { + + describe('UIComponentTextSearchActionInterface001', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0040 + * @tc.desc search test back + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0040 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface001") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchActionInterface001_search_001')) + await Utils.sleep(1000) + await search?.inputText("这是测试文本,This is test text.") + await Utils.sleep(500) + await search?.longClick() + await Utils.sleep(1000) + await driver?.pressBack() + await Utils.sleep(1000) + await driver?.pressBack() + await Utils.sleep(1000) + await driver?.pressBack() + await Utils.sleep(2000) + windowSnap.snapShot() + await Utils.sleep(2000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0040 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0060 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0060 + * @tc.desc search test tab + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0060 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface001") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchActionInterface001_search_001')) + await Utils.sleep(1000) + await search?.click() + await Utils.sleep(500) + await driver?.triggerKey(2049) + await Utils.sleep(500) + await driver?.triggerKey(2049) + await Utils.sleep(1000) + await driver?.mouseClick({ + x: 100, y: 200 + }, MouseButton.MOUSE_BUTTON_RIGHT) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0060 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0100 + * @tc.desc search test tab + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0100 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface002") + let driver: Driver = Driver.create() + let searchOne: Component = await driver.findComponent(ON.id('UIComponentTextSearchActionInterface002_search_001')) + let searchTwo: Component = await driver.findComponent(ON.id('UIComponentTextSearchActionInterface002_search_002')) + await Utils.sleep(1000) + await searchOne?.longClick() + await Utils.sleep(500) + await searchTwo?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0100 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0120 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0120 + * @tc.desc search test Customize keyboard + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0100 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface003") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchActionInterface003_search_001')) + await Utils.sleep(1000) + await search?.inputText("123456789") + await Utils.sleep(500) + await search?.longClick() + await Utils.sleep(1000) + await driver?.pressBack() + await Utils.sleep(1000) + await search?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0120 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0130 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0130 + * @tc.desc search test Customize keyboard + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0130', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0130 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface003") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchActionInterface003_search_001')) + await Utils.sleep(1000) + await search?.inputText("123456789") + await Utils.sleep(500) + let point = await search?.getBoundsCenter() + await Utils.sleep(500) + await driver?.click((point.x * 2) - 30,point.y) + await Utils.sleep(1000) + await search?.inputText("12345") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ACTION_0130 finish.`); + done() + }) + + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSearchInterfaceTest/UIComponentTextSearchInterface001.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSearchInterfaceTest/UIComponentTextSearchInterface001.test.ets new file mode 100644 index 00000000..1f2ba322 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSearchInterfaceTest/UIComponentTextSearchInterface001.test.ets @@ -0,0 +1,1375 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, MouseButton, ON } from '@ohos.UiTest' + +/* + * SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0010:设置文本颜色 + * + * Settings.createWindow(config.url): + * 创建窗口,更改窗口基本配置,更改方式详见model/Settings createWindow方法 + * + * windowSnap.snapShot(globalThis.context): + * 窗口截屏&图片文件保存,存储在设备端 + * 存储文件固定,单挑用例执行后覆盖,用于自动化UI对比 + * 支持调试更改文件名为时间戳格式,更改model/snapShot createAndGetFile方法 注释L35,放开L32,L33 + * + * Logger日志使用方法: + * import Logger form './model/Logger' + * Logger.info(TAG,`config = ${config}, err = ${JSON.stringify(exception)}`) + * */ + +export default function UIComponentTextSearchInterface001() { + + describe('UIComponentTextSearchInterface001', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_EVASIVE_0190 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_EVASIVE_0190 + * @tc.desc search InputMethod EVASIVE & view top + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_EVASIVE_0190', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_EVASIVE_0190 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface001") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface001_button_001')) + await Utils.sleep(500) + await search?.click() + await Utils.sleep(1000) + Settings?.changeOrientation() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Settings?.changeOrientation() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_EVASIVE_0190 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_EVASIVE_0200 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_EVASIVE_0200 + * @tc.desc search InputMethod EVASIVE & view center + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_EVASIVE_0200', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_EVASIVE_0200 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface001") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface001_button_002')) + await Utils.sleep(500) + await search?.click() + await Utils.sleep(1000) + Settings?.changeOrientation() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Settings?.changeOrientation() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_EVASIVE_0200 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_EVASIVE_0210 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_EVASIVE_0210 + * @tc.desc search InputMethod EVASIVE & view center + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_EVASIVE_0210', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_EVASIVE_0210 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface001") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface001_button_003')) + await Utils.sleep(500) + await search?.click() + await Utils.sleep(1000) + Settings?.changeOrientation() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Settings?.changeOrientation() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_EVASIVE_0210 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0010 + * @tc.desc search change textFont + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0010 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface002") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface002_button_001')) + await Utils.sleep(500) + await search?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0010 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0020_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0020_1 + * @tc.desc search change size + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0020_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0020_1 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol020") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol020_button_001')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0020_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0020_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0020_2 + * @tc.desc search change size + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0020_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0020_2 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol020") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol020_button_002')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0020_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0020_3 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0020_3 + * @tc.desc search change size + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0020_3', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0020_3 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol020") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol020_button_003')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0020_3 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0030_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0030_1 + * @tc.desc search change color + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0030_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0030_1 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol030") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol030_button_001')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0030_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0030_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0030_2 + * @tc.desc search change color + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0030_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0030_2 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol030") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol030_button_002')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0030_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0030_3 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0030_3 + * @tc.desc search change color + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0030_3', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0030_3 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol030") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol030_button_003')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0030_3 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0040 + * @tc.desc search change onSubmit + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0040 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol040") + let driver: Driver = Driver.create() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0040 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0050 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0050 + * @tc.desc search change CancelButtonStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0050 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol050") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0050 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_1 + * @tc.desc search change size + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_1 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol060") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol060_button_001')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_2 + * @tc.desc search change size + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_2 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol060") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol060_button_002')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_3 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_3 + * @tc.desc search change size + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_3', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_3 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol060") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol060_button_003')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_3 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_4 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_4 + * @tc.desc search change size + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_4', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_4 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol060") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol060_button_004')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0060_4 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0070_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0070_1 + * @tc.desc search change size + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0070_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0070_1 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol070") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol070_button_001')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0070_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0070_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0070_2 + * @tc.desc search change size + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0070_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0070_2 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol070") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol070_button_002')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0070_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0070_3 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0070_3 + * @tc.desc search change size + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0070_3', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0070_3 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol070") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol070_button_003')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0070_3 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0080_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0080_1 + * @tc.desc cancel change color + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0080_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0080_1 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol080") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol080_button_001')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0080_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0080_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0080_2 + * @tc.desc cancel change color + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0080_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0080_2 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol080") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol080_button_002')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0080_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0080_3 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0080_3 + * @tc.desc cancel change color + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0080_3', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0080_3 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol080") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Symbol080_button_003')) + await Utils.sleep(500) + await search.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0080_3 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0090 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0090 + * @tc.desc search change search_icon is null + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0090', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0090 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface003") + let driver: Driver = Driver.create() + let button: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface003_button_001')) + await Utils.sleep(500) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0090 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0100 + * @tc.desc search change cancel_icon is null + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0100 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface004") + let driver: Driver = Driver.create() + let button: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface004_button_001')) + await Utils.sleep(500) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0100 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0110 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0110 + * @tc.desc search change search_icon is null-icon + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0110', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0110 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface003") + let driver: Driver = Driver.create() + let button: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface003_button_001')) + await Utils.sleep(500) + await button?.click() + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0110 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0120 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0120 + * @tc.desc search change cancel_icon is null-icon + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0120 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface004") + let driver: Driver = Driver.create() + let button: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface004_button_001')) + await Utils.sleep(500) + await button?.click() + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0120 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0130 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0130 + * @tc.desc search change cancel_icon and search_icon is null + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0130', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0130 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface005") + let driver: Driver = Driver.create() + let button: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface005_button_001')) + await Utils.sleep(500) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0130 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0140 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0140 + * @tc.desc search change fontsize + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0140', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0140 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface006") + let driver: Driver = Driver.create() + let button: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface006_button_001')) + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface006_search_001')) + await Utils.sleep(500) + await button?.click() + await Utils.sleep(1000) + await search?.inputText("this is test text") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0140 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0150 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0150 + * @tc.desc search change weight + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0150', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0150 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface007") + let driver: Driver = Driver.create() + let button: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface007_button_001')) + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface007_search_001')) + await Utils.sleep(500) + await button?.click() + await Utils.sleep(1000) + await search?.inputText("this is test text") + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0150 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0160 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0160 + * @tc.desc search Focus to cancel button + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0160', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0160 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface008") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface008_search_001')) + await Utils.sleep(500) + await search?.click() + await Utils.sleep(1000) + await driver?.triggerKey(2049) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(500) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0160 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0170 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0170 + * @tc.desc search set icon size is 100 + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0170', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0170 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface009") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface009_search_001')) + let button: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface009_button_001')) + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + // for (let index = 0; index < 8; index++) { + // await driver?.triggerKey(2050) + // await Utils.sleep(500) + // } + // await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0170 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0180 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0180 + * @tc.desc search set enable = false + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0180', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0170 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0010") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0010_search_001')) + let button: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0010_button_001')) + await Utils.sleep(1000) + await search?.inputText("this is test text") + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + let point = await search?.getBoundsCenter() + await Utils.sleep(500) + await driver?.mouseClick({ + x: (point.x * 2) - 30, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(500) + await search?.click() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0180 finish.`); + done() + }) + + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0200 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0200 + * @tc.desc search setOrientation + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0200', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0170 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0010") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0010_search_001')) + let button: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0010_button_001')) + await Utils.sleep(1000) + await search?.inputText("this is test text") + await Utils.sleep(1000) + Settings?.changeOrientation() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(500) + Settings?.changeOrientation() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ICON_SYMBOL_0200 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0010 + * @tc.desc search setDirection + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0010 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0011") + let driver: Driver = Driver.create() + let button: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0011_button_001')) + await Utils.sleep(1000) + await button?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0010 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0030 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0030 + * @tc.desc search doubleClick + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0030 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0012") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0012_search_001')) + await Utils.sleep(1000) + await search?.inputText("this is test text.") + await Utils.sleep(1000) + let point = await search?.getBoundsCenter() + // await search?.doubleClick() + await driver?.doubleClick(point.x - 100, point.y) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0030 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0040 + * @tc.desc search drag + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0040 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0012") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0012_search_001')) + await Utils.sleep(1000) + await search?.inputText("this is test text.this is test text.this is test text.this is test text.") + await Utils.sleep(1000) + let point = await search?.getBoundsCenter() + await Utils.sleep(500) + await driver?.drag(point.x, point.y, 0, point.y) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0040 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0050_001 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0050_001 + * @tc.desc search longClick + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0050_001', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0050_001 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0012") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0012_search_001')) + await Utils.sleep(1000) + await search?.inputText("this is test text.this is test text.") + await Utils.sleep(1000) + await search?.longClick() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0050_001 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0050_002 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0050_002 + * @tc.desc search longClick + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0050_002', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0050_002 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0012") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0012_search_001')) + await Utils.sleep(1000) + await search?.inputText("this is test text.") + await Utils.sleep(1000) + let point = await search?.getBoundsCenter() + await Utils.sleep(500) + await driver?.longClick(point.x + 50, point.y) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0050_002 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0070 + * @tc.desc search delete/Backspace + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0070 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0012") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0012_search_001')) + await Utils.sleep(1000) + await search?.inputText("this is test text.this is test text.this is test text.this is test text") + await Utils.sleep(1000) + await driver?.triggerKey(2055) + await Utils.sleep(500) + //ctrl + A + await driver?.triggerCombineKeys(2072, 2017) + await Utils.sleep(1000) + await driver?.triggerKey(2055) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0070 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0080 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0080 + * @tc.desc search ctrl + A + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0080', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0080 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0012") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0012_search_001')) + await Utils.sleep(1000) + await search?.inputText("this is test text.this is test text.this is test text.this is test text") + await Utils.sleep(1000) + //ctrl + A + await driver?.triggerCombineKeys(2072, 2017) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0080 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0100_001 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0100_001 + * @tc.desc search test MouseButton + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0100_001', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0100_001 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0012") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0012_search_001')) + await Utils.sleep(1000) + await search?.inputText("this is test text.this is test text.this is test text.this is test text") + await Utils.sleep(1000) + let point = await search?.getBoundsCenter() + await Utils.sleep(500) + await driver?.mouseMoveTo({ + x: 50, y: point.y + 100 + }) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(500) + await driver?.click(100, 500) + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0100_001 finish.`); + done() + }) + + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0100_002 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0100_002 + * @tc.desc search test MouseButton + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0100_002', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0100_002 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0012") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0012_search_001')) + await Utils.sleep(500) + await search?.inputText("this is test text.this is test text.this is test text.this is test text") + await Utils.sleep(500) + let point = await search?.getBoundsCenter() + await Utils.sleep(500) + await driver?.mouseMoveTo({ + x: point.x, y: point.y + }) + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + await driver?.click(100, 500) + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0100_002 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0110 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0110 + * @tc.desc search test MouseButton + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0110', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0110 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0012") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0012_search_001')) + await Utils.sleep(500) + await search?.inputText("this is test text.this is test text.this is test text.this is test text") + await Utils.sleep(500) + let point = await search?.getBoundsCenter() + await Utils.sleep(500) + await driver?.mouseDrag({ + x: point.x, y: point.y + }, { + x: 0, y: point.y + }) + await Utils.sleep(1000) + await windowSnap.snapShot() + await Utils.sleep(1000) + await driver?.click(100, 500) + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERACTION_0110 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0200 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0200 + * @tc.desc search test carePotion + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0200', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0200 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Interface200") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('Interface200_search_001')) + let button: Component = await driver.findComponent(ON.id('Interface200_button_001')) + await Utils.sleep(1000) + await search.click() + await Utils.sleep(1000) + await button.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0200 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0460 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0460 + * @tc.desc search test caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0460', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0460 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0013") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0013_search_001')) + await Utils.sleep(1000) + await search?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0460 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0470 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0470 + * @tc.desc search test caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0470', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0470 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0014") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0014_search_001')) + await Utils.sleep(1000) + await search?.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0470 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0530 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0530 + * @tc.desc search test caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0530', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0530 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0530") + let driver: Driver = Driver.create() + await Utils.sleep(1000) + let search: Component = await driver.findComponent(ON.id('SearchUIComponentTextSearchInterface0530')) + await Utils.sleep(1000) + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa') + await Utils.sleep(1000) + await search.longClick() + await Utils.sleep(1000) + await windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0530 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0020 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0020 + * @tc.desc search test caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0020 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0020") + let driver: Driver = Driver.create() + await Utils.sleep(1000) + let search: Component = await driver.findComponent(ON.id('SearchUIComponentTextSearchInterface0020')) + await Utils.sleep(1000) + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa') + await Utils.sleep(1000) + await search.longClick() + await Utils.sleep(1000) + await driver.triggerKey(2055) + await Utils.sleep(1000) + await windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0020 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0030 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0030 + * @tc.desc search test caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0030 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0030"); + await Utils.sleep(2000); + let driver: Driver = Driver.create(); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0030')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000) + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0030 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0040 + * @tc.desc search test caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0040 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0040"); + let driver: Driver = Driver.create(); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0040')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(1000); + let all: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await all.click(); + await Utils.sleep(1000); + let copy: Component = await driver.findComponent(ON.text('复制')); + await Utils.sleep(100); + await copy.click(); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + let past: Component = await driver.findComponent(ON.text('粘贴')); + await Utils.sleep(100); + await past.click(); + await Utils.sleep(2000) + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0040 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0370 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0370 + * @tc.desc search test caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0370', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0370 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0370"); + await Utils.sleep(2000); + let driver: Driver = Driver.create(); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0370')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000) + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0370 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0390 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0390 + * @tc.desc search test caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0390', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0390 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0390"); + await Utils.sleep(2000); + let driver: Driver = Driver.create(); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0390')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000) + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0390 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0400 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0400 + * @tc.desc search test caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0400', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0400 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0400"); + await Utils.sleep(2000); + let driver: Driver = Driver.create(); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0400')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000) + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0400 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0410 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0410 + * @tc.desc search test caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0410', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0410 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0410"); + await Utils.sleep(2000); + let driver: Driver = Driver.create(); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0410')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000) + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0410 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0420 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0420 + * @tc.desc search test caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0420', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0420 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0420"); + await Utils.sleep(2000); + let driver: Driver = Driver.create(); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0420')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000) + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0420 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0430 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0430 + * @tc.desc search test caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0430', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0430 start.`); + Settings.createWindow("testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0430"); + await Utils.sleep(2000); + let driver: Driver = Driver.create(); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('UIComponentTextSearchInterface0430')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000) + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0430 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0360 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0360 + * @tc.desc Search: caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0360', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0360 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface"); + let driver: Driver = Driver.create(); + let btn: Component = await driver.findComponent(ON.id('textSelectionInterface_008')); + await btn.click(); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('textSelectionInterface_002')); + await Utils.sleep(1000); + await search.longClick(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0360 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0380 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0380 + * @tc.desc Search: caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0380', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0380 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface"); + let driver: Driver = Driver.create(); + let btn: Component = await driver.findComponent(ON.id('textSelectionInterface_007')); + await btn.click(); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('textSelectionInterface_002')); + await Utils.sleep(1000); + await search.longClick(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0380 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0440 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0440 + * @tc.desc Search: caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0440', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0440 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface"); + let driver: Driver = Driver.create(); + let btn: Component = await driver.findComponent(ON.id('textSelectionInterface_009')); + await btn.click(); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('textSelectionInterface_002')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0440 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0450 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0450 + * @tc.desc Search: caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0450', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0450 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface"); + let driver: Driver = Driver.create(); + let btn: Component = await driver.findComponent(ON.id('textSelectionInterface_004')); + await btn.click(); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('textSelectionInterface_002')); + await Utils.sleep(1000); + await search.longClick(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0450 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0480 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0480 + * @tc.desc Search: caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0480', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0480 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface"); + let driver: Driver = Driver.create(); + let btn: Component = await driver.findComponent(ON.id('textSelectionInterface_006')); + await btn.click(); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('textSelectionInterface_002')); + await Utils.sleep(1000); + await search.longClick(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0480 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0490 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0490 + * @tc.desc Search: caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0490', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0490 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface"); + let driver: Driver = Driver.create(); + let btn: Component = await driver.findComponent(ON.id('textSelectionInterface_005')); + await btn.click(); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('textSelectionInterface_002')); + await Utils.sleep(1000); + await search.longClick(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0490 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0500 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0500 + * @tc.desc Search: caretStyle + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0500', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0500 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface"); + let driver: Driver = Driver.create(); + let btn: Component = await driver.findComponent(ON.id('textSelectionInterface_003')); + await btn.click(); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('textSelectionInterface_002')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_INTERFACE_0500 finish.`); + done(); + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSelectionActionTest/UIComponentTextSelectionAction.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSelectionActionTest/UIComponentTextSelectionAction.test.ets new file mode 100644 index 00000000..91a8ae09 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSelectionActionTest/UIComponentTextSelectionAction.test.ets @@ -0,0 +1,947 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton, UiWindow } from '@ohos.UiTest' +import { text } from '@kit.ArkGraphics2D' + +export default function UIComponentTextSelectionAction() { + + describe('UIComponentTextSelectionAction', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0020 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0020 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0020 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test have drag'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0020 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0030 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0030 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0030 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await driver.delayMs(100); + await textInput.inputText("This test text") + await driver.delayMs(500); + await textInput.longClick(); + await Utils.sleep(4000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0030 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0040 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0040 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test longClick longClick'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(500); + let point = await textInput.getBoundsCenter() + await Utils.sleep(100); + await driver.click(point.x + 50, point.y); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0040 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0060 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0060 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0060 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInputtestdoubleClickdoubleClick,hdshhjj'); + await Utils.sleep(1000); + await textInput.doubleClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0060 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0070 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0070 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(500); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0070 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0110 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0110 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0110', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0110 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0110')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test TransitionEffect.OPACITY.animation'); + await Utils.sleep(500); + await textInput.click(); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(500); + // await driver.longClick(point.x,point.y); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_RIGHT); + await Utils.sleep(1500); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0110 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0120 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0120 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0120 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0120") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0120')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test '); + await Utils.sleep(500); + await textInput.longClick(); + await Utils.sleep(500); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0110 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0130 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0130 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0130', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0130 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test longClick longClick'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + let point = await textInput.getBoundsCenter(); + await driver.longClick(point.x + 50, point.y); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0130 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0140 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0140 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0140', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0140 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test longClick longClick'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + let point = await textInput.getBoundsCenter() + await driver?.click(point.x - 100, point.y); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0140 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0150 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0150 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0150', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0150 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test longClick inputText'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + let point = await textInput.getBoundsCenter(); + await driver.inputText(point, 'insert'); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0150 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0160 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0160 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0160', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0160 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0160") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0160')); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + let point = await textInput.getBoundsCenter(); + await driver.click(point.x, point.y); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0160 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0170 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0170 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0170', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0170 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test cut inputText'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(500); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(500); + await selectAll.click(); + await Utils.sleep(500); + let cut: Component = await driver.findComponent(ON.text('剪切')); + await Utils.sleep(500); + await cut.click(); + await Utils.sleep(500); + let point = await textInput.getBoundsCenter(); + await driver.click(point.x, point.y); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0170 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0180 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0180 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0180', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0180 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0180 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0320 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0320 + * @tc.desc Ctrl+A + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0320', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0320 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test text selectAll Ctrl+A'); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(100); + await driver.triggerCombineKeys(2072, 2017); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0320 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0330 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0330 + * @tc.desc Ctrl+C + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0330', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0330 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test text Copy Ctrl+C'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + await driver.triggerCombineKeys(2072, 2019); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0330 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0340 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0340 + * @tc.desc Ctrl+X + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0340', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0340 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test text cut Ctrl+X'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + await driver.triggerCombineKeys(2072, 2040); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0340 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0380 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0380 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0380', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0380 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test text menu enterKey'); + await Utils.sleep(500); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(1000); + await driver.mouseClick({ + x: point.y, y: point.y + }, MouseButton.MOUSE_BUTTON_RIGHT); + await Utils.sleep(1500); + await driver.triggerKey(2119); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0380 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0400 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0400 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0400', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0400 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test text menu delete Key'); + await Utils.sleep(500); + let point = await textInput.getBoundsCenter(); + let point1 = await textInput.getBounds(); + await Utils.sleep(1000); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_RIGHT); + await Utils.sleep(500); + await driver.triggerKey(2055); + await Utils.sleep(500); + await driver.mouseClick({ + x: point1.left, y: point.y + }, MouseButton.MOUSE_BUTTON_RIGHT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0400 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0410 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0410 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0410', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0410 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(500); + await textInput.inputText('TextInput:test text singLine'); + await Utils.sleep(500); + await textInput.click(); + await Utils.sleep(500); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0410 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0420 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0420 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0420', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0420 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(500); + await textInput.inputText('TextInput:test text singLine'); + await Utils.sleep(500); + await textInput.longClick(); + await Utils.sleep(500); + await driver.triggerKey(2081); + await Utils.sleep(500); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(1000); + await driver.drag(point.x, point.y, point.x - 100, point.y, 400) + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0420 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0430 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0430 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0430', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0430 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0430") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0430')); + await Utils.sleep(500); + await textInput.longClick(); + await Utils.sleep(500); + await driver.triggerKey(2081); + await Utils.sleep(500); + let point = await textInput.getBounds(); + await Utils.sleep(1000); + await driver.drag(point.left, point.top, point.right, point.bottom - 60, 400) + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0430 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0440 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0440 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0440', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0440 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0430") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0430')); + await Utils.sleep(500); + await driver.triggerKey(2082); + await Utils.sleep(500); + let point = await textInput.getBounds(); + await Utils.sleep(1000); + await driver.drag(point.right, point.bottom, point.left, point.top + 10, 400) + // await driver.mouseDrag({x:point.x-20,y:point.y},{x:point.x+30,y:point.y},500); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0440 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0450 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0450 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0450', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0450 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0430") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0430')); + await Utils.sleep(500); + await driver.triggerKey(2082); + await Utils.sleep(500); + let point = await textInput.getBounds(); + await Utils.sleep(1000); + await driver.drag(point.right, point.bottom, point.left, point.top + 10, 400) + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0450 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0490 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0490 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0490', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0490 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test copy inputText,this text'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(500); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(500); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_RIGHT); + await Utils.sleep(500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0490 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0500 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0500 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0500', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0500 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(500); + let driver: Driver = Driver.create(); + await driver.delayMs(500); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(500); + await textInput.inputText('TextInput:test copy&paste longPress inputText'); + await Utils.sleep(500); + await textInput.longClick(); + await Utils.sleep(500); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(500); + await selectAll.click(); + await Utils.sleep(500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await Utils.sleep(500); + await copy.click(); + await Utils.sleep(500); + await driver.triggerKey(2054); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0500 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0510 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0510 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0510', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0510 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(500); + let driver: Driver = Driver.create(); + await driver.delayMs(500); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(500); + await textInput.inputText('TextInput:test copy&paste inputText'); + await Utils.sleep(500); + await textInput.longClick(); + await Utils.sleep(500); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(500); + await selectAll.click(); + await Utils.sleep(500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await Utils.sleep(500); + await copy.click(); + await Utils.sleep(500); + await driver.triggerKey(2082); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0510 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0520 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0520 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0520', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0520 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test selectAll longPress inputText'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(500); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0520 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0530 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0530 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0530', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0530 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test selectAll rightClick inputText'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(500); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(500); + await driver.mouseClick({ + x: point.x + 100, y: point.y + 70 + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0530 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0560 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0560 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0560', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0560 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test delete inputText'); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(500); + await textInput.click(); + await Utils.sleep(500); + await driver.triggerKey(2055); + await Utils.sleep(500); + await driver.triggerKey(2081); + await Utils.sleep(500); + let point = await textInput.getBounds(); + await driver.click(point.left, point.bottom); + await Utils.sleep(500); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0560 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0570 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0570 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0570', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0570 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test delete inputText'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(500); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0570 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0580 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0580 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0580', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0580 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test drag inputText'); + await Utils.sleep(500); + let point = await textInput.getBoundsCenter(); + await driver.drag(point.x, point.y, point.x * 2, point.y, 400); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0580 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0590 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0590 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0590', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0590 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0430") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0430')); + await Utils.sleep(500); + let point = await textInput.getBounds(); + await driver.drag(point.right - 100, point.bottom - 20, point.left, point.top - 10, 400); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0590 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0610 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0610 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0610', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0610 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test select area inputText'); + await Utils.sleep(500); + await textInput.longClick(); + await Utils.sleep(500); + let point = await textInput.getBoundsCenter(); + await driver.click(point.x, point.y); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0610 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0620 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0620 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0620', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0620 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textSelectionAction0020')); + await Utils.sleep(100); + await textInput.inputText('TextInput:test select area inputText'); + await Utils.sleep(500); + await textInput.longClick(); + await Utils.sleep(500); + let point = await textInput.getBoundsCenter(); + await driver.click(point.x, point.y + 50); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0620 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0630 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0630 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0630', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0630 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0630") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput1: Component = await driver.findComponent(ON.id('textSelectionAction0630_1')); + let textInput2: Component = await driver.findComponent(ON.id('textSelectionAction0630_2')); + await Utils.sleep(100); + await textInput1.inputText('TextInput:test selectArea inputText'); + await Utils.sleep(500); + await textInput1.longClick(); + await Utils.sleep(1000); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll.click(); + await Utils.sleep(1000); + let point = await textInput1.getBoundsCenter(); + let point2 = await textInput2.getBoundsCenter(); + await driver.drag(point.x, point.y, point2.x, point2.y, 400); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_ACTION_0630 finish.`); + done(); + }) + }) +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSelectionInterfaceTest/UIComponentTextSelectionInterface.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSelectionInterfaceTest/UIComponentTextSelectionInterface.test.ets new file mode 100755 index 00000000..e779f2f4 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UIComponentTextSelectionInterfaceTest/UIComponentTextSelectionInterface.test.ets @@ -0,0 +1,263 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, MouseButton, ON } from '@ohos.UiTest' + +/* + * + * Settings.createWindow(config.url): + * 创建窗口,更改窗口基本配置,更改方式详见model/Settings createWindow方法 + * + * windowSnap.snapShot(globalThis.context): + * 窗口截屏&图片文件保存,存储在设备端 + * 存储文件固定,单挑用例执行后覆盖,用于自动化UI对比 + * 支持调试更改文件名为时间戳格式,更改model/snapShot createAndGetFile方法 注释L35,放开L32,L33 + * + * Logger日志使用方法: + * import Logger form './model/Logger' + * Logger.info(TAG,`config = ${config}, err = ${JSON.stringify(exception)}`) + * */ + +export default function UIComponentTextSelectionInterface() { + + describe('UIComponentTextSelectionInterface', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0010 + * @tc.desc search: onCopy + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0010 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface"); + let driver: Driver = Driver.create(); + let search: Component = await driver.findComponent(ON.id('textSelectionInterface_002')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(1000); + await search.inputText('这是输入文字可复制到[search]组件内'); + await Utils.sleep(1000); + await search.longClick(); + await Utils.sleep(1000); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll?.click(); + await Utils.sleep(1000); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy?.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0010 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0020 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0020 + * @tc.desc search: onCut + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0020 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface020"); + let driver: Driver = Driver.create(); + let search: Component = await driver.findComponent(ON.id('textSelectionInterface020_001')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(1000); + await search.inputText('这是输入文字可剪切到应用内'); + await Utils.sleep(1000); + await search.longClick(); + await Utils.sleep(1000); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll?.click(); + await Utils.sleep(1000); + let copy: Component = await driver.findComponent(ON.text('剪切')); + await copy?.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0020 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0030 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0030 + * @tc.desc search: onPaste + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0030 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface"); + let driver: Driver = Driver.create(); + let search: Component = await driver.findComponent(ON.id('textSelectionInterface_002')); + await Utils.sleep(1000); + await search.inputText('这是输入文字可复制到[search]组件内'); + await Utils.sleep(1000); + await search.longClick(); + await Utils.sleep(1000); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll?.click(); + await Utils.sleep(1000); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy?.click(); + await Utils.sleep(500); + let point = await search.getBoundsCenter(); + await driver.mouseClick({x:point.x,y:point.y},MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(1000); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await paste?.click(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0030 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0040 + * @tc.desc search change onSubmit + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0040 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface040") + let driver: Driver = Driver.create() + let search: Component = await driver.findComponent(ON.id('textSelectionInterface040_001')) + let submit: Component = await driver.findComponent(ON.text('Search')) + await Utils.sleep(500) + await search.inputText("提交内容") + await Utils.sleep(1000) + await submit.click() + await Utils.sleep(1000) + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0040 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0050 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0050 + * @tc.desc TextArea: onCopy + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0030 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface"); + let driver: Driver = Driver.create(); + let textArea: Component = await driver.findComponent(ON.id('textSelectionInterface_001')); + await Utils.sleep(1000); + await textArea.inputText('这是输入文字可复制到textArea组件内'); + await Utils.sleep(1000); + await textArea.longClick(); + await Utils.sleep(1000); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll?.click(); + await Utils.sleep(1000); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy?.click(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0050 finish.`); + done(); + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0060 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0060 + * @tc.desc textArea: onCut + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0020 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface020"); + let driver: Driver = Driver.create(); + let search: Component = await driver.findComponent(ON.id('textSelectionInterface020_002')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(1000); + await search.inputText('这是输入文字可剪切到应用内'); + await Utils.sleep(1000); + await search.longClick(); + await Utils.sleep(1000); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll?.click(); + await Utils.sleep(1000); + let copy: Component = await driver.findComponent(ON.text('剪切')); + await copy?.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0060 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0070 + * @tc.desc TextArea: onPaste + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0070 start.`); + Settings.createWindow("testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface"); + let driver: Driver = Driver.create(); + let textArea: Component = await driver.findComponent(ON.id('textSelectionInterface_001')); + await Utils.sleep(1000); + await textArea.click(); + await Utils.sleep(1000); + await textArea.inputText('这是输入文字可复制到[textArea]组件内\n这是输入文字可复制到[textArea]组件内'); + await Utils.sleep(1000); + await textArea.longClick(); + await Utils.sleep(1000); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll?.click(); + await Utils.sleep(1000); + let copy: Component = await driver.findComponent(ON.text('复制')); + await copy?.click(); + await Utils.sleep(500); + let point = await textArea.getBoundsCenter(); + await driver.mouseClick({x:point.x,y:point.y},MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + await textArea.longClick(); + await Utils.sleep(1000); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await paste?.click(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SELECTION_INTERFACE_0070 finish.`); + done(); + }) + }) +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonApplicationLevelFontsTest/UiComponentTextCommonApplicationLevelFontsTest.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonApplicationLevelFontsTest/UiComponentTextCommonApplicationLevelFontsTest.test.ets new file mode 100644 index 00000000..ef08dd6b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonApplicationLevelFontsTest/UiComponentTextCommonApplicationLevelFontsTest.test.ets @@ -0,0 +1,66 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton, UiWindow } from '@ohos.UiTest' + +export default function UiComponentTextCommonApplicationLevelFontsTest() { + + describe('UiComponentTextCommonApplicationLevelFontsTest', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_APPLICATION_LEVEL_FONTS_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_APPLICATION_LEVEL_FONTS_0010 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_APPLICATION_LEVEL_FONTS_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_APPLICATION_LEVEL_FONTS_0010 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonApplicationLevelFonts/UiComponentTextCommonApplicationLevelFonts0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let dialogBtn: Component = await driver.findComponent(ON.id('openDialogApplicationLevelFonts0010')); + await Utils.sleep(100); + await dialogBtn.click(); + await Utils.sleep(1000); + let btn: Component = await driver.findComponent(ON.id('changeFontApplicationLevelFonts0010')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_APPLICATION_LEVEL_FONTS_0010 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonCustomKeyBoardIsSupportAvoidanceTest/UiComponentTextCommonCustomKeyBoardIsSupportAvoidanceTest.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonCustomKeyBoardIsSupportAvoidanceTest/UiComponentTextCommonCustomKeyBoardIsSupportAvoidanceTest.test.ets new file mode 100644 index 00000000..e2b66978 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonCustomKeyBoardIsSupportAvoidanceTest/UiComponentTextCommonCustomKeyBoardIsSupportAvoidanceTest.test.ets @@ -0,0 +1,6003 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton, UiWindow, DisplayRotation } from '@ohos.UiTest' + +export default function UiComponentTextCommonCustomKeyBoardIsSupportAvoidanceTest() { + + describe('UiComponentTextCommonCustomKeyBoardIsSupportAvoidanceTest', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0010_1')); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0010_2')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0010_2')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0010_2')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await Settings.changeOrientation(); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0010_2')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0010_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0020_1')); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0020_2')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0020_2')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0020_2')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0020_2')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0020_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0030") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0030_1')); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0030") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0030_2')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0030") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0030_2')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0030") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await driver.setDisplayRotation(DisplayRotation.ROTATION_0); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0030_2')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0030") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0030_2')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0030_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0040") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0040_1')); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0040") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0040_2')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0040") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0040_2')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0040") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0040_2')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0040") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0040_2')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0040_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0050") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0050')); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0050") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0050')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0050") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0050')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0050") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0050')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0050") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0050')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0050_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0060')); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0060')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0060')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0060')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0060')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0060_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0070") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0070')); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0070") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0070')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0070") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0070')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0070") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0070')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_5 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0070") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('btnChangeCustomKeyBoardIsSupportAvoidance0070')); + await Utils.sleep(100); + await btn.click() + await Utils.sleep(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0070')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_6 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_6 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_6', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_6 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0070") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0070')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0070_6 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0080") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0080')); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0080") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0080')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0080") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0080')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0080") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0080')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_5 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0080") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('btnChangeCustomKeyBoardIsSupportAvoidance0080')); + await Utils.sleep(100); + await btn.click() + await Utils.sleep(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0080')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_6 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_6 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_6', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_6 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0080") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0080')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0080_6 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0090") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0090')); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0090") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0090')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0090") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0090')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0090") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0090')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0090") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0090')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0090_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0100") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0100')); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0100") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0100')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0100") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0100')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0100") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0100')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0100") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0100')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0100_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0110')); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0110')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0110')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0110')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0110')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0110_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0120") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0120')); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0120") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0120')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0120") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0120')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0120") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0120')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0120") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0120')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0120_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0130 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0130 + * @tc.desc + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0130', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0130 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0130") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0130')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + let textInput1: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0130_1')); + await Utils.sleep(100); + await textInput1.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0130 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0150_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0150_1 + * @tc.desc focusable + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0150_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0150_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0150") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0150_1')); + let button: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0150_btn_01')); + await Utils.sleep(500); + await textInput.inputText('aaaaaaaa'); + await Utils.sleep(500); + await button.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0150_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0150_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0150_2 + * @tc.desc stopEditing + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0150_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0150_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0150") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0150_1')); + let button: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0150_btn_02')); + await Utils.sleep(500); + await textInput.inputText('aaaaaaaa'); + await Utils.sleep(500); + await button.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0150_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0150_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0150_3 + * @tc.desc stopEditing + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0150_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0150_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0150") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0150_1')); + await Utils.sleep(500); + await textInput.inputText('aaaaaaaa'); + await Utils.sleep(500); + await driver.triggerKey(2) + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0150_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0360_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0360_1 + * @tc.desc focusable + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0360_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0360_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0360") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0360_1')); + let button: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0360_btn_01')); + await Utils.sleep(500); + await textInput.inputText('aaaaaaaa'); + await Utils.sleep(500); + await button.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0360_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0360_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0360_2 + * @tc.desc stopEditing + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0360_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0360_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0360") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0360_1')); + let button: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0360_btn_02')); + await Utils.sleep(500); + await textInput.inputText('aaaaaaaa'); + await Utils.sleep(500); + await button.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0360_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0360_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0360_3 + * @tc.desc stopEditing + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0360_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0360_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0360") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0360_1')); + await Utils.sleep(500); + await textInput.inputText('aaaaaaaa'); + await Utils.sleep(500); + await driver.drag(200, 500, 500, 500) + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0360_3 finish.`); + done() + }) + + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0570_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0570_1 + * @tc.desc focusable-textArea + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0570_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0570_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0570") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0570_1')); + let button: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0570_btn_01')); + await Utils.sleep(500); + await textInput.inputText('aaaaaaaa'); + await Utils.sleep(500); + await button.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0570_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0570_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0570_2 + * @tc.desc stopEditing-textArea + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0570_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0570_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0570") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0570_1')); + let button: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0570_btn_02')); + await Utils.sleep(500); + await textInput.inputText('aaaaaaaa'); + await Utils.sleep(500); + await button.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0570_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0570_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0570_3 + * @tc.desc stopEditing-textArea + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0570_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0570_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0570") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0570_1')); + await Utils.sleep(500); + await textInput.inputText('aaaaaaaa'); + await Utils.sleep(500); + await driver.drag(200, 500, 500, 500) + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0570_3 finish.`); + done() + }) + + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0160") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0160')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0160')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0160") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0160')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0160')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0160") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0160')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0160')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0160") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0160')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0160')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0160") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0160')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0160')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0160_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0170") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0170')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0170')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0170") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0170')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0170')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0170") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0170')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0170')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0170") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0170')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0170')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0170") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0170')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0170')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0170_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0200") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0200')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0200") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0200')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0200") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0200')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0200") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0200')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0200") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0200')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0200_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0210") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0210')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0210") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0210')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0210") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0210')); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0210") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0210')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0210") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputCustomKeyBoardIsSupportAvoidance0210')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0210_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0220") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0220')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0220") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0220')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0220") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0220')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0220") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0220')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0220") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0220')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0220_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0230") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0230')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0230") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0230')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0230") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0230')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0230") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0230')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0230") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0230')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0230_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0240") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0240')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0240") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0240')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0240") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0240')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0240") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0240')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0240") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0240')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0240_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0250") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0250')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0250") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0250')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0250") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0250')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0250") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0250')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0250") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0250')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0250_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0260") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0260')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0260") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0260')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0260") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0260')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0260") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0260')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0260") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0260')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0260_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0270") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0270')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0270") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0270')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0270") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0270')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0270") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0270')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0270") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0270')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0270_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0280") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0280')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0280") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0280')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0280") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0280')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0280") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0280')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_5 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0280") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('btnChangeCustomKeyBoardIsSupportAvoidance0280')); + await Utils.sleep(100); + await btn.click() + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0280')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_6 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_6 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_6', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_6 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0280") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0280')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0280_6 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0290") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0290')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0290") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0290')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0290") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0290')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0290") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0290')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_5 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0290") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('btnChangeCustomKeyBoardIsSupportAvoidance0290')); + await Utils.sleep(100); + await btn.click() + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0290')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_6 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_6 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_6', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_6 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0290") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0290')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0290_6 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0300") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0300')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0300") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0300')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0300") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0300')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0300") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0300')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0300") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0300')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0300_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0310") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0310')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0310") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0310')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0310") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0310')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0310") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0310')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0310") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0310')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0310_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0320") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0320')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0320") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0320')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0320") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0320')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0320") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0320')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0320") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0320')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0320_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0330") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0330')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0330") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0330')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0330") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0330')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0330") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0330')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0330") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0330')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0330_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0340 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0340 + * @tc.desc + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0340', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0340 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0340") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0340')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + let search1: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0340_1')); + await Utils.sleep(100); + await search1.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0340 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0370") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0370')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0370')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0370") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0370')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0370')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0370") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0370')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0370')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0370") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0370')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0370')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0370") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0370')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0370')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0370_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0380") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0380')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0380')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0380") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0380')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0380')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0380") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0380')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0380')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0380") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0380')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0380')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0380") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0380')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0380')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0380_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0410") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0410')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0410") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0410')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0410") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0410')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0410") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0410')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0410") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0410')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0410_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0420") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0420')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0420") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0420')); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0420") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0420')); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0420") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0420')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0420") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchCustomKeyBoardIsSupportAvoidance0420')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0420_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0430") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0430')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0430") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0430')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0430") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0430')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0430") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0430')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0430") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0430')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0430_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0440") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0440')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0440") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0440')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0440") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0440')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0440") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0440')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0440") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0440')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0440_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0450") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0450')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0450") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0450')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0450") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0450')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0450") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0450')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0450") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0450')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0450_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0460") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0460')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0460") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0460')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0460") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0460')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0460") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0460')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0460") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0460')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0460_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0470") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0470')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0470") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0470')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0470") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0470')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0470") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0470')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0470") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0470')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0470_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0480") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0480')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0480") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0480')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0480") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0480')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0480") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0480')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0480") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0480')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0480_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0490") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0490')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0490") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0490')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0490") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0490')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0490") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0490')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_5 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0490") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('btnChangeCustomKeyBoardIsSupportAvoidance0490')); + await Utils.sleep(100); + await btn.click() + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0490')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_6 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_6 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_6', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_6 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0490") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0490')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0490_6 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0500") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0500')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0500") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0500')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0500") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0500')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0500") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0500')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_5 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0500") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('btnChangeCustomKeyBoardIsSupportAvoidance0500')); + await Utils.sleep(100); + await btn.click() + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0500')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_6 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_6 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_6', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_6 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0500") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0500')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0500_6 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0510") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0510')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0510") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0510')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0510") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0510')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0510") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0510')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0510") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0510')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0510_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0520") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0520')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0520") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0520')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0520") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0520')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0520") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0520')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0520") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0520')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0520_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0530") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0530')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0530") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0530')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0530") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0530')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0530") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0530')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0530") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0530')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0530_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0540") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0540')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0540") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0540')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0540") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0540')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0540") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0540')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0540") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0540')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0540_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0550 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0550 + * @tc.desc + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0550', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0550 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0550") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0550')); + await Utils.sleep(100); + await textArea.click(); + let textArea1: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0550_1')); + await Utils.sleep(100); + await textArea1.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0550 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0580") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0580')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0580") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0580')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0580") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0580')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + 300 + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0580") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0580')); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0580") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0580')); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0580_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0590 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0590 + * @tc.desc + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0590', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0590 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0590") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0590')); + await Utils.sleep(100); + await textArea.click() + await Utils.sleep(2500); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0590 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0600 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0600 + * @tc.desc + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0600', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0600 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0600") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0600')); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnCustomKeyBoardIsSupportAvoidance0600')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(3000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0600 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0610") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0610')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0610')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0610") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0610')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0610')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0610") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0610')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0610')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0610") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0610')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0610')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0610") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0610')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0610')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0610_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0620") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0620')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0620')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0620") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0620')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0620')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0620") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0620')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0620')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0620") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0620')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0620')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0620") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let btn: Component = await driver.findComponent(ON.id('openDialogCustomKeyBoardIsSupportAvoidance0620')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0620')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0620_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0650") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0650')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0650") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0650')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0650") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0650')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0650") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0650')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0650") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0650')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0650_5 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_1 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_1 + * @tc.desc 首次进入页面时,默认拉起键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_1', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0660") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0660')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_1 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_2 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_2 + * @tc.desc 使用手指点击输入框拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_2', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0660") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0660')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_2 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_3 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_3 + * @tc.desc 连接鼠标后点击鼠标左键拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_3', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0660") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0660')); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_LEFT); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_3 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_4 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_4 + * @tc.desc 长按文本内容拉起自定义键盘 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_4', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0660") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0660')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_4 finish.`); + done() + }) + /* + * @tc.number SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_5 + * @tc.name SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_5 + * @tc.desc 键盘拉起时切换横屏 + */ + it('SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_5', 0, async (done: Function) => { + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0660") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaCustomKeyBoardIsSupportAvoidance0660')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUE_ACE_UI_COMPONENT_TEXT_COMMON_CUSTOMKEYBOARD_ISSUPPORTAVOIDANCE_0660_5 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonEmojiTest/UiComponentTextCommonEmojiTest.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonEmojiTest/UiComponentTextCommonEmojiTest.test.ets new file mode 100644 index 00000000..a7c80d0b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonEmojiTest/UiComponentTextCommonEmojiTest.test.ets @@ -0,0 +1,946 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton, UiWindow, DisplayRotation } from '@ohos.UiTest' + +export default function UiComponentTextCommonEmojiTest() { + + describe('UiComponentTextCommonEmojiTest', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0010 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0010 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0010')); + await Utils.sleep(100); + await textInput.inputText('\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0010')); + await Utils.sleep(100); + await textArea.inputText('\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2014); + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0010 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0020 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0020 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0020 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0020')); + await Utils.sleep(100); + await textInput.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0020')); + await Utils.sleep(100); + await textArea.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2014); + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0020 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0030 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0030 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0030 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0030") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0030')); + await Utils.sleep(100); + await textInput.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0030')); + await Utils.sleep(100); + await textArea.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0030')); + await Utils.sleep(100); + await search.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(100); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0030 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0040 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0040 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0040") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0040')); + await Utils.sleep(100); + await textInput.inputText('avf\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0040')); + await Utils.sleep(100); + await textArea.inputText('a\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0040')); + await Utils.sleep(100); + await search.inputText('abcd\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(100); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0040 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0050 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0050 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0050 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0050") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0050')); + await Utils.sleep(100); + await textInput.inputText('aaa\naaaaaaaaaaaaaa\naaaaaaaaaaaaaaaaavf\uD83D\uDE00中'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0050')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaa\naaaaaaaaaaaa\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0050')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaa\nbcd\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0050 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0060 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0060 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0060 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component[] = await driver.findComponents(ON.id('TextInputTextCommonEmoji0060')); + await Utils.sleep(100); + await textInput[0].inputText('\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(100); + let textArea: Component[] = await driver.findComponents(ON.id('TextAreaTextCommonEmoji0060')); + await Utils.sleep(100); + await textArea[0].inputText('\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(100); + let search: Component[] = await driver.findComponents(ON.id('SearchTextCommonEmoji0060')); + await Utils.sleep(100); + await search[0].inputText('\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(100); + await textInput[1].inputText('\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2014); + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(100); + await textArea[1].inputText('\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2014); + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(100); + await search[1].inputText('\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2014); + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0060 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0070 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0070 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0070") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component[] = await driver.findComponents(ON.id('TextInputTextCommonEmoji0070')); + await Utils.sleep(100); + await textInput[0].inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(100); + let textArea: Component[] = await driver.findComponents(ON.id('TextAreaTextCommonEmoji0070')); + await Utils.sleep(100); + await textArea[0].inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(100); + let search: Component[] = await driver.findComponents(ON.id('SearchTextCommonEmoji0070')); + await Utils.sleep(100); + await search[0].inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(100); + await textInput[1].inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2014); + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(100); + await textArea[1].inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2014); + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(100); + await search[1].inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2014); + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0070 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0080 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0080 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0080', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0080 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0080") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0080')); + await Utils.sleep(100); + await textInput.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await textInput.click(); + await driver.triggerKey(2071); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0080')); + await Utils.sleep(100); + await textArea.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await textArea.click(); + await driver.triggerKey(2071); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0080')); + await Utils.sleep(100); + await search.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await search.click(); + await driver.triggerKey(2071); + await Utils.sleep(1500); + await windowSnap.snapShot(); + await Utils.sleep(1500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0080 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0090 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0090 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0090', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0090 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0090") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0090')); + await Utils.sleep(100); + await textInput.inputText('avf\uD83D\uDE00\uD83D\uDE00中ff'); + await Utils.sleep(100); + await driver.triggerKey(2014); + await driver.triggerKey(2014); + await driver.triggerKey(2014); + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0090')); + await Utils.sleep(100); + await textArea.inputText('a\uD83D\uDE00\uD83D\uDE00ff'); + await Utils.sleep(100); + await driver.triggerKey(2014); + await driver.triggerKey(2014); + await driver.triggerKey(2014); + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0090')); + await Utils.sleep(100); + await search.inputText('abcd\uD83D\uDE00\uD83D\uDE00中ff'); + await Utils.sleep(100); + await driver.triggerKey(2014); + await driver.triggerKey(2014); + await driver.triggerKey(2014); + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0090 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0100 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0100 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0100") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0100')); + await Utils.sleep(100); + await textInput.inputText('aaa\naaaaaaaaaaaaaa\naaaaaaaaaaaaaaaaavf\uD83D\uDE00中'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0100')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaa\naaaaaaaaaaaa\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0100')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaa\nbcd\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(100); + await driver.triggerKey(2071); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0100 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0110 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0110 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0110', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0110 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0110')); + await Utils.sleep(100); + await textInput.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(100); + await driver.triggerKey(2071); + await driver.triggerKey(2055); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0110')); + await Utils.sleep(100); + await textArea.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(100); + await driver.triggerKey(2071); + await driver.triggerKey(2055); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0110')); + await Utils.sleep(100); + await search.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(100); + await driver.triggerKey(2071); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0110 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0120 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0120 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0120 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0120") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0120')); + await Utils.sleep(100); + await textInput.inputText('\uD83D\uDE00\uD83D\uDE00'); + await driver.triggerKey(2055); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0120')); + await Utils.sleep(100); + await textArea.inputText('\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0120')); + await Utils.sleep(100); + await search.inputText('\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0120 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0140 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0140 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0140', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0140 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0140") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0140')); + await Utils.sleep(100); + await textInput.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await textInput.click(); + await driver.triggerKey(2055); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0140')); + await Utils.sleep(100); + await textArea.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await textArea.click(); + await driver.triggerKey(2055); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0140')); + await Utils.sleep(100); + await search.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await search.click(); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0140 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0150 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0150 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0150', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0150 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0150") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0150')); + await Utils.sleep(100); + await textInput.inputText('avf\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0150')); + await Utils.sleep(100); + await textArea.inputText('a\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0150')); + await Utils.sleep(100); + await search.inputText('abcd\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0150 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0160 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0160 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0160', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0160 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0160") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0160')); + await Utils.sleep(100); + await textInput.inputText('aaa\naaaaaaaaaaaaaa\naaaaaaaaaaaaaaaaavf\uD83D\uDE00中'); + await Utils.sleep(100); + await textInput.longClick() + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0160')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaa\naaaaaaaaaaaa\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0160')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaa\nbcd\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await search.longClick() + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0160 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0180 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0180 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0180', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0180 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0180") + let driver: Driver = Driver.create(); + await Utils.sleep(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0180')); + await Utils.sleep(100); + await textInput.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let textInputCut: Component = await driver.findComponent(ON.text('剪切')); + await Utils.sleep(100); + await textInputCut.click(); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let textInputCopy: Component = await driver.findComponent(ON.text('复制')); + await textInputCopy.click(); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let textInputPaste: Component = await driver.findComponent(ON.text('粘贴')); + await Utils.sleep(100); + await textInputPaste.click(); + await Utils.sleep(600); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0180 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0200 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0200 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0200', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0200 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0200") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0200')); + await Utils.sleep(100); + await textInput.inputText('avf\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0200')); + await Utils.sleep(100); + await textArea.inputText('a\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0200')); + await Utils.sleep(100); + await search.inputText('abcd\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0200 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0210 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0210 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0210', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0210 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0210") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0210')); + await Utils.sleep(100); + await textInput.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0210')); + await Utils.sleep(100); + await textArea.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0210')); + await Utils.sleep(100); + await search.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0210 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0220 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0220 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0220', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0220 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0220") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0220')); + await Utils.sleep(100); + await textInput.inputText('a\uD83D\uDE00'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll.click(); + await Utils.sleep(100); + let textInputCopy: Component = await driver.findComponent(ON.text('复制')); + await textInputCopy.click(); + await Utils.sleep(100); + await textInput.longClick(); + let textInputPaste: Component = await driver.findComponent(ON.text('粘贴')); + await Utils.sleep(100); + await textInputPaste.click(); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0220')); + await Utils.sleep(100); + await textArea.inputText('\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let textAreaAll: Component = await driver.findComponent(ON.text('全选')); + await textAreaAll.click(); + await Utils.sleep(100); + let textAreaCopy: Component = await driver.findComponent(ON.text('复制')); + await textAreaCopy.click(); + await Utils.sleep(100); + await textArea.longClick(); + let textAreaPaste: Component = await driver.findComponent(ON.text('粘贴')); + await Utils.sleep(100); + await textAreaPaste.click(); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0220')); + await Utils.sleep(100); + await search.inputText('\uD83D\uDE00a'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(100); + let searchAll: Component = await driver.findComponent(ON.text('全选')); + await searchAll.click(); + await Utils.sleep(100); + let searchCopy: Component = await driver.findComponent(ON.text('复制')); + await searchCopy.click(); + await Utils.sleep(100); + await search.longClick(); + let searchPaste: Component = await driver.findComponent(ON.text('粘贴')); + await Utils.sleep(100); + await searchPaste.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0220 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0230 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0230 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0230', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0230 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0230") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0230')); + await Utils.sleep(100); + await textArea.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2014); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0230 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0240 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0240 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0240', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0240 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0240") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0240')); + await Utils.sleep(100); + await textArea.inputText('\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00' + + '\uD83D\uDE00\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0240 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0250 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0250 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0250', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0250 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0250") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0250')); + await Utils.sleep(100); + await textInput.inputText('avf\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0250')); + await Utils.sleep(100); + await textArea.inputText('a\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0250')); + await Utils.sleep(100); + await search.inputText('abcd\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await Settings.changeOrientation(); + await Utils.sleep(100); + await textInput.click(); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(100); + await textArea.click(); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(100); + await search.click(); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0250 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0270 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0270 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0270', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0270 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0270") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonEmoji0270')); + await Utils.sleep(100); + await textInput.inputText('avf\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextCommonEmoji0270')); + await Utils.sleep(100); + await textArea.inputText('a\uD83D\uDE00\uD83D\uDE00'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await driver.triggerKey(2055); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonEmoji0270')); + await Utils.sleep(100); + await search.inputText('abcd\uD83D\uDE00\uD83D\uDE00中'); + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_EMOJI_0270 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonMenuAvoidTest/UiComponentTextCommonMenuAvoidTest.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonMenuAvoidTest/UiComponentTextCommonMenuAvoidTest.test.ets new file mode 100644 index 00000000..fdbca84f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonMenuAvoidTest/UiComponentTextCommonMenuAvoidTest.test.ets @@ -0,0 +1,1916 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton, UiWindow, DisplayRotation } from '@ohos.UiTest' + +export default function UiComponentTextCommonMenuAvoidTest() { + + describe('UiComponentTextCommonMenuAvoidTest', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0010 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0010 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0010')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaad'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0010 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0020 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0020 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0020 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0020')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaad'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0020 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0030 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0030 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0030 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0030") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0030')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaad'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0030 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0040 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0040 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0040") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0040')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaad'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.fling({ + x: (point.x - 20), y: point.y + }, { + x: point.x + 60, y: point.y + }, 5, 600); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0040 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0050 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0050 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0050 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0050") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0050')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaad'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.fling({ + x: (point.x - 20), y: point.y + }, { + x: point.x + 60, y: point.y + }, 5, 600); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0050 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0060 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0060 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0060 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0060')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaad'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0060 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0070 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0070 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0070") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0070')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaad'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0070 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0080 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0080 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0080', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0080 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0080") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0080')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaadaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0080 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0090 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0090 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0090', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0090 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0090") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0090')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaadaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0090 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0100 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0100 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0100") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0100')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaadaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0100 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0110 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0110 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0110', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0110 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0110')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaadaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0110 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0120 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0120 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0120 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0120") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0120')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaadaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0120 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0130 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0130 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0130', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0130 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0130") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0130')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaadaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0130 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0140 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0140 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0140', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0140 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0140") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0140')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaadaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0140 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0150 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0150 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0150', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0150 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0150") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0150')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaadaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0150 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0160 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0160 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0160', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0160 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0160") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0160')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaadaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.fling({ + x: point.x, y: point.y - 20 + }, { + x: point.x, y: point.y + 60 + }, 5, 600); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0160 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0170 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0170 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0170', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0170 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0170") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0170')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaadaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.fling({ + x: point.x, y: point.y - 20 + }, { + x: point.x, y: point.y + 60 + }, 5, 600); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0170 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0180 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0180 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0180', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0180 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0180") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0180')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaadaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0180 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0190 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0190 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0190', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0190 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0190") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0190')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaadaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0190 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0200 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0200 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0200', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0200 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0200") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0200')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaadaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0200 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0210 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0210 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0210', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0210 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0210") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0210')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaadaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0210 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0220 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0220 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0220', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0220 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0220") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0220')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaadaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0220 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0230 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0230 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0230', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0230 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0230") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0230')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaadaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0230 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0250 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0250 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0250', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0250 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0250") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0250')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0250 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0250_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0250_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0250_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0250_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0250") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0250')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0250_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0250_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0250_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0250_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0250_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0250") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0250')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.fling({ + x: point.x, y: point.y - 20 + }, { + x: point.x, y: point.y + 60 + }, 5, 600); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0250_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0260_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0260_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0260_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0260_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0260") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0260')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaa'); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0260')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0260_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0260_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0260_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0260_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0260_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0260") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0260')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaa'); + await Utils.sleep(100); + let btnChange: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0260')); + await Utils.sleep(100); + await btnChange.click(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnChangeTextInputTextCommonMenuAvoid0260')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0260_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0270_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0270_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0270_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0270_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0270") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0270')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0270_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0270_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0270_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0270_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0270_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0270") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0270')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0270')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0270_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0280_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0280_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0280_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0280_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0280") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0280')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0280_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0280_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0280_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0280_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0280_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0280") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0280')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0280')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0280_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0290_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0290_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0290_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0290_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0290") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0290')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0290_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0290_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0290_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0290_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0290_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0290") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0290')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0290')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0290_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0300_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0300_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0300_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0300_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0300") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0300')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0300_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0300_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0300_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0300_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0300_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0300") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0300')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0300')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0300_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0310 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0310 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0310', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0310 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0310") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0310')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0310 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0320 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0320 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0320', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0320 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0320") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0320')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0320 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0330_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0330_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0330_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0330_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0330") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0330')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0330_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0330_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0330_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0330_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0330_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0330") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonMenuAvoid0330')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0330')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0330_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0340_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0340_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0340_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0340_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0340") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0340')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0340_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0340_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0340_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0340_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0340_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0340") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0340')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0340_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0340_3 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0340_3 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0340_3', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0340_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0340") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0340')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.fling({ + x: point.x, y: point.y - 20 + }, { + x: point.x, y: point.y + 60 + }, 5, 600); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0340_3 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0350 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0350 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0350', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0350 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0350") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0350')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0350')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0350 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0360_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0360_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0360_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0360_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0360") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0360')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaadaaa'); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0360')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0360_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0360_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0360_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0360_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0360_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0360") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0360')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaadaaa'); + await Utils.sleep(100); + let btnChange: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0360')); + await Utils.sleep(100); + await btnChange.click(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnChangeTextInputTextCommonMenuAvoid0360')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0360_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0370_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0370_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0370_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0370_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0370") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0370')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0370_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0370_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0370_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0370_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0370_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0370") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0370')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0370')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0370_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0380_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0380_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0380_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0380_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0380") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0380')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaad'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0380_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0380_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0380_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0380_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0380_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0380") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0380')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaad'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0380')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0380_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0390_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0390_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0390_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0390_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0390") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0390')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0390_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0390_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0390_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0390_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0390_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0390") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0390')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0390')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0390_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0400_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0400_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0400_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0400_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0400") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0400')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0400_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0400_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0400_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0400_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0400_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0400") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0400')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0400')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0400_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0410_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0410_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0410_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0410_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0410") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0410')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0410_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0410_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0410_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0410_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0410_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0410") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0410')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0410')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0410_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0420_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0420_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0420_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0420_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0420") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0420')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaa'); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0420')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0420_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0420_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0420_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0420_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0420_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0420") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0420')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaa'); + await Utils.sleep(100); + let btnChange: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0420')); + await Utils.sleep(100); + await btnChange.click(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnChangeTextInputTextCommonMenuAvoid0420')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0420_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0430_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0430_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0430_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0430_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0430") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0430')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0430_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0430_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0430_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0430_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0430_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0430") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0430')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0430')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0430_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0440_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0440_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0440_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0440_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0440") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0440')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0440_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0440_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0440_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0440_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0440_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0440") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0440')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0440')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0440_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0450_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0450_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0450_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0450_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0450") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0450')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0450_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0450_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0450_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0450_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0450_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0450") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0450')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0450')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0450_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0460_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0460_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0460_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0460_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0460") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0460')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0460_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0460_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0460_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0460_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0460_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0460") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0460')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0460')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0460_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0470_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0470_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0470_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0470_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0470") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0470')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0470_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0470_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0470_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0470_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0470_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0470") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0470')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0470')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await search.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0470_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0480 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0480 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0480', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0480 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0480") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0480')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0480 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0490 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0490 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0490', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0490 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0490") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0490')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0490 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0500 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0500 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0500', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0500 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0500") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0500')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0500 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0510 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0510 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0510', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0510 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0510") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0510')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.fling({ + x: point.x, y: point.y - 100 + }, { + x: point.x, y: point.y + 50 + }, 5, 600); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0510 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0520 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0520 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0520', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0520 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0520") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0520')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaa'); + await Utils.sleep(1000); + await Settings.changeOrientation() + await Utils.sleep(1000); + await search.longClick(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + await Settings.changeOrientation() + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0520 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0530 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0530 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0530', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0530 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0530") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonMenuAvoid0530')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonMenuAvoid0530')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + let point = await search.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseClick({ + x: point.x, y: point.y + }, MouseButton.MOUSE_BUTTON_RIGHT); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0530 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0540 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0540 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0540', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0540 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0540") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonMenuAvoid0540')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaadaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.fling({ + x: point.x, y: point.y + }, { + x: point.x, y: point.y + 60 + }, 5, 600); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_MENU_AVOID_0540 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonQuanXuanCaiDanTest/UiComponentTextCommonQuanXuanCaiDanTest.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonQuanXuanCaiDanTest/UiComponentTextCommonQuanXuanCaiDanTest.test.ets new file mode 100644 index 00000000..706b47e4 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonQuanXuanCaiDanTest/UiComponentTextCommonQuanXuanCaiDanTest.test.ets @@ -0,0 +1,1341 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton, UiWindow, DisplayRotation } from '@ohos.UiTest' + +export default function UiComponentTextCommonQuanXuanCaiDanTest() { + + describe('UiComponentTextCommonQuanXuanCaiDanTest', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0010 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0010 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0010')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'jajajjajajjajdjajdajdjajdjawjdjawdjawjdjawjdjawdjawjdjwajdjwdjawjdjwajdjwjdwdjjda' + + 'jajjdajdjwdahdhahdawhdhawdhhhdhahdahwdhahdhahadadawddadaddaw'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0010 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0020 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0020 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0020 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0020')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'jajajjajajjajdjajdajdjajdjawjdjawdjawjdjawjdjawdjawjdjwajdjwdjawjdjwajdjwjdwdjjda' + + 'jajjdajdjwdahdhahdawhdhawdhhhdhahdahwdhahdhahadadawd'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0020 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0030 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0030 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0030 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0030") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0030')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0030 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0040 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0040 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0040") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0040')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0040 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0050 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0050 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0050 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0050") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0050')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textInput.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0050 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0060 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0060 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0060 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0060')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textInput.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0060 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0070 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0070 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0070") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0070')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textInput.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0070 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0080 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0080 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0080', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0080 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0080") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0080')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textInput.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0080 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0090 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0090 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0090', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0090 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0090") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0090')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textInput.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0090 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0100 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0100 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0100") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0100')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textInput.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0100 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0110 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0110 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0110', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0110 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0110')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textInput.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0110 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0120 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0120 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0120 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0120") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0120')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textInput.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0120 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0130 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0130 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0130', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0130 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0130") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0130')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwaddaddawdwadwaaaaaaa' + + 'aaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0130 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0140 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0140 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0140', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0140 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0140") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0140')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0140 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0150 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0150 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0150', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0150 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0150") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0150')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0150 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0160 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0160 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0160', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0160 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0160") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0160')); + await Utils.sleep(100); + await textInput.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwadaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0160 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0170 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0170 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0170', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0170 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0170") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0170')); + await Utils.sleep(100); + await textArea.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0170 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0180 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0180 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0180', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0180 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0180") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0180')); + await Utils.sleep(100); + await textArea.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0180 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0190 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0190 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0190', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0190 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0190") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0190')); + await Utils.sleep(100); + await textArea.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0190 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0200 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0200 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0200', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0200 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0200") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0200')); + await Utils.sleep(100); + await textArea.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0200 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0210 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0210 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0210', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0210 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0210") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0210')); + await Utils.sleep(100); + await textArea.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textArea.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0210 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0220 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0220 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0220', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0220 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0220") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0220')); + await Utils.sleep(100); + await textArea.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textArea.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0220 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0230 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0230 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0230', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0230 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0230") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0230')); + await Utils.sleep(100); + await textArea.inputText('hahahahahhahahahhahahahdadadawdawdwdawdwadawdwadwadwadwad' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textArea.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0230 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0240 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0240 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0240', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0240 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0240") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0240')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textArea.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0240 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0250 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0250 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0250', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0250 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0250") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0250')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textArea.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0250 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0260 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0260 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0260', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0260 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0260") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0260')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textArea.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0260 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0270 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0270 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0270', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0270 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0270") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0270')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textArea.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0270 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0280 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0280 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0280', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0280 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0280") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0280')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textArea.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0280 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0290 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0290 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0290', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0290 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0290") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0290')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0290 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0300 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0300 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0300', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0300 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0300") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0300')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textArea.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0300 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0310 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0310 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0310', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0310 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0310") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0310')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textArea.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0310 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0320 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0320 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0320', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0320 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0320") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0320')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0320 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0330 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0330 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0330', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0330 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0330") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0330')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0330 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0340 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0340 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0340', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0340 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0340") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0340')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textArea.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0340 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0350 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0350 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0350', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0350 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0350") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0350')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0350 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0360 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0360 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0360', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0360 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0360") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0360')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textInput.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0360 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0370 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0370 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0370', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0370 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0370") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0370')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, true, 10); + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + await textInput.click() + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0370 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0380 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0380 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0380', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0380 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0380") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0380')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonQuanXuanCaiDan0380')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0380 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0390_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0390_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0390_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0390_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0390") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0390')); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonQuanXuanCaiDan0390UP')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0390_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0390_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0390_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0390_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0390_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0390") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextCommonQuanXuanCaiDan0390')); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('btnTextCommonQuanXuanCaiDan0390')); + await Utils.sleep(100); + await btn.click(); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0390_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0400 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0400 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0400', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0400 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0400") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextCommonQuanXuanCaiDan0400')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchTextCommonQuanXuanCaiDan0400')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0400 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0410 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0410 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0410', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0410 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0410") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextCommonQuanXuanCaiDan0410')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(1000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textInput.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + await Settings.changeOrientation(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_QUANXUANCAIDAN_0410 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonTextImproveTest/UiComponentTextCommonTextImprove.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonTextImproveTest/UiComponentTextCommonTextImprove.test.ets new file mode 100644 index 00000000..73942668 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonTextImproveTest/UiComponentTextCommonTextImprove.test.ets @@ -0,0 +1,436 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton } from '@ohos.UiTest' + +export default function UiComponentTextCommonTextImprove() { + + describe('UiComponentTextCommonTextImprove', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(100); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0010 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0010 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0010')); + await Utils.sleep(100); + await textInput.inputText('123ab?_!A123'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0010 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0020 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0020 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0020 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0020')); + await Utils.sleep(100); + await textInput.inputText('123ab?_!A123'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0020 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0030 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0030 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0030 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0030") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0030')); + await Utils.sleep(100); + await textInput.inputText('123ab?_!A123'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0030 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0040 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0040 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0040") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0040')); + await Utils.sleep(100); + await textInput.inputText('123ab?_!A123'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0040 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0050 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0050 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0050 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0050") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0050')); + await Utils.sleep(100); + await textInput.inputText('123ab?_!A123'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0050 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0060 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0060 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0060 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0060')); + await Utils.sleep(100); + await textInput.inputText('123ab?_!A123'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0060 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0070 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0060 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0070") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0070')); + await Utils.sleep(100); + await textInput.inputText('123ab?_!A123'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0070 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0080 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0080 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0080', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0060 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0080") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0080')); + await Utils.sleep(100); + await textInput.inputText('123456789'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0080 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0090 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0090 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0090', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0090 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0090") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0090')); + await Utils.sleep(100); + await textInput.inputText('123456789'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0090 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0100 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0100 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0100") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0100')); + await Utils.sleep(100); + await textInput.inputText('123ab?_!A123'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0100 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0110 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0110 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0110', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0110 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0110')); + await Utils.sleep(100); + await textInput.inputText('123ab?_!A123123ab?_!A123123ab?_!A123123ab?_!' + + 'A123123ab?_!A123123ab?_!A123123ab?_!A123ab?_!A123123ab?_!A123123ab?_!A123' + + '123123ab?_!A123123ab?_!A123123ab?_!A123123ab?_!A123123ab?_!A123123ab?_!A123'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0110 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0120 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0120 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0120 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0120") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0120')); + await Utils.sleep(100); + await textInput.inputText('123ab?_!A123123ab'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0120 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0130 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0130 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0130', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0130 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0130") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0130')); + await Utils.sleep(100); + await textInput.inputText('123ab?_!A123123ab'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0130 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0140 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0140 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0140', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0140 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0140") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0140')); + await Utils.sleep(100); + await textInput.inputText('123ab?_!A123123ab'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0140 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0150 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0150 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0150', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0150 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0150") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0150')); + await Utils.sleep(100); + await textInput.inputText('123ab?_!A123123ab'); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0150 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0160 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0160 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0160', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0160 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0160") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0160')); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0160 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0170 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0170 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0170', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0170 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0170") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0170')); + await Utils.sleep(100); + await textInput.inputText('123ab?_!A123123ab'); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0170 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0180 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0180 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0180', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0180 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0180") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextImprove0180')); + await Utils.sleep(100); + await textInput.longClick(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTIMPROVE_0180 finish.`); + done(); + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonTextMinFontsizeTest/UiComponentTextCommonTextMinFontsize.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonTextMinFontsizeTest/UiComponentTextCommonTextMinFontsize.test.ets new file mode 100644 index 00000000..ee9000a3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonTextMinFontsizeTest/UiComponentTextCommonTextMinFontsize.test.ets @@ -0,0 +1,1321 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton } from '@ohos.UiTest' + +export default function UiComponentTextCommonTextMinFontsize() { + + describe('UiComponentTextCommonTextMinFontsize', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(100); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_008 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_008 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_008', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_008 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize008") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize008')); + await ch1.click(); + await Utils.sleep(100); + await ch1.inputText('this is input002'); + await ch1.inputText('this is input002this is input002'); + await ch1.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_008 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_009 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_009 + * @tc.desc + */ + + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_009', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_009 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize009") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize009')); + await Utils.sleep(100); + await ch1.click(); + await Utils.sleep(100); + await ch1.inputText('哈哈哈哈哈哈') + await Utils.sleep(100); + let ch2: Component = await driver.findComponent(ON.id('searchFontSize009')); + await ch2.click(); + await Utils.sleep(100); + await ch2.inputText('ABCpriorities. Sometimes, a significant changeChange,a constant and inevitable,everychange') + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_009 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_010 + * @tc.desc + */ + + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_010 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize010')); + await Utils.sleep(100); + await ch1.click(); + await Utils.sleep(100); + await ch1.inputText('哈哈哈哈哈哈') + await Utils.sleep(100); + let ch2: Component = await driver.findComponent(ON.id('searchFontSizeLong010')); + await ch2.click(); + await Utils.sleep(100); + await ch2.inputText('ABCpriorities. Sometimes, a significant changeChange,a constant and inevitable,everychange ') + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_010 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_011 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_011 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_011', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_011 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize011") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize011TextArea2')); + await Utils.sleep(100); + await ch1.click(); + await Utils.sleep(100); + await ch1.inputText('ABC prioritiesSometimes,a significant change Change') + await Utils.sleep(100); + let ch2: Component = await driver.findComponent(ON.id('searchFontSize011TextArea3')); + await ch2.click(); + await Utils.sleep(100); + await ch2.inputText('ABCpriorities. Sometimes, a significant changeChange,a constant and inevitable,everychange') + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_011 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_012 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_012 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_012', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_012 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize012"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize012TextArea1')); + await Utils.sleep(100); + await ch1.click(); + await Utils.sleep(100); + await ch1.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + windowSnap.snapShot('first012'); + await Utils.sleep(1000); + let button1: Component = await driver.findComponent(ON.id('ButtonChange1')); + await Utils.sleep(100); + await button1.click(); + await Utils.sleep(100); + windowSnap.snapShot('second012'); + await Utils.sleep(1000); + let button2: Component = await driver.findComponent(ON.id('ButtonChange2')); + await Utils.sleep(100); + await button2.click(); + await Utils.sleep(100); + windowSnap.snapShot('third012'); + await Utils.sleep(1000); + let button3: Component = await driver.findComponent(ON.id('ButtonChange3')); + await Utils.sleep(100); + await button3.click(); + await Utils.sleep(100); + windowSnap.snapShot('forth012'); + await Utils.sleep(1000); + let button4: Component = await driver.findComponent(ON.id('ButtonChange4')); + await Utils.sleep(100); + await button4.click(); + await Utils.sleep(100); + windowSnap.snapShot('fifth012'); + await Utils.sleep(1000); + let button5: Component = await driver.findComponent(ON.id('ButtonChange5')); + await Utils.sleep(100); + await button5.click(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_012 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_013 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_013 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_013', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_013 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize013") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize013TextArea2')); + await Utils.sleep(100); + await ch1.click(); + await Utils.sleep(100); + await ch1.inputText('ABC prioritiesSometimes,a significant change Change') + windowSnap.snapShot('first013'); + await Utils.sleep(1000) + let button1: Component = await driver.findComponent(ON.id('ButtonChangeText013')); + await Utils.sleep(100); + await button1.click(); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_013 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_014 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_014 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_014', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_014 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize014") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize014TextArea2')); + await Utils.sleep(100); + await ch1.click(); + await Utils.sleep(100); + await ch1.inputText('ABC prioritiesSometimes,a significant change Change'); + windowSnap.snapShot('first014'); + await Utils.sleep(1000); + let button1: Component = await driver.findComponent(ON.id('ButtonSelectText014')); + await Utils.sleep(100); + await button1.click(); + await Utils.sleep(100); + let copy: Component = await driver.findComponent(ON.text('剪切')) + await copy?.click(); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_014 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize015"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize015TextArea1')); + await Utils.sleep(100); + await ch1.click(); + await Utils.sleep(100); + await ch1.inputText('ABC priorities'); + await Utils.sleep(1500); + await windowSnap.snapShot(); + await Utils.sleep(1500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize015"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize015TextArea1')); + await Utils.sleep(100); + await ch1.click(); + await Utils.sleep(100); + await ch1.inputText('ABC priorities'); + await Utils.sleep(1000); + let button: Component = await driver.findComponent(ON.id('ButtonStopEditingText015')); + await Utils.sleep(100); + await button.click(); + await Utils.sleep(1500); + await windowSnap.snapShot(); + await Utils.sleep(1500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_3 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_3 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_3', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize015"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize015TextArea1')); + await Utils.sleep(200); + await ch1.click(); + await Utils.sleep(200); + await ch1.inputText('ABC priorities.Sometimes,a significant change'); + await Utils.sleep(1500); + await windowSnap.snapShot(); + await Utils.sleep(1500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_3 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_4 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_4 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_4', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize015"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize015TextArea1')); + await Utils.sleep(1000); + await ch1.inputText('ABC priorities.Sometimes,a significant change'); + await Utils.sleep(100); + let button: Component = await driver.findComponent(ON.id('ButtonStopEditingText015')); + await Utils.sleep(100); + await button.click(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_4 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_5 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_5 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_5', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize015"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize015TextArea1')); + await Utils.sleep(1000); + await ch1.inputText('ABC priorities ' + + 'Sometimes,a significant change Change,a ' + + 'constant and inevitable,every change ' + + 'brings the potentialfor growth and new ' + + 'beginnings,But remember,every change ' + + 'brings the potentialfor,ABC priorities ' + + 'Sometimes,a significantchange Change,a ' + + 'constant and inevitable,every change ' + + 'brings the potential for growth and new ' + + 'beginnings,But remember,every change ' + + 'brings the potential for ') + await Utils.sleep(1500); + await windowSnap.snapShot(); + await Utils.sleep(1500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_5 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_6 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_6 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_6', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_6 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize015"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize015TextArea1')); + await Utils.sleep(1000); + await ch1.inputText('ABC priorities ' + + 'Sometimes,a significant change Change,a ' + + 'constant and inevitable,every change ' + + 'brings the potentialfor growth and new ' + + 'beginnings,But remember,every change ' + + 'brings the potentialfor,ABC priorities ' + + 'Sometimes,a significantchange Change,a ' + + 'constant and inevitable,every change ' + + 'brings the potential for growth and new ' + + 'beginnings,But remember,every change ' + + 'brings the potential for ') + await Utils.sleep(1000); + let button: Component = await driver.findComponent(ON.id('ButtonStopEditingText015')); + await Utils.sleep(100); + await button.click(); + await Utils.sleep(1500); + await windowSnap.snapShot(); + await Utils.sleep(1500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_015_6 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_016 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_016 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_016', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_016 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize016"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let button: Component = await driver.findComponent(ON.id('ButtonChangeText016_1')); + await Utils.sleep(100); + await button.click(); + await Utils.sleep(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize016TextArea1')); + await Utils.sleep(100); + await ch1.click(); + await Utils.sleep(100); + windowSnap.snapShot('first016'); + await Utils.sleep(1000); + let button2: Component = await driver.findComponent(ON.id('ButtonChangeText016_2')); + await Utils.sleep(100); + await button2.click(); + await ch1.click(); + await Utils.sleep(100); + await Utils.sleep(100); + windowSnap.snapShot('second016'); + await Utils.sleep(1000); + let button3: Component = await driver.findComponent(ON.id('ButtonChangeText016_3')); + await Utils.sleep(100); + await button3.click(); + await ch1.click(); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_016 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_017 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_017 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_017', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_017 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize017"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize017')); + await Utils.sleep(100); + await ch1.inputText('哈哈哈哈哈哈'); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_017 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_018 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_018 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_018', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_018 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize018"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize018TextInput')); + await Utils.sleep(100); + await ch1.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + let ch2: Component = await driver.findComponent(ON.id('searchFontSize018TextInput_1')); + await Utils.sleep(100); + await ch2.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + let ch3: Component = await driver.findComponent(ON.id('searchFontSize018TextInput_2')); + await Utils.sleep(100); + await ch3.inputText('ABC priorities ' + + 'Sometimes,a significant change Change,a ' + + 'constant and inevitable,every change '); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_018 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_019 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_019 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_019', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_019 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize019"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize019TextArea')); + await Utils.sleep(100); + await ch1.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + let ch2: Component = await driver.findComponent(ON.id('searchFontSize019TextArea_1')); + await Utils.sleep(100); + await ch2.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + let ch3: Component = await driver.findComponent(ON.id('searchFontSize019TextArea_2')); + await Utils.sleep(100); + await ch3.inputText('ABC priorities ' + + 'Sometimes,a significant change Change,a ' + + 'constant and inevitable,every change '); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_019 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_020 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_020 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_020 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize020"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let button1: Component = await driver.findComponent(ON.id('ButtonChangeHeight020_1')); + await Utils.sleep(100); + await button1.click(); + await Utils.sleep(100); + windowSnap.snapShot('first020'); + await Utils.sleep(1000); + let button2: Component = await driver.findComponent(ON.id('ButtonChangeHeight020_3')); + await Utils.sleep(100); + await button2.click(); + await Utils.sleep(100); + windowSnap.snapShot('second020'); + await Utils.sleep(1000); + let button3: Component = await driver.findComponent(ON.id('ButtonChangeHeight020_3')); + await Utils.sleep(100); + await button3.click(); + await Utils.sleep(100); + windowSnap.snapShot('third020'); + await Utils.sleep(1000); + let button4: Component = await driver.findComponent(ON.id('ButtonChangeHeight020_4')); + await Utils.sleep(100); + await button4.click(); + await Utils.sleep(100); + windowSnap.snapShot('forth020'); + await Utils.sleep(1000); + let button5: Component = await driver.findComponent(ON.id('ButtonChangeHeight020_5')); + await Utils.sleep(100); + await button5.click(); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_020 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_021 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_021 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_021', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_021 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize021"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize021TextInput')); + await Utils.sleep(100); + await ch1.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('first021'); + await Utils.sleep(1000); + await ch1.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + windowSnap.snapShot('second021'); + await Utils.sleep(1000); + let ch2: Component = await driver.findComponent(ON.id('searchFontSize021TextArea')); + await Utils.sleep(100); + await ch2.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('third021'); + await Utils.sleep(1000); + await ch2.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_021 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_022 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_022 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_022', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_022 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize022"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize022TextInput')); + await Utils.sleep(100); + await ch1.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('first022'); + await Utils.sleep(1000); + await ch1.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_022 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_023 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_023 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_023', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_023 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize023"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize023TextArea')); + await Utils.sleep(100); + await ch1.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('first023'); + await Utils.sleep(1000); + await ch1.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_023 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_024 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_024 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_024', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_024 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize024"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('searchFontSize024TextInput')); + await Utils.sleep(100); + await textInput.inputText('哈哈哈哈哈哈哈哈哈哈已'); + await Utils.sleep(100); + await textInput?.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll?.click(); + await Utils.sleep(500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await Utils.sleep(100); + await copy?.click(); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('searchFontSize024TextArea')); + await Utils.sleep(100); + await textArea?.click(); + await Utils.sleep(100); + await textInput.doubleClick(); + await Utils.sleep(1000); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await Utils.sleep(100); + await paste?.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_024 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_025 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_025 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_025', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_025 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize025"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('searchFontSize025TextArea')); + await Utils.sleep(100); + await textArea.inputText('哈哈哈哈哈哈哈哈哈哈已'); + await Utils.sleep(100); + await textArea?.longClick(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await selectAll?.click(); + await Utils.sleep(500); + let copy: Component = await driver.findComponent(ON.text('复制')); + await Utils.sleep(100); + await copy?.click(); + await Utils.sleep(100); + let textInput: Component = await driver.findComponent(ON.id('searchFontSize025TextInput')); + await Utils.sleep(100); + await textInput?.click(); + await Utils.sleep(100); + await textArea.doubleClick(); + await Utils.sleep(1000); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await Utils.sleep(100); + await paste?.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_025 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_026 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_026 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_026', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_026 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize026"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize026TextInput2')); + await Utils.sleep(100); + await ch1.click(); + await Utils.sleep(100); + await ch1.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + let ch2: Component = await driver.findComponent(ON.id('searchFontSize026TextInput3')); + await ch2.click(); + await Utils.sleep(100); + await ch2.inputText('ABCpriorities. Sometimes, a significant changeChange,a constant and inevitable,everychange '); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_026 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_027 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_027 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_027', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_027 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize027") + await Utils.sleep(100) + let driver: Driver = Driver.create(); + await driver.delayMs(100) + let ch1: Component = await driver.findComponent(ON.id('searchFontSize027TextInput')); + await Utils.sleep(100) + await ch1.click() + await Utils.sleep(100) + await ch1.inputText('ABC prioritiesSometimes,a significant change Change') + let button1: Component = await driver.findComponent(ON.id('ButtonChange1')); + await Utils.sleep(100) + await button1.click() + await Utils.sleep(100) + windowSnap.snapShot('first027'); + await Utils.sleep(1000); + let button2: Component = await driver.findComponent(ON.id('ButtonChange2')); + await Utils.sleep(100) + await button2.click() + await Utils.sleep(100) + windowSnap.snapShot('second027'); + await Utils.sleep(1000); + let button3: Component = await driver.findComponent(ON.id('ButtonChange3')); + await Utils.sleep(100) + await button3.click() + await Utils.sleep(100) + windowSnap.snapShot('third027'); + await Utils.sleep(1000); + let button4: Component = await driver.findComponent(ON.id('ButtonChange4')); + await Utils.sleep(100) + await button4.click() + await Utils.sleep(100) + windowSnap.snapShot('forth027'); + await Utils.sleep(1000); + let button5: Component = await driver.findComponent(ON.id('ButtonChange5')); + await Utils.sleep(100) + await button5.click() + await Utils.sleep(100) + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_027 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_028 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_028 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_028', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_028 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize028"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize028TextArea2')); + await Utils.sleep(100); + await ch1.click(); + await Utils.sleep(100); + await ch1.inputText('ABC prioritiesSometimes,a significant change Change'); + windowSnap.snapShot('first028'); + await Utils.sleep(1000); + let button1: Component = await driver.findComponent(ON.id('ButtonChangeText028')); + await Utils.sleep(100); + await button1.click(); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_028 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_029 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_029 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_029', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_029 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize029"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100) + let ch1: Component = await driver.findComponent(ON.id('searchFontSize029TextInput2')); + await Utils.sleep(100); + await ch1.click(); + await Utils.sleep(100); + await ch1.inputText('ABC prioritiesSometimes,a significant change Change'); + windowSnap.snapShot('first029'); + await Utils.sleep(1000); + let button1: Component = await driver.findComponent(ON.id('ButtonSelectText029')); + await Utils.sleep(100); + await button1.click(); + await Utils.sleep(100); + let copy: Component = await driver.findComponent(ON.text('剪切')); + await copy?.click(); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_029 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_030 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_030 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_030 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize030"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let buttonNormal: Component = await driver.findComponent(ON.id('ButtonChangeTypeNormalText030')); + await Utils.sleep(100); + await buttonNormal.click(); + await Utils.sleep(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize030TextInput')); + await Utils.sleep(100); + await ch1.inputText('123456@com!#$%^&abcdefg'); + windowSnap.snapShot('first030'); + await Utils.sleep(1000); + let buttonPassword: Component = await driver.findComponent(ON.id('ButtonChangeTypePassword030')); + await Utils.sleep(100); + await buttonPassword.click(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_030 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_1 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_1 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_1', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_1 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize031"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize031TextArea1')); + await Utils.sleep(100); + await ch1.click(); + await Utils.sleep(100); + await ch1.inputText('ABC priorities'); + await Utils.sleep(1500); + await windowSnap.snapShot(); + await Utils.sleep(1500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_1 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_2 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_2 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_2', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_2 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize031"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize031TextArea1')); + await Utils.sleep(100); + await ch1.click(); + await Utils.sleep(100); + await ch1.inputText('ABC priorities'); + await Utils.sleep(1000); + let button: Component = await driver.findComponent(ON.id('ButtonStopEditingText031')); + await Utils.sleep(100); + await button.click(); + await Utils.sleep(1500); + await windowSnap.snapShot(); + await Utils.sleep(1500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_2 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_3 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_3 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_3', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_3 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize031"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize031TextArea1')); + await Utils.sleep(200); + await ch1.click(); + await Utils.sleep(200); + await ch1.inputText('ABC priorities.Sometimes,a significant change'); + await Utils.sleep(1500); + await windowSnap.snapShot(); + await Utils.sleep(1500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_3 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_4 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_4 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_4', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_4 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize031"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize031TextArea1')); + await Utils.sleep(1000); + await ch1.inputText('ABC priorities.Sometimes,a significant change'); + await Utils.sleep(100); + let button: Component = await driver.findComponent(ON.id('ButtonStopEditingText031')); + await Utils.sleep(100); + await button.click(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_4 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_5 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_5 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_5', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_5 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize031"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize031TextArea1')); + await Utils.sleep(1000); + await ch1.inputText('ABC priorities ' + + 'Sometimes,a significant change Change,a ' + + 'constant and inevitable,every change ' + + 'brings the potentialfor growth and new ' + + 'beginnings,But remember,every change ' + + 'brings the potentialfor,ABC priorities ' + + 'Sometimes,a significantchange Change,a ' + + 'constant and inevitable,every change ' + + 'brings the potential for growth and new ' + + 'beginnings,But remember,every change ' + + 'brings the potential for ') + await Utils.sleep(1500); + await windowSnap.snapShot(); + await Utils.sleep(1500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_5 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_6 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_6 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_6', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_6 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize031"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let ch1: Component = await driver.findComponent(ON.id('searchFontSize031TextArea1')); + await Utils.sleep(1000); + await ch1.inputText('ABC priorities ' + + 'Sometimes,a significant change Change,a ' + + 'constant and inevitable,every change ' + + 'brings the potentialfor growth and new ' + + 'beginnings,But remember,every change ' + + 'brings the potentialfor,ABC priorities ' + + 'Sometimes,a significantchange Change,a ' + + 'constant and inevitable,every change ' + + 'brings the potential for growth and new ' + + 'beginnings,But remember,every change ' + + 'brings the potential for ') + await Utils.sleep(1000); + let button: Component = await driver.findComponent(ON.id('ButtonStopEditingText031')); + await Utils.sleep(100); + await button.click(); + await Utils.sleep(1500); + await windowSnap.snapShot(); + await Utils.sleep(1500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_031_6 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_032 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_032 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_032', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_032 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize032"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let button: Component = await driver.findComponent(ON.id('ButtonChangeText032_1')); + await Utils.sleep(100); + await button.click(); + await Utils.sleep(100); + windowSnap.snapShot('first032'); + await Utils.sleep(1000); + let button2: Component = await driver.findComponent(ON.id('ButtonChangeText032_2')); + await Utils.sleep(100); + await button2.click(); + await Utils.sleep(100); + windowSnap.snapShot('second032'); + await Utils.sleep(1000); + let button3: Component = await driver.findComponent(ON.id('ButtonChangeText032_3')); + await Utils.sleep(100); + await button3.click(); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_032 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_033 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_033 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_033', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_033 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize033"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('searchFontSize033TextInput')); + await Utils.sleep(100); + await textInput.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('first033'); + await Utils.sleep(1000); + await textInput.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('searchFontSize033TextArea')); + await Utils.sleep(100); + await textArea.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('second033'); + await Utils.sleep(1000); + await textArea.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_033 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_034 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_034 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_034', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_034 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize034") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('searchFontSize034TextInput')); + await Utils.sleep(100); + await textInput.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('first'); + await Utils.sleep(1000); + await textInput.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('searchFontSize034TextArea')); + await Utils.sleep(100); + await textArea.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('second'); + await Utils.sleep(1000); + await textArea.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('searchFontSize034')); + await Utils.sleep(100); + await search.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('third'); + await Utils.sleep(1000); + await search.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_034 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_035 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_035 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_035', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_035 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize035"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('searchFontSize035TextInput')); + await Utils.sleep(100); + await textInput.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('first'); + await Utils.sleep(1000); + await textInput.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('searchFontSize035TextArea')); + await Utils.sleep(100); + await textArea.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('second'); + await Utils.sleep(1000); + await textArea.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('searchFontSize035')); + await Utils.sleep(100); + await search.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('third'); + await Utils.sleep(1000); + await search.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_035 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_036 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_036 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_036', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_036 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize036"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('searchFontSize036TextInput')); + await Utils.sleep(100); + await textInput.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('first'); + await Utils.sleep(1000); + await textInput.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('searchFontSize036TextArea')); + await Utils.sleep(100); + await textArea.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('second'); + await Utils.sleep(1000); + await textArea.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('searchFontSize036')); + await Utils.sleep(100); + await search.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('third'); + await Utils.sleep(1000); + await search.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_036 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_037 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_037 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_037', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_037 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize037"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('searchFontSize037TextInput')); + await Utils.sleep(100); + await textInput.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('first'); + await Utils.sleep(1000); + await textInput.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('searchFontSize037TextArea')); + await Utils.sleep(100); + await textArea.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('second'); + await Utils.sleep(1000); + await textArea.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('searchFontSize037')); + await Utils.sleep(100); + await search.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('third'); + await Utils.sleep(1000); + await search.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_037 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_038 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_038 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_038', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_038 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize038"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('searchFontSize038TextInput')); + await Utils.sleep(100); + await textInput.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('first'); + await Utils.sleep(1000); + await textInput.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('searchFontSize038TextArea')); + await Utils.sleep(100); + await textArea.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('second'); + await Utils.sleep(1000); + await textArea.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('searchFontSize038')); + await Utils.sleep(100); + await search.inputText('ABC prioritiesSometimes'); + await Utils.sleep(100); + windowSnap.snapShot('third'); + await Utils.sleep(1000); + await search.inputText('ABC prioritiesSometimes,a significant change Change'); + await Utils.sleep(100); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXT_MINFONTSIZE_038 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonTextStyleTest/UiComponentTextCommonTextStyle.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonTextStyleTest/UiComponentTextCommonTextStyle.test.ets new file mode 100644 index 00000000..6add9e01 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextCommonTextStyleTest/UiComponentTextCommonTextStyle.test.ets @@ -0,0 +1,888 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton } from '@ohos.UiTest' + +export default function UiComponentTextCommonTextStyleTest() { + + describe('UiComponentTextCommonTextStyleTest', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(100); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0210 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0210 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0210', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0210 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0210") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0210 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0220 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0220 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0220', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0220 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0220") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0220 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0320 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0320 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0320', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0320 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0320") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextStyle0320')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0320 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0330 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0330 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0330', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0330 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0330") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextStyle0330')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0330 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0340 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0340 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0340', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0340 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0340") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextStyle0340')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0340 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0350 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0350 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0350', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0350 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0350") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextStyle0350')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0350 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0360 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0360 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0360', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0360 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0360") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextStyle0360')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0360 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0730 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0730 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0730', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0730 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0730") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextStyle0730')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0730 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0740 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0740 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0740', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0740 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0740") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextStyle0740')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0740 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0750 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0750 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0750', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0750 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0750") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextStyle0750')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0750 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0760 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0760 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0760', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0760 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0760") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextStyle0760')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0760 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0770 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0770 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0770', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0770 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0770") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextStyle0770')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0770 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0780 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0780 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0780', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0780 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0780") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextStyle0780')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0780 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0790 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0790 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0790', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0790 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0790") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0790 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0800 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0800 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0800', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0800 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0800") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0800 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0810 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0810 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0810', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0810 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0810") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextStyle0810')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0810 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0820 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0820 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0820', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0820 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0820") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextStyle0820')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0820 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0830 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0830 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0830', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0830 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0830") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextStyle0830')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0830 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0840 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0840 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0840', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0840 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0840") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextStyle0840')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_0840 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1150 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1150 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1150', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1150 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1150") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextStyle1150')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1150 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1160 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1160 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1160', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1160 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1160") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextStyle1160')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1160 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1170 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1170 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1170', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1170 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1170") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextStyle1170')); + await Utils.sleep(100); + await textArea.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await textArea.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1170 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1450 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1450 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1450', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1450 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1450") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('text1450')); + await Utils.sleep(100); + await text.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await text.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1450 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1460 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1460 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1460', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1460 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1460") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('text1460')); + await Utils.sleep(100); + await text.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1460 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1470 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1470 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1470', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1470 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1470") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let text: Component = await driver.findComponent(ON.id('text1470')); + await Utils.sleep(100); + await text.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1470 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1850 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1850 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1850', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1850 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1850") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('search1850')); + await Utils.sleep(100); + await search.longClick(); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1850 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1860 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1860 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1860', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1860 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1860") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('search1860')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1860 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1870 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1870 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1870', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1870 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1870") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('search1870')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1870 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1880 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1880 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1880', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1880 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1880") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1880 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1890 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1890 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1890', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1890 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1890") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1890 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1910 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1910 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1910', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1910 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1910") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1910 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1920 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1920 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1920', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1920 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1920") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1920 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1930 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1930 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1930', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1930 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1930") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('search1930')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1930 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1940 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1940 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1940', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1940 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1940") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('search1940')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_1940 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2040 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2040 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2040") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('search2040')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2040 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2050 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2050 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2050 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2050") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('search2050')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2050 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2060 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2060 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2060 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('search2060')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2060 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2070 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2070 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2070") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('search2070')); + await Utils.sleep(100); + await search.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await search.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2070 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2120 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2120 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2120 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2120") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let richEditor: Component = await driver.findComponent(ON.id('richEditor2120')); + await Utils.sleep(100); + await richEditor.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await richEditor.longClick(); + await Utils.sleep(100); + let select: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await select.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2120 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2130 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2130 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2130', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2130 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2130") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let richEditor: Component = await driver.findComponent(ON.id('richEditor2130')); + await Utils.sleep(100); + await richEditor.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await richEditor.longClick(); + await Utils.sleep(100); + let select: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await select.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2130 finish.`); + done(); + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2140 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2140 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2140', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2140 start.`); + Settings.createWindow("testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2140") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let richEditor: Component = await driver.findComponent(ON.id('richEditor2140')); + await Utils.sleep(100); + await richEditor.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(100); + await richEditor.longClick(); + await Utils.sleep(100); + let select: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await select.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_COMMON_TEXTSTYLE_2140 finish.`); + done(); + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextDecorationTest/UiComponentTextDecorationTest.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextDecorationTest/UiComponentTextDecorationTest.test.ets new file mode 100644 index 00000000..d969adbe --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextDecorationTest/UiComponentTextDecorationTest.test.ets @@ -0,0 +1,2098 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton, UiWindow, DisplayRotation } from '@ohos.UiTest' + +export default function UiComponentTextDecorationTest() { + + describe('UiComponentTextDecorationTest', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0010 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0010 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0010')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0010')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0010')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0010')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0010 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0020 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0020 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0020 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0020')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0020')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0020')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0020')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0020 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0030 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0030 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0030 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0030") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0030')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0030')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0030')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0030')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0030 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0040 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0040 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0040") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0040')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0040')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0040')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0040')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0040 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0050 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0050 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0050 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0050") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0050')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0050')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0050')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0050')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0050 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0060 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0060 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0060 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0060')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0060')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0060')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0060')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0060 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0070 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0070 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0070") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0070')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0070')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0070')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0070')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0070 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0080 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0080 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0080', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0080 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0080") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0080')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0080 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0090 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0090 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0090', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0090 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0090") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0090')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0090')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0090')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0090')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0090 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0100 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0100 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0100") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0100')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0100')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0100')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0100')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0100 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0110 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0110 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0110', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0110 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0110')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0110')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0110')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0110')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0110 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0120 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0120 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0120 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0120") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0120')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0120')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0120')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0120')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0120 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0130 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0130 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0130', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0130 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0130") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0130')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0130')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0130')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0130')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0130 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0140 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0140 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0140', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0140 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0140") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0140')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0140')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0140')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0140')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0140 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0150 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0150 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0150', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0150 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0150") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0150')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0150')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0150')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0150')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0150 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0160 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0160 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0160', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0160 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0160") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0160')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0160 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0170 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0170 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0170', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0170 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0170") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0170')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0170')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0170')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0170')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0170 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0180 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0180 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0180', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0180 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0180") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0180')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0180')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0180')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0180')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0180 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0190 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0190 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0190', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0190 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0190") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0190')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0190')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0190')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0190')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0190 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0200 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0200 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0200', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0200 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0200") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0200')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0200')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0200')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0200')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0200 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0210 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0210 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0210', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0210 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0210") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0210')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0210')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0210')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0210')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0210 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0220 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0220 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0220', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0220 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0220") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0220')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0220')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0220')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0220')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0220 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0230 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0230 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0230', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0230 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0230") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0230')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0230')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0230')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0230')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0230 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0240 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0240 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0240', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0240 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0240") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0240')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0240 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0250 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0250 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0250', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0250 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0250") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0250')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0250 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0260 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0260 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0260', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0260 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0260") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0260')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + let select: Component = await driver.findComponent(ON.id('selectButton0260')); + await Utils.sleep(100); + await select.click(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll?.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0260 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0270 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0270 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0270', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0270 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0270") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0270')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + let select: Component = await driver.findComponent(ON.id('selectButton0270')); + await Utils.sleep(100); + await select.click(); + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll?.click(); + await Utils.sleep(100); + let text: Component = await driver.findComponent(ON.id('text0270')); + await Utils.sleep(100); + let textInput: Component = await driver.findComponent(ON.id('textInput0270')); + await Utils.sleep(100); + await text.dragTo(textInput) + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0270 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0280 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0280 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0280', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0280 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0280") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0280 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0290 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0290 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0290', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0290 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0290") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0290')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0290 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0300 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0300 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0300', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0300 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0300") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0300')); + await Utils.sleep(1000); + await changeLine.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0300 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0310 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0310 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0310', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0310 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0310") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0310')); + await Utils.sleep(1000); + await changeLine.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0310 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0320 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0320 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0320', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0320 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0320") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0320')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0320 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0330 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0330 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0330', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0330 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0330") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0330')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0330 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0360 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0360 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0360', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0360 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0360") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0360')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await driver.setDisplayRotation(DisplayRotation.ROTATION_0); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0360 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0380 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0380 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0380', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0380 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0380") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0380')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0380')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0380')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0380')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0380 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0390 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0390 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0390', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0390 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0390") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0390')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0390')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0390')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0390')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0390 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0400 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0400 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0400', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0400 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0400") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0400')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0400')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0400')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0400')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0400 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0410 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0410 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0410', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0410 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0410") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0410')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0410')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0410')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0410')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0410 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0420 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0420 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0420', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0420 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0420") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0420')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0420')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0420')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0420')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0420 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0430 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0430 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0430', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0430 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0430") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0430')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0430')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0430')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0430')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0430 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0440 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0440 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0440', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0440 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0440") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0440')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0440')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0440')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0440')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0440 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0450 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0450 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0450', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0450 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0450") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0450')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0450 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0460 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0460 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0460', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0460 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0460") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0460')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + let addText: Component = await driver.findComponent(ON.id('addTextBt0460')); + await Utils.sleep(100); + await addText.click(); + await Utils.sleep(100); + let deleteText: Component = await driver.findComponent(ON.id('deleteTextBt0460')); + await Utils.sleep(100); + await deleteText.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0460 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0480 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0480 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0480', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0480 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0480") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0480')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0480 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0490 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0490 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0490', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0490 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0490") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0490')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0490 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0500 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0500 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0500', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0500 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0500") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0500')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0500')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0500')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0500')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0500 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0510 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0510 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0510', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0510 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0510") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0510')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0510')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0510')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0510')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0510 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0520 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0520 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0520', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0520 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0520") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0520')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0520')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0520')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0520')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0520 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0530 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0530 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0530', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0530 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0530") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0530')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0530')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0530')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0530')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0530 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0540 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0540 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0540', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0540 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0540") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0540')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0540')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0540')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0540')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0540 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0550 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0550 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0550', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0550 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0550") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0550')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0550')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0550')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0550')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0550 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0560 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0560 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0560', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0560 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0560") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0560')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0560')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0560')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0560')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0560 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0570 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0570 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0570', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0570 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0570") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0570')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0570 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0580 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0580 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0580', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0580 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0580") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0580')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + let addText: Component = await driver.findComponent(ON.id('addTextBt0580')); + await Utils.sleep(100); + await addText.click(); + await Utils.sleep(100); + let deleteText: Component = await driver.findComponent(ON.id('deleteTextBt0580')); + await Utils.sleep(100); + await deleteText.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0580 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0600 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0600 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0600', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0600 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0600") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0600')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0600 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0610 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0610 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0610', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0610 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0610") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0610')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0610')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0610')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0610')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0610 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0620 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0620 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0620', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0620 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0620") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0620')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0620')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0620')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0620')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0620 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0630 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0630 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0630', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0630 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0630") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0630')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0630')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0630')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0630')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0630 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0640 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0640 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0640', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0640 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0640") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0640')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0640')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0640')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0640')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0640 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0650 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0650 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0650', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0650 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0650") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0650')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0650')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0650')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0650')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0650 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0660 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0660 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0660', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0660 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0660") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0660')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0660')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0660')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0660')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0660 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0670 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0670 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0670', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0670 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0670") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let underlineButton: Component = await driver.findComponent(ON.id('underlineBt0670')); + await Utils.sleep(100); + await underlineButton.click(); + await Utils.sleep(100); + let underLineThroughButton: Component = await driver.findComponent(ON.id('underLineThroughBt0670')); + await Utils.sleep(100); + await underLineThroughButton.click(); + await Utils.sleep(100); + let overlineButton: Component = await driver.findComponent(ON.id('overlineBt0670')); + await Utils.sleep(100); + await overlineButton.click(); + await Utils.sleep(100); + let noLineButton: Component = await driver.findComponent(ON.id('noneBt0670')); + await Utils.sleep(100); + await noLineButton.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0670 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0680 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0680 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0680', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0680 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0680") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0680')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0680 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0690 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0690 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0690', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0690 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0690") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0690')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + let addText: Component = await driver.findComponent(ON.id('addTextBt0690')); + await Utils.sleep(100); + await addText.click(); + await Utils.sleep(100); + let deleteText: Component = await driver.findComponent(ON.id('deleteTextBt0690')); + await Utils.sleep(100); + await deleteText.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0690 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0710 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0710 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0710', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0710 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0710") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0710')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0710 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0720 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0720 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0720', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0720 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0720") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeLine: Component = await driver.findComponent(ON.id('changeLineBt0720')); + await Utils.sleep(100); + await changeLine.click(); + await Utils.sleep(100); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_ATTRIBUTES_FONT_INTERFACE_0720 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0470_01 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0470_01 + * @tc.desc textInput test decoration & longClick + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0470_01', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0470_01 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0470") + await Utils.sleep(200); + let driver: Driver = Driver.create(); + let textInput: Component = await driver.findComponent(ON.id('UiComponentTextDecoration0470_textInput')); + await Utils.sleep(200); + await textInput?.longClick() + await Utils.sleep(200); + let copy: Component = await driver.findComponent(ON.text('复制')); + await Utils.sleep(200); + await copy?.click() + await Utils.sleep(200); + await textInput?.longClick() + await Utils.sleep(200); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await Utils.sleep(200); + await paste?.click() + await Utils.sleep(200); + await textInput?.longClick() + await Utils.sleep(200); + let cut: Component = await driver.findComponent(ON.text('剪切')); + await Utils.sleep(200); + await cut?.click() + await Utils.sleep(500); + windowSnap.snapShot(); + await Utils.sleep(500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0470_01 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0470_01 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0470_01 + * @tc.desc textInput test decoration & drag + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0470_02', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0470_02 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0470") + await Utils.sleep(500); + let driver: Driver = Driver.create(); + let textInput: Component = await driver.findComponent(ON.id('UiComponentTextDecoration0470_textInput')); + let textArea: Component = await driver.findComponent(ON.id('UiComponentTextDecoration0470_textArea')); + await Utils.sleep(500); + await textInput?.longClick() + await Utils.sleep(500); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(500); + await selectAll?.click() + await Utils.sleep(500); + await textInput?.dragTo(textArea) + await Utils.sleep(500); + windowSnap.snapShot(); + await Utils.sleep(500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0470_02 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0590_01 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0590_01 + * @tc.desc search test decoration & longClick + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0590_01', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0590_01 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0470") + await Utils.sleep(200); + let driver: Driver = Driver.create(); + let search: Component = await driver.findComponent(ON.id('UiComponentTextDecoration0470_search')); + await Utils.sleep(200); + await search?.longClick() + await Utils.sleep(200); + let copy: Component = await driver.findComponent(ON.text('复制')); + await Utils.sleep(200); + await copy?.click() + await Utils.sleep(200); + await search?.longClick() + await Utils.sleep(200); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await Utils.sleep(200); + await paste?.click() + await Utils.sleep(200); + await search?.longClick() + await Utils.sleep(200); + let cut: Component = await driver.findComponent(ON.text('剪切')); + await Utils.sleep(200); + await cut?.click() + await Utils.sleep(500); + windowSnap.snapShot(); + await Utils.sleep(500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0590_01 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0590_02 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0590_02 + * @tc.desc search test decoration & drag + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0590_02', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0590_02 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0470") + await Utils.sleep(500); + let driver: Driver = Driver.create(); + let search: Component = await driver.findComponent(ON.id('UiComponentTextDecoration0470_search')); + let textArea: Component = await driver.findComponent(ON.id('UiComponentTextDecoration0470_textArea')); + await Utils.sleep(500); + await search?.longClick() + await Utils.sleep(500); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(500); + await selectAll?.click() + await Utils.sleep(500); + await search?.dragTo(textArea) + await Utils.sleep(500); + windowSnap.snapShot(); + await Utils.sleep(500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0590_02 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0700_01 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0700_01 + * @tc.desc textArea test decoration & longClick + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0700_01', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0700_01 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0470") + await Utils.sleep(200); + let driver: Driver = Driver.create(); + let textArea: Component = await driver.findComponent(ON.id('UiComponentTextDecoration0470_textArea')); + await Utils.sleep(200); + await textArea?.longClick() + await Utils.sleep(200); + let copy: Component = await driver.findComponent(ON.text('复制')); + await Utils.sleep(200); + await copy?.click() + await Utils.sleep(200); + await textArea?.longClick() + await Utils.sleep(200); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await Utils.sleep(200); + await paste?.click() + await Utils.sleep(200); + await textArea?.longClick() + await Utils.sleep(200); + let cut: Component = await driver.findComponent(ON.text('剪切')); + await Utils.sleep(200); + await cut?.click() + await Utils.sleep(500); + windowSnap.snapShot(); + await Utils.sleep(500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0700_01 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0700_02 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0700_02 + * @tc.desc textArea test decoration & drag + */ + it('SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0700_02', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0700_02 start.`); + Settings.createWindow("testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0470") + await Utils.sleep(500); + let driver: Driver = Driver.create(); + let textArea: Component = await driver.findComponent(ON.id('UiComponentTextDecoration0470_textArea')); + let search: Component = await driver.findComponent(ON.id('UiComponentTextDecoration0470_search')); + await Utils.sleep(500); + await textArea?.longClick() + await Utils.sleep(500); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(500); + await selectAll?.click() + await Utils.sleep(500); + await textArea?.dragTo(search) + await Utils.sleep(500); + windowSnap.snapShot(); + await Utils.sleep(500); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_DECOARTION_0700_02 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextInputDeleteCallBackTest/UiComponentTextInputDeleteCallBackTest.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextInputDeleteCallBackTest/UiComponentTextInputDeleteCallBackTest.test.ets new file mode 100644 index 00000000..d6166d9f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextInputDeleteCallBackTest/UiComponentTextInputDeleteCallBackTest.test.ets @@ -0,0 +1,128 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton, UiWindow } from '@ohos.UiTest' + +export default function UiComponentTextInputDeleteCallBackTest() { + + describe('UiComponentTextInputDeleteCallBackTest', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0010 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0010 start.`); + Settings.createWindow("testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputDeleteCallBack0010')); + await Utils.sleep(100); + await textInput.inputText('aa'); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchDeleteCallBack0010')); + await Utils.sleep(100); + await search.inputText('aa'); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaDeleteCallBack0010')); + await Utils.sleep(100); + await textArea.inputText('aa'); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0010 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0020 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0020 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0020 start.`); + Settings.createWindow("testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputDeleteCallBack0020')); + await Utils.sleep(100); + await textInput.inputText('a'); + await Utils.sleep(100); + let search: Component = await driver.findComponent(ON.id('SearchDeleteCallBack0020')); + await Utils.sleep(100); + await search.inputText('a'); + await Utils.sleep(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaDeleteCallBack0020')); + await Utils.sleep(100); + await textArea.inputText('a'); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0020 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0030 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0030 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0030 start.`); + Settings.createWindow("testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0030") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputDeleteCallBack0030')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(1000); + await textInput.inputText('aaaaa'); + await Utils.sleep(1000); + let search: Component = await driver.findComponent(ON.id('SearchDeleteCallBack0030')); + await Utils.sleep(100); + await search.inputText('aaaaa'); + await Utils.sleep(1000); + let textArea: Component = await driver.findComponent(ON.id('TextAreaDeleteCallBack0030')); + await Utils.sleep(100); + await textArea.inputText('aaaaa'); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0030 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextInputReplacementTest/UiComponentTextInputReplacement001.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextInputReplacementTest/UiComponentTextInputReplacement001.test.ets new file mode 100755 index 00000000..dc5d7b52 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextInputReplacementTest/UiComponentTextInputReplacement001.test.ets @@ -0,0 +1,265 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, MouseButton, ON } from '@ohos.UiTest' + +/* + * + * Settings.createWindow(config.url): + * 创建窗口,更改窗口基本配置,更改方式详见model/Settings createWindow方法 + * + * windowSnap.snapShot(globalThis.context): + * 窗口截屏&图片文件保存,存储在设备端 + * 存储文件固定,单挑用例执行后覆盖,用于自动化UI对比 + * 支持调试更改文件名为时间戳格式,更改model/snapShot createAndGetFile方法 注释L35,放开L32,L33 + * + * Logger日志使用方法: + * import Logger form './model/Logger' + * Logger.info(TAG,`config = ${config}, err = ${JSON.stringify(exception)}`) + * */ + +export default function UiComponentTextInputReplacementTest001() { + + describe('UiComponentTextInputReplacementTest001', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_ONSUBMIT_0100 + * @tc.name SUB_ACE_UI_COMPONENT_ONSUBMIT_0100 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_ONSUBMIT_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_ONSUBMIT_0100 start.`); + Settings.createWindow("testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0010") + await Utils.sleep(1000) + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('richEditor')); + await textInput.longClick(); + await Utils.sleep(100); + let selectMoreOrBackButton: Component = await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await selectMoreOrBackButton.click(); + await Utils.sleep(1000); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_ONSUBMIT_0100 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0010 + * @tc.name SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0010 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0010 start.`); + Settings.createWindow("testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0020") + await Utils.sleep(1000) + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('richEditor')); + await textInput.longClick(); + await Utils.sleep(100); + let selectMoreOrBackButton: Component = await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await selectMoreOrBackButton.click(); + await Utils.sleep(1000); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0010 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0020 + * @tc.name SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0020 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0020 start.`); + Settings.createWindow("testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0030") + await Utils.sleep(1000) + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('richEditor')); + await textInput.longClick(); + await Utils.sleep(100); + let selectMoreOrBackButton: Component = await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await selectMoreOrBackButton.click(); + await Utils.sleep(1000); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0020 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0030 + * @tc.name SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0030 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0030 start.`); + Settings.createWindow("testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0040") + await Utils.sleep(1000) + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('richEditor')); + await textInput.longClick(); + await Utils.sleep(100); + let selectMoreOrBackButton: Component = await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await selectMoreOrBackButton.click(); + await Utils.sleep(1000); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0030 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0040 + * @tc.name SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0040 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0040 start.`); + Settings.createWindow("testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0050") + await Utils.sleep(1000) + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('richEditor')); + await textInput.longClick(); + await Utils.sleep(100); + let selectMoreOrBackButton: Component = await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await selectMoreOrBackButton.click(); + await Utils.sleep(1000); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0040 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0050 + * @tc.name SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0050 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0050 start.`); + Settings.createWindow("testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0060") + await Utils.sleep(1000) + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('richEditor')); + await textInput.longClick(); + await Utils.sleep(100); + let selectMoreOrBackButton: Component = await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await selectMoreOrBackButton.click(); + await Utils.sleep(1000); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0050 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0060 + * @tc.name SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0060 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0060 start.`); + Settings.createWindow("testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0070") + await Utils.sleep(1000) + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('richEditor')); + await textInput.longClick(); + await Utils.sleep(100); + let selectMoreOrBackButton: Component = await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await selectMoreOrBackButton.click(); + await Utils.sleep(1000); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0060 finish.`); + done() + }) + + + /* + * @tc.number SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0070 + * @tc.name SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0070 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0070 start.`); + Settings.createWindow("testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0080") + await Utils.sleep(1000) + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('richEditor')); + await textInput.longClick(); + await Utils.sleep(100); + let selectMoreOrBackButton: Component = await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await selectMoreOrBackButton.click(); + await Utils.sleep(1000); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0070 finish.`); + done() + }) + + /* + * @tc.number SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0080 + * @tc.name SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0080 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0080', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0080 start.`); + Settings.createWindow("testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0090") + await Utils.sleep(1000) + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('richEditor')); + await textInput.longClick(); + await Utils.sleep(100); + let selectMoreOrBackButton: Component = await driver.findComponent(ON.type('SelectMoreOrBackButton')); + await selectMoreOrBackButton.click(); + await Utils.sleep(1000); + windowSnap.snapShot() + await Utils.sleep(1000) + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_SELECTIONMENU_PC_0080 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextMirrorTest/UiComponentTextMirrorTest.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextMirrorTest/UiComponentTextMirrorTest.test.ets new file mode 100644 index 00000000..50980dbd --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextMirrorTest/UiComponentTextMirrorTest.test.ets @@ -0,0 +1,417 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton, UiWindow, DisplayRotation } from '@ohos.UiTest' + +export default function UiComponentTextMirrorTest() { + + describe('UiComponentTextMirrorTest', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0010 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0010 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0010')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0010 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0040 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0040 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0040") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0040')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0040 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0050 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0050 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0050 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0050") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0050')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0050 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0060 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0060 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0060 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0060')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0060 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0070 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0070 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0070") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0070')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0070 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0080 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0080 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0080', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0080 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0080") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0080')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0080 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0090 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0090 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0090', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0090 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0090") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0090')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0090 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0100 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0100 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0100") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0100')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0100 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0110 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0110 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0110', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0110 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0110')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0110 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0120 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0120 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0120 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0120") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0120')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0120 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0130 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0130 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0130', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0130 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0130") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0130')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0130 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0140 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0140 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0140', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0140 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0140") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0140')); + await Utils.sleep(1000); + await changeDirection.click(); + await Utils.sleep(1000); + let textArea: Component = await driver.findComponent(ON.id('textAreaMirror0140')); + let pos = await textArea.getBoundsCenter(); + await Utils.sleep(1000); + await driver.mouseScroll({ + x: pos.x, y: (pos.y) + }, false, 1); + await Utils.sleep(100); + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0140 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0150 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0150 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0150', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0150 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0150") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0150')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0150 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0160 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0160 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0160', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0160 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0160") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0160')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0160 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0170 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0170 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0170', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0170 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0170") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0170')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0170 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0180 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0180 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0180', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0180 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0180") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeScreen: Component = await driver.findComponent(ON.id('changeScreenBt0180')); + await Utils.sleep(100); + await changeScreen.click(); + await Utils.sleep(1000); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0180')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + await driver.setDisplayRotation(DisplayRotation.ROTATION_0); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0180 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0190 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0190 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0190', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0190 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0190") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let changeDirection: Component = await driver.findComponent(ON.id('changeDirection0190')); + await Utils.sleep(100); + await changeDirection.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0190 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0200 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0200 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0200', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0200 start.`); + Settings.createWindow("testability/pages/UiComponentTextMirror/UiComponentTextMirror0200"); + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await Utils.sleep(1000); + Settings.switchLocales(); + await Utils.sleep(1000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Settings.switchCusLocales('zh-Hans-CN'); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_MIRROR_0200 finish.`); + done(); + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextRefactorAdjustmentTest/UiComponentTextRefactorAdjustmentTest.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextRefactorAdjustmentTest/UiComponentTextRefactorAdjustmentTest.test.ets new file mode 100644 index 00000000..1d1db14b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextRefactorAdjustmentTest/UiComponentTextRefactorAdjustmentTest.test.ets @@ -0,0 +1,645 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton, UiWindow } from '@ohos.UiTest' + +export default function UiComponentTextRefactorAdjustmentTest() { + + describe('UiComponentTextRefactorAdjustmentTest', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0020 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0020 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0020 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextRefactorAdjustment0020')); + await Utils.sleep(100); + await textInput.click(); + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0020 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0050 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0050 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0050 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0050") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextRefactorAdjustment0050')); + await Utils.sleep(100); + await textInput.inputText('123456'); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0050 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0110 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0110 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0110', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0110 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0110") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await Utils.sleep(1000); + let textInput: Component = await driver.findComponent(ON.id('textInputTextRefactorAdjustment0110')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(1000); + await textInput.longClick(); + await Utils.sleep(1000); + let copy: Component = await driver.findComponent(ON.text('复制')); + await Utils.sleep(1000); + await copy.click(); + await Utils.sleep(1000); + let textArea: Component = await driver.findComponent(ON.id('textAreaTextRefactorAdjustment0110')); + await Utils.sleep(1000); + await textArea.longClick(); + await Utils.sleep(1000); + let paste: Component = await driver.findComponent(ON.text('粘贴')); + await Utils.sleep(1000); + await paste.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(3000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0110 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0120 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0120 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0120', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0120 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0120") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextRefactorAdjustment0120')); + await Utils.sleep(100); + await textInput.inputText('@@'); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0120 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0130 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0130 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0130', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0130 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0130") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextRefactorAdjustment0130')); + await Utils.sleep(100); + await textInput.inputText('aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'); + await Utils.sleep(1000); + await textInput.longClick() + await Utils.sleep(1000); + let copy: Component = await driver.findComponent(ON.text('复制')); + await Utils.sleep(1000); + await copy.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(3000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0130 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0140 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0140 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0140', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0140 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0140") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextRefactorAdjustment0140')); + await Utils.sleep(100); + await textInput.inputText('123'); + await Utils.sleep(1000); + await textInput.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0140 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0160 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0160 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0160', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0160 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0160") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextRefactorAdjustment0160')); + await Utils.sleep(100); + await textInput.inputText('哈哈哈哈哈哈哈哈哈哈'); + await Utils.sleep(100); + let point = await textInput.getBoundsCenter(); + await driver.inputText(point, 'abc'); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0160 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0170 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0170 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0170', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0170 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0170") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextRefactorAdjustment0170')); + await Utils.sleep(100); + await textInput.inputText('yyyyyyyyyyyyyyyyy'); + await Utils.sleep(100); + await textInput.click() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0170 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0190 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0190 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0190', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0190 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0190") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('textInputTextRefactorAdjustment0190')); + await Utils.sleep(100); + await textInput.inputText('yyyyyyyyyyyyyyyyy'); + await Utils.sleep(100); + let btn: Component = await driver.findComponent(ON.id('ButtonTextRefactorAdjustment0190')); + await Utils.sleep(100); + await btn.click() + await Utils.sleep(100); + await textInput.doubleClick() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0190 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0230 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0230 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0230', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0230 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0230") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextRefactorAdjustment0230')); + await Utils.sleep(100); + await textInput.inputText('yyyyyyyyyyyyyyyyy'); + await Utils.sleep(100); + await textInput.click() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0230 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0260 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0260 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0260', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0260 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0260") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextRefactorAdjustment0260')); + await Utils.sleep(100); + await textInput.inputText('yyyyyyyyyyyyyyyyy'); + await Utils.sleep(100); + await textInput.click() + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0260 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0270 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0270 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0270', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0270 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0270") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextRefactorAdjustment0270')); + await Utils.sleep(100); + await textArea.inputText('yyyyyyyyyyyyyyyyyyyyyyyyyyyyy'); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0270 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0280 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0280 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0280', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0280 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0280") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(500); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextRefactorAdjustment0280')); + await Utils.sleep(1000); + await textArea.longClick() + await Utils.sleep(1000); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(1000); + await selectAll.click(); + await Utils.sleep(1000); + let copy: Component = await driver.findComponent(ON.text('复制')); + await Utils.sleep(1000); + await copy.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(3000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0280 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0290 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0290 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0290', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0290 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0290") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextRefactorAdjustment0290')); + await Utils.sleep(1000); + await textArea.longClick() + await Utils.sleep(1000); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(1000); + await selectAll.click(); + await Utils.sleep(1000); + let copy: Component = await driver.findComponent(ON.text('复制')); + await Utils.sleep(1000); + await copy.click(); + await Utils.sleep(1000); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextRefactorAdjustment0290')); + await textInput.longClick(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0290 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0300 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0300 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0300', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0300 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0300") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextRefactorAdjustment0300')); + await Utils.sleep(100); + await textArea.longClick() + await Utils.sleep(100); + let selectAll: Component = await driver.findComponent(ON.text('全选')); + await Utils.sleep(100); + await selectAll.click(); + await Utils.sleep(100); + let point = await textArea.getBoundsCenter(); + await Utils.sleep(100); + await driver.mouseScroll({ + x: point.x, y: (point.y) + }, false, 5); + await Utils.sleep(1000); + await textArea.click() + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0300 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0310 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0310 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0310', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0310 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0310") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextRefactorAdjustment0310')); + await Utils.sleep(100); + await textArea.click(); + await Utils.sleep(100); + await driver.triggerKey(2055); + await Utils.sleep(500); + await driver.triggerKey(2055); + await Utils.sleep(500); + await driver.triggerKey(2055); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0310 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0320 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0320 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0320', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0320 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0320") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextRefactorAdjustment0320')); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextRefactorAdjustment0320')); + let search: Component = await driver.findComponent(ON.id('SearchTextRefactorAdjustment0320')); + await Utils.sleep(100); + await textArea.click(); + await textInput.click(); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0320 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0330 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0330 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0330', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0330 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0330") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextRefactorAdjustment0330')); + await Utils.sleep(100); + await textInput.inputText('100hahhahah'); + await Utils.sleep(100); + let button: Component = await driver.findComponent(ON.id('ButtonTextRefactorAdjustment0330')); + await Utils.sleep(1000); + await button.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0330 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0340 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0340 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0340', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0340 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0340") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextRefactorAdjustment0340')); + await Utils.sleep(100); + await textArea.inputText('100hahhahahahhahahahahahahahhahahahahahhahahahahahhaahahahahhahahahahahah'); + await Utils.sleep(100); + let button: Component = await driver.findComponent(ON.id('ButtonTextRefactorAdjustment0340')); + await Utils.sleep(1000); + await button.click(); + await Utils.sleep(1000); + let pos = await textArea.getBoundsCenter(); + await Utils.sleep(1000); + await driver.mouseScroll({ + x: pos.x, y: (pos.y) + }, false, 2); + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0340 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0350 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0350 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0350', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0350 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0350") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextRefactorAdjustment0350')); + await Utils.sleep(100); + await textInput.inputText('100brouhaha'); + await Utils.sleep(100); + await driver.triggerKey(2054); + await Utils.sleep(1000); + let button: Component = await driver.findComponent(ON.id('ButtonTextRefactorAdjustment0350')); + await Utils.sleep(1000); + await button.click(); + await Utils.sleep(2000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0350 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0360 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0360 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0360', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0360 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0360") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextRefactorAdjustment0360')); + let textInput: Component = await driver.findComponent(ON.id('TextInputTextRefactorAdjustment0360')); + let search: Component = await driver.findComponent(ON.id('SearchTextRefactorAdjustment0360')); + await Utils.sleep(100); + await textArea.click(); + await textInput.click(); + await search.click(); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0360 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0380 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0380 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0380', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0380 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0380") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let textArea: Component = await driver.findComponent(ON.id('TextAreaTextRefactorAdjustment0380')); + await Utils.sleep(100); + let pos = await textArea.getBoundsCenter(); + await Utils.sleep(1000); + await driver.mouseScroll({ + x: pos.x, y: (pos.y) + }, false, 5); + await Utils.sleep(4000); + await windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0380 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0420 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0420 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0420', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0420 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0420") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0420 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0440 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0440 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0440', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0440 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0440") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0440 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0450 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0450 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0450', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0450 start.`); + Settings.createWindow("testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0450") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + await Utils.sleep(1000); + windowSnap.snapShot(); + await Utils.sleep(1000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_REFACTOR_ADJUSTMENT_0450 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextSearchEnterKeyTypeTest/UiComponentTextSearchEnterKeyTypeTest.test.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextSearchEnterKeyTypeTest/UiComponentTextSearchEnterKeyTypeTest.test.ets new file mode 100644 index 00000000..62c4886b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/UiComponentTextSearchEnterKeyTypeTest/UiComponentTextSearchEnterKeyTypeTest.test.ets @@ -0,0 +1,244 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' +import Settings from '../model/Settings' +import windowSnap from '../model/snapShot' +import Logger from '../model/Logger' +import Utils from '../model/Utils' +import { Component, Driver, ON, MouseButton, UiWindow } from '@ohos.UiTest' + +export default function UiComponentTextSearchEnterKeyTypeTest() { + + describe('UiComponentTextSearchEnterKeyTypeTest', () => { + afterEach(async (done: Function) => { + if (Settings.windowClass == undefined) { + return + } + + Settings.windowClass.destroyWindow((err) => { + if (err.code) { + Logger.error('TEST', `Failed to destroy the window. Cause : ${JSON.stringify(err)}`) + return; + } + Logger.info('TEST', `Succeeded in destroy the window.`); + }) + await Utils.sleep(1000); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0100 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0100 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0100', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0100 start.`); + Settings.createWindow("testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0100") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextSearchEnterKeyType0100')); + await Utils.sleep(500); + await search.inputText('ABC'); + await Utils.sleep(2000); + await driver.click(1100, 2550) + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0100 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0010 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0010 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0010', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0010 start.`); + Settings.createWindow("testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0010") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextSearchEnterKeyType0010')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0010 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0060 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0060 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0060', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0060 start.`); + Settings.createWindow("testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0060") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextSearchEnterKeyType0060')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0060 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0040 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0040 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0040', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0040 start.`); + Settings.createWindow("testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0040") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextSearchEnterKeyType0040')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0040 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0030 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0030 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0030', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0030 start.`); + Settings.createWindow("testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0030") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextSearchEnterKeyType0030')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0030 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0090 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0090 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0090', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0090 start.`); + Settings.createWindow("testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0090") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextSearchEnterKeyType0090')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0090 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0050 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0050 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0050', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0050 start.`); + Settings.createWindow("testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0050") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextSearchEnterKeyType0050')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0050 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0070 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0070 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0070', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0070 start.`); + Settings.createWindow("testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0070") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextSearchEnterKeyType0070')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0070 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0020 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0020 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0020', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0020 start.`); + Settings.createWindow("testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0020") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextSearchEnterKeyType0020')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0020 finish.`); + done() + }) + /* + * @tc.number SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0080 + * @tc.name SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0080 + * @tc.desc + */ + it('SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0080', 0, async (done: Function) => { + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0080 start.`); + Settings.createWindow("testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0080") + await Utils.sleep(100); + let driver: Driver = Driver.create(); + await driver.delayMs(100); + let search: Component = await driver.findComponent(ON.id('SearchTextSearchEnterKeyType0080')); + await Utils.sleep(1000); + await search.click(); + await Utils.sleep(2000); + await windowSnap.snapShot(); + await Utils.sleep(2000); + Logger.info('TEST', `SUB_ACE_UI_COMPONENT_TEXT_SEARCH_ENTERKEYTYPE_0080 finish.`); + done() + }) + }) +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/model/Settings.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/model/Settings.ets index c74ae272..06042c7a 100644 --- a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/model/Settings.ets +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/test/model/Settings.ets @@ -24,6 +24,7 @@ import { i18n } from '@kit.LocalizationKit'; import { router } from '@kit.ArkUI'; import { systemDateTime } from '@kit.BasicServicesKit'; + const TAG: string = '[TEST]'; async function sleep(time: number): Promise { @@ -36,14 +37,15 @@ async function sleep(time: number): Promise { } class Settings { - isPhone: boolean = true; + isPhone: boolean = false; windowClass: window.Window | undefined = undefined windowCreateType: string = "changeWindow"; private static DEFAULT_WIDTH: number = 720; - private static DEFAULT_HEIGHT: number = 1280; + private static DEFAULT_HEIGHT: number = 1412; private static DEFAULT_DPI: number = 240; - private static DEFAULT_OFFSET_X: number = 0; - private static DEFAULT_OFFSET_Y: number = 60; + private static DEFAULT_OFFSET_X: number = 100; + private static DEFAULT_OFFSET_Y: number = 132; + private portrait: boolean = true changeWindowPosition(windowClass: window.Window, X: number | undefined, Y: number | undefined) { @@ -331,7 +333,6 @@ class Settings { } ; } - getSysDateTime(): Date { try { systemDateTime.getDate().then((date: Date) => { diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/TestAbility.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/TestAbility.ets index 5b2992dc..5fe37a99 100644 --- a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/TestAbility.ets +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/TestAbility.ets @@ -1,6 +1,6 @@ /* - * Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * @@ -58,14 +58,22 @@ export default class TestAbility extends UIAbility { onWindowStageCreate(windowStage: window.WindowStage) { hilog.info(0x0000, 'testTag', '%{public}s', 'TestAbility onWindowStageCreate'); GlobalThis.getInstance().setContext("context", this.context) - - windowStage.loadContent('testability/pages/Index', (err) => { - if (err.code) { - hilog.error(0x0000, 'testTag', 'Failed to load the content. Cause: %{public}s', JSON.stringify(err) ?? ''); - return; + let atManager = abilityAccessCtrl.createAtManager(); + let appFlags = bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION; + let permissionFlags = 0; + bundleManager.getBundleInfoForSelf(appFlags, (err, data) => { + if (err) { + Logger.error(TAG, 'getAllApplicationInfo failed: %{public}s', err.message); + console.error("") } - hilog.info(0x0000, 'testTag', 'Succeeded in loading the content.'); - }); + let tokenID = data.appInfo.accessTokenId; + atManager.grantUserGrantedPermission(tokenID, 'ohos.permission.READ_MEDIA', permissionFlags, (err, data) => { + if (err) { + Logger.info(TAG, `grantUserGrantedPermission fail, err->${JSON.stringify(err)}`) + } + }) + + } onWindowStageDestroy() { diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentCommonAttrCom0080.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentCommonAttrCom0080.ets new file mode 100755 index 00000000..f6f6b1da --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentCommonAttrCom0080.ets @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentCommonAttrCom0080 { + build() { + Column() { + Column() { + Hyperlink('https://example.com/') { + } + } + }.width('100%').height('100%').justifyContent(FlexAlign.Start) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentCustomSpanInvailDate0110.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentCustomSpanInvailDate0110.ets new file mode 100755 index 00000000..aa41b702 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentCustomSpanInvailDate0110.ets @@ -0,0 +1,99 @@ +// xxx.ets +import { drawing } from '@kit.ArkGraphics2D' +import { image } from '@kit.ImageKit' +import { LengthMetrics } from '@kit.ArkUI' + +class MyCustomSpan extends CustomSpan { + constructor(word: string, width: number, height: number) { + super(); + this.word = word; + this.width = width; + this.height = height; + } + + onMeasure(measureInfo: CustomSpanMeasureInfo): CustomSpanMetrics { + this.message = "change log: " + this.height; + return { width: this.width, height: this.height }; + } + + onDraw(context: DrawContext, options: CustomSpanDrawInfo) { + let canvas = context.canvas; + + const brush = new drawing.Brush(); + brush.setColor({ + alpha: 255, + red: 0, + green: 74, + blue: 175 + }); + const font = new drawing.Font(); + font.setSize(25); + const textBlob = drawing.TextBlob.makeFromString(this.word, font, drawing.TextEncoding.TEXT_ENCODING_UTF8); + canvas.attachBrush(brush); + canvas.drawRect({ + left: options.x + 10, + right: options.x + vp2px(this.width) - 10, + top: options.lineTop + 10, + bottom: options.lineBottom - 10 + }); + + brush.setColor({ + alpha: 255, + red: 23, + green: 169, + blue: 141 + }); + canvas.attachBrush(brush); + canvas.drawTextBlob(textBlob, options.x + 20, options.lineBottom - 15); + canvas.detachBrush(); + } + + setWord(word: string) { + this.word = word; + } + + width: number = 160; + word: string = "drawing"; + height: number = 10; + message: string = ''; +} + +@Entry +@Component +struct UIComponentCustomSpanInvailDate0110 { + customSpan1: MyCustomSpan = new MyCustomSpan("Hello", 80, 10); + customSpan3: MyCustomSpan = new MyCustomSpan("World", 80, 40); + style1: MutableStyledString = new MutableStyledString(this.customSpan1); + textStyle: MutableStyledString = new MutableStyledString("123"); + textController: TextController = new TextController(); + imagePixelMap: image.PixelMap | undefined = undefined; + isPageShow: boolean = true; + @State message: string = 'onMeasure '; + + async onPageShow() { + if (!this.isPageShow) { + return + } + this.isPageShow = false; + this.textController.setStyledString(this.style1) + } + + build() { + Row() { + Column() { + Button('change height').onClick(() => { + this.customSpan1.height = 100; + this.message = this.message + this.customSpan1.message; + this.isPageShow = true; + this.onPageShow(); + }).id('UIComponentCustomSpanInvailDate0110_button_01') + Text(this.message).margin(10) + Text(undefined, { controller: this.textController }) + .copyOption(CopyOptions.InApp) + .fontSize(30) + } + .width('100%') + } + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0340.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0340.ets new file mode 100755 index 00000000..9f8be16c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0340.ets @@ -0,0 +1,61 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentEditAbleTextThreeReplacement0340 { + controller: TextInputController = new TextInputController(); + @State inputValue: string = "dfggg"; + + // 自定义键盘组件 + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + if (this.controller.getCaretOffset().index == 0) { + this.inputValue = item + this.inputValue; + } else { + this.inputValue += item; + } + }).id('button_0') + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Button('change point').onClick(() => { + this.controller.caretPosition(2); + }).id('UIComponentEditAbleTextThreeReplacement0340_button_001') + TextInput({ controller: this.controller, text: this.inputValue }) + .customKeyboard(this.CustomKeyboardBuilder()) + .margin(10) + .border({ width: 1 }) + .height('48vp') + .id('UIComponentEditAbleTextThreeReplacement0340_textInput_001') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0630.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0630.ets new file mode 100755 index 00000000..d6ac5e36 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0630.ets @@ -0,0 +1,62 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentEditAbleTextThreeReplacement0630 { + controller: TextAreaController = new TextAreaController(); + @State inputValue: string = ""; + + // 自定义键盘组件 + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + if (this.controller.getCaretOffset().index == 0) { + this.inputValue = item + this.inputValue; + } else { + this.inputValue += item; + } + }).id('button_0') + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Button('change point').onClick(() => { + this.controller.caretPosition(2); + }).id('UIComponentEditAbleTextThreeReplacement0630_button_001') + TextArea({ controller: this.controller, text: this.inputValue }) + .customKeyboard(this.CustomKeyboardBuilder()) + .margin(10) + .height(100) + .border({ width: 1 }) + .height('48vp') + .id('UIComponentEditAbleTextThreeReplacement0630_textInput_001') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0730.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0730.ets new file mode 100755 index 00000000..2cd0f060 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0730.ets @@ -0,0 +1,74 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentEditAbleTextThreeReplacement0730 { + controller: SearchController = new SearchController(); + @State inputValue: string = ""; + + // 自定义键盘组件 + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach(['A', 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + if (item == 'A') { + Button(item + "") + .width(110).onClick(() => { + if (this.controller.getCaretOffset().index == 0) { + this.inputValue = item + this.inputValue; + } else { + this.inputValue += item; + } + }).id('button_A') + } else { + Button(item + "") + .width(110).onClick(() => { + if (this.controller.getCaretOffset().index == 0) { + this.inputValue = item + this.inputValue; + } else { + this.inputValue += item; + } + }).id('button_0') + } + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Button('change point').onClick(() => { + this.controller.caretPosition(2); + }).id('UIComponentEditAbleTextThreeReplacement0730_button_001') + Search({ controller: this.controller, value: this.inputValue }) + .customKeyboard(this.CustomKeyboardBuilder()) + .margin(10) + .inputFilter('[A-Z]') + .height(100) + .border({ width: 1 }) + .height('48vp') + .id('UIComponentEditAbleTextThreeReplacement0730_textInput_001') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement1020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement1020.ets new file mode 100755 index 00000000..f507452c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement1020.ets @@ -0,0 +1,56 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentEditAbleTextThreeReplacement1020 { + controller: RichEditorController = new RichEditorController() + + // 自定义键盘组件 + @Builder CustomKeyboardBuilder() { + Column() { + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.controller.addTextSpan(item + '', { + offset: this.controller.getCaretOffset(), + style: + { + fontSize: 30 + } + }) + this.controller.setCaretOffset(this.controller.getCaretOffset() + item.toString().length) + }).id('button_0') + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + RichEditor({ controller: this.controller }) + .customKeyboard(this.CustomKeyboardBuilder()).margin(10).border({ width: 1 }) + .height(200) + .borderWidth(1) + .borderColor(Color.Red) + .width("100%") + .id('UIComponentEditAbleTextThreeReplacement1020_rich_001') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextCopyAttribute0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextCopyAttribute0010.ets new file mode 100755 index 00000000..c625a4de --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextCopyAttribute0010.ets @@ -0,0 +1,165 @@ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} + +@Entry +@Component +struct Test_Clipboard_With_Span_String { + @State imagePixelMap: image.PixelMap | undefined = undefined + @State msgList: Array = []; + @State permission_state: boolean = true; + mutableStr: MutableStyledString = new MutableStyledString(''); + controller: TextController = new TextController(); + controllerShow: TextController = new TextController(); + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + build() { + Scroll() { + Column({ space: 5 }) { + Divider() + Text("Text组件设置baselineoffset") + Text("带回家的好时范德萨加快福建考虑到撒开房间爱肯定是发动机考试垃圾分类扣三分手机端开发了健康的水立方") + .copyOption(CopyOptions.LocalDevice) + .draggable(true) + .fontSize(30)// .fontColor(Color.Green) + .heightAdaptivePolicy(30) + .focusable(true) + .textSelectable(TextSelectableMode.SELECTABLE_FOCUSABLE)// .fontFeature("\"ss01\" on") + .decoration({ type: TextDecorationType.LineThrough, color: Color.Red }) + + Divider() + Divider() + Row() { + Button("读取剪贴板内容") + .onClick(() => { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData(async (err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + for (let i = 0; i < pasteData.getRecordCount(); i++) { + let record = pasteData.getRecord(i); + if (record.data == undefined) { + continue; + } + // record.getData("openharmony.styled-string").then(async (value) => { + if (record.data instanceof ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(record.data); + this.msgList.push('剪贴板内容_转换:' + styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + // }); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + }) + Button("重置") + .onClick(() => { + let mutableShow = new MutableStyledString(''); + this.controllerShow.setStyledString(mutableShow) + this.msgList = []; + }) + } + + Divider() + Text(undefined, { controller: this.controllerShow }).copyOption(CopyOptions.LocalDevice) + Divider() + + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(20) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + } + .border({ width: 1, radius: 5 }) + .width('100%') + } + .height("90%") + .align(Alignment.Top) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize042.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize042.ets new file mode 100755 index 00000000..05ff35f8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize042.ets @@ -0,0 +1,38 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextMinFontSize042 { + build() { + Column() { + Column() { + TextArea({ text: 'ABC priorities.' }) + .minFontSize(10) + .maxFontSize(20) + .fontSize(16) + .margin({ bottom: 10 }) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .id('UIComponentTextMinFontSize042_textArea_001') + TextInput({ text: 'ABC priorities.' }) + .minFontSize(10) + .maxFontSize(30) + .fontSize(16) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .id('UIComponentTextMinFontSize042_textInput_001') + } + }.width('100%').height('100%').justifyContent(FlexAlign.Start) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize043.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize043.ets new file mode 100755 index 00000000..a0fa1ab8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize043.ets @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextMinFontSize043 { + controller: TextAreaController = new TextAreaController(); + + build() { + Column() { + Column() { + Button('set selection').onClick(() => { + this.controller.setTextSelection(0, 15); + }).margin({ bottom: 10 }).id('UIComponentTextMinFontSize043_button_001') + TextArea({ text: 'ABC priorities.', controller: this.controller }) + .minFontSize(10) + .maxFontSize(30) + .fontSize(16) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MIN_FONT_SIZE_FIRST) + .id('UIComponentTextMinFontSize043_textArea_001') + } + }.width('100%').height('100%').justifyContent(FlexAlign.Start) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize044.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize044.ets new file mode 100755 index 00000000..30d8a55e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize044.ets @@ -0,0 +1,40 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextMinFontSize044 { + build() { + Column() { + Column() { + TextArea({ text: 'ABC priorities.' }) + .minFontSize(10) + .maxFontSize(30) + .fontSize(16) + .margin({ bottom: 10 }) + .height(50) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST) + .id('UIComponentTextMinFontSize044_textArea_001') + TextInput({ text: 'ABC priorities.' }) + .minFontSize(10) + .maxFontSize(30) + .fontSize(16) + .height(50) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST) + .id('UIComponentTextMinFontSize044_textInput_001') + } + }.width('100%').height('100%').justifyContent(FlexAlign.Start) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize045.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize045.ets new file mode 100755 index 00000000..818e883f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize045.ets @@ -0,0 +1,40 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextMinFontSize045 { + build() { + Column() { + Column() { + TextArea({ text: 'ABC priorities.' }) + .minFontSize(10) + .maxFontSize(30) + .fontSize(16) + .margin({ bottom: 10 }) + .height(20) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST) + .id('UIComponentTextMinFontSize045_textArea_001') + TextInput({ text: 'ABC priorities.' }) + .minFontSize(10) + .maxFontSize(30) + .fontSize(16) + .height(20) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST) + .id('UIComponentTextMinFontSize045_textInput_001') + } + }.width('100%').height('100%').justifyContent(FlexAlign.Start) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize046.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize046.ets new file mode 100755 index 00000000..68056aba --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize046.ets @@ -0,0 +1,40 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextMinFontSize046 { + build() { + Column() { + Column() { + TextArea({ text: 'ABC priorities.' }) + .minFontSize(10) + .maxFontSize(30) + .fontSize(16) + .margin({ bottom: 10 }) + .height(5) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST) + .id('UIComponentTextMinFontSize046_textArea_001') + TextInput({ text: 'ABC priorities.' }) + .minFontSize(10) + .maxFontSize(30) + .fontSize(16) + .height(5) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST) + .id('UIComponentTextMinFontSize046_textInput_001') + } + }.width('100%').height('100%').justifyContent(FlexAlign.Start) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize047.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize047.ets new file mode 100755 index 00000000..edffc056 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize047.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextMinFontSize047 { + build() { + Column() { + Column() { + TextInput({ text: 'ABC priorities.' }) + .minFontSize(10) + .maxFontSize(30) + .fontSize(16) + .maxLines(2) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .id('UIComponentTextMinFontSize047_textInput_001') + } + }.width('100%').height('100%').justifyContent(FlexAlign.Start) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize048.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize048.ets new file mode 100755 index 00000000..145a33a4 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize048.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextMinFontSize048 { + build() { + Column() { + Column() { + TextArea({ text: 'ABC priorities.' }) + .minFontSize(10) + .maxFontSize(20) + .style(TextContentStyle.INLINE) + .fontSize(16) + .maxLines(2) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .id('UIComponentTextMinFontSize048_textArea_001') + } + }.width('100%').height('100%').justifyContent(FlexAlign.Start) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentReverseAnalysisInterface/UIComponentReverseAnalysisInterface001.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentReverseAnalysisInterface/UIComponentReverseAnalysisInterface001.ets new file mode 100644 index 00000000..fd42d35d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentReverseAnalysisInterface/UIComponentReverseAnalysisInterface001.ets @@ -0,0 +1,67 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentReverseAnalysisInterface001 { + @State text: string = 'This is the input text. Long press to display the selection.' + private scrollerForScroll: Scroller = new Scroller() + @State isScrollNext: boolean = false + + build() { + Stack({ alignContent: Alignment.TopStart }) { + Scroll(this.scrollerForScroll) { + Column() { + TextInput({ text: this.text }) + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .margin(15) + .fontColor(Color.Black) + .key('UIComponentReverseAnalysisInterface001_textInput_001') + + TextArea({ text: this.text }) + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .height(100) + .margin(15) + .fontColor(Color.Black) + .key('UIComponentReverseAnalysisInterface001_textArea_001') + + Search({ value: this.text }) + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .margin(15) + .fontColor(Color.Black) + .key('UIComponentReverseAnalysisInterface001_search_001') + + }.width('100%') + } + .height('30%') + .key('UIComponentReverseAnalysisInterface001_scroll_001') + + Button('Scroll Next Page') + .margin({ top: 260, left: 20 }) + .width('90%') + .height('5%') + .fontSize(12) + .onClick(() => { + this.isScrollNext = !this.isScrollNext + this.scrollerForScroll.scrollPage({ next: this.isScrollNext }) + }) + .key('UIComponentReverseAnalysisInterface001_button_001') + }.height('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentReverseAnalysisInterface/UIComponentReverseAnalysisInterface002.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentReverseAnalysisInterface/UIComponentReverseAnalysisInterface002.ets new file mode 100644 index 00000000..48a165c5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentReverseAnalysisInterface/UIComponentReverseAnalysisInterface002.ets @@ -0,0 +1,124 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Component +struct ColorAndBlur { + @State useColor1: boolean = true; + @State useBlur1: boolean = true; + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + NavDestination() { + Stack({ alignContent: Alignment.Center }) { + Column() { + Text().height('90%') + TextInput({ placeholder: 'this is placeholder text', controller: this.controller, text: this.inputValue }) + .width('100%') + .margin({ top: 15 }) + .customKeyboard(this.CustomKeyboardBuilder()) + .key('UIComponentReverseAnalysisInterface002_textInput_002') + } + .width('100%') + .height('100%') + }.width('100%') + .height('100%') + } + .width('100%') + .height('100%') + } +} + +@Entry +@Component +struct UIComponentReverseAnalysisInterface002 { + private stack: NavPathStack = new NavPathStack(); + @State useColor1: boolean = true; + @State useBlur1: boolean = true; + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + + @Builder + PageBuilder(name: string) { + ColorAndBlur() + } + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Navigation(this.stack) { + Stack({ alignContent: Alignment.Center }) { + Column() { + Stack({ alignContent: Alignment.Center }) { + Button("push page") + .onClick(() => { + this.stack.pushPath({ name: "page" }) + }) + } + .width('100%') + .layoutWeight(1) + .key('UIComponentReverseAnalysisInterface002_button_001') + + TextInput({ placeholder: 'this is placeholder text', controller: this.controller, text: this.inputValue }) + .width('100%') + .margin({ top: 15 }) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: true }) + .key('UIComponentReverseAnalysisInterface002_textInput_001') + } + }.width('100%') + .height('100%') + } + .width('100%') + .height('100%') + .navDestination(this.PageBuilder) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement0210.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement0210.ets new file mode 100755 index 00000000..06b2de2d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement0210.ets @@ -0,0 +1,49 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UIComponentSettextselectionReplacement0210 { + controller: SearchController = new SearchController(); + @State start : number =0; + @State end : number = 2; + + build() { + Column() { + Search({ + value: '12334423222342342353453245455646464333422343422342342342342343242342342342324234', + placeholder: 'Type to search...', + controller: this.controller + }) + .id('search') + .width('100%') + Button('ch1') + .id('ch1') + .onClick(()=>{ + this.controller.setTextSelection(1,2); + }) + Button('ch2') + .id('ch2') + .onClick(()=>{ + this.controller.setTextSelection(3,1); + }) + Button('ch3') + .id('ch3') + .onClick(()=>{ + this.controller.setTextSelection(-1,-1); + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement0220.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement0220.ets new file mode 100755 index 00000000..bc2dc7b3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement0220.ets @@ -0,0 +1,39 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UIComponentSettextselectionReplacement0220 { + controller: SearchController = new SearchController(); + + build() { + Column() { + Search({ + value: '12334423222342342353453245455646464333422343422342342342342343242342342342324234', + placeholder: 'Type to search...', + controller: this.controller + }) + .id('search') + .width('100%') + .gesture( + LongPressGesture({ duration: 450 }) + .tag('longPress1') + .onAction((event: GestureEvent) => { + this.controller.setTextSelection(0, 0, { menuPolicy: MenuPolicy.DEFAULT }); + }) + ) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface001.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface001.ets new file mode 100644 index 00000000..ea0876c7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface001.ets @@ -0,0 +1,40 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentTextAffineTransformationInterface001 { + @State message: string = '这是测试文本,this is test text'; + @State options: ScaleOptions = { x: 1, y: 1, z: 1 }; + + build() { + Row() { + Column() { + Text(this.message) + .fontSize(20) + .copyOption(CopyOptions.InApp) + .scale(this.options) + .key('UIComponentTextAffineTransformationInterface001_text_001') + Button('change scale').onClick(() => { + this.options = { x: 2, y: 0.5, z: 5 } + }).margin(80).key('UIComponentTextAffineTransformationInterface001_button_001') + + } + .width('100%') + .height('100%') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface0010.ets new file mode 100644 index 00000000..dfaaf568 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface0010.ets @@ -0,0 +1,86 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { matrix4 } from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextAffineTransformationInterface0010 { + @State text: string = '这是测试文本,this is test text'; + @State scaleOptions: ScaleOptions = { x: 1, y: 1, z: 1 }; + @State transOptions: TranslateOptions = { x: 0, y: 0, z: 0 }; + @State rotateOptions: RotateOptions = { + x: 0, + y: 0, + z: 0, + centerX: '0%', + centerY: '0%', + angle: 0 + }; + @State options: object = matrix4.identity() + .translate({ x: 1, y: 1 }) + .scale({ x: 1, y: 1 }) + .rotate({ + x: 1, + y: 1, + z: 1, + angle: 1 + }); + @State start: number = 0; + @State end: number = 2; + @State enable: boolean = false; + + build() { + Row() { + Column() { + Text(this.text) + .width(200) + .height(100) + .enableDataDetector(this.enable) + .copyOption(CopyOptions.InApp) + .scale(this.scaleOptions) + .translate(this.transOptions) + .rotate(this.rotateOptions) + .key('UIComponentTextAffineTransformationInterface0010_text_001') + Button('enableDataDetector').onClick(() => { + this.enable = true; + }).margin(80).key('UIComponentTextAffineTransformationInterface0010_button_001') + Button('change').onClick(() => { + this.scaleOptions = { x: -2, y: 0.5, z: -5 }; + this.transOptions = { x: 10, y: 100, z: 10 }; + this.rotateOptions = { + x: 0, + y: 1, + z: 0, + centerX: '0%', + centerY: '0%', + angle: 300 + }; + this.options = matrix4.identity() + .translate({ x: 50, y: 50 }) + .scale({ x: 1.5, y: 1 }) + .rotate({ + x: 0, + y: 0, + z: 1, + angle: 60 + }); + }).margin(80).key('UIComponentTextAffineTransformationInterface0010_button_002') + } + .width('100%') + .height('100%') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface002.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface002.ets new file mode 100644 index 00000000..d5f3d1ac --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface002.ets @@ -0,0 +1,46 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentTextAffineTransformationInterface002 { + @State message: string = '这是测试文本,this is test text'; + @State options: ScaleOptions = { x: 1, y: 1, z: 1 }; + + build() { + Row() { + Column() { + Text(this.message) + .fontSize(20) + .copyOption(CopyOptions.InApp) + .scale(this.options) + .key('UIComponentTextAffineTransformationInterface002_text_001') + Button('change scale').onClick(() => { + this.options = { + x: 2, + y: 0.5, + z: 5, + centerX: '0%', + centerY: '0%' + } + }).margin(80).key('UIComponentTextAffineTransformationInterface002_button_001') + + } + .width('100%') + .height('100%') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface003.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface003.ets new file mode 100644 index 00000000..cfba26ee --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface003.ets @@ -0,0 +1,46 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentTextAffineTransformationInterface003 { + @State text: string = '这是测试文本,this is test text'; + @State options: ScaleOptions = { x: 1, y: 1, z: 1 }; + + build() { + Row() { + Column() { + TextInput({ text: this.text }) + .fontSize(20) + .copyOption(CopyOptions.InApp) + .scale(this.options) + .key('UIComponentTextAffineTransformationInterface003_textInput_001') + Button('change scale').onClick(() => { + this.options = { + x: 2, + y: 0.5, + z: 5, + centerX: '0%', + centerY: '0%' + } + }).margin(80).key('UIComponentTextAffineTransformationInterface003_button_001') + + } + .width('100%') + .height('100%') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface004.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface004.ets new file mode 100644 index 00000000..0ef310ef --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface004.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentTextAffineTransformationInterface004 { + @State text: string = '这是测试文本,this is test text'; + @State options: TranslateOptions = { x: 1, y: 1, z: 1 }; + + build() { + Row() { + Column() { + Text(this.text) + .fontSize(20) + .copyOption(CopyOptions.InApp) + .translate(this.options) + .key('UIComponentTextAffineTransformationInterface004_text_001') + Button('change translate').onClick(() => { + this.options = { + x: 100, + y: 10 + } + }).margin(80).key('UIComponentTextAffineTransformationInterface004_button_001') + } + .width('100%') + .height('100%') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface005.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface005.ets new file mode 100644 index 00000000..221e93d6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface005.ets @@ -0,0 +1,56 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { matrix4 } from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextAffineTransformationInterface005 { + @State text: string = '这是测试文本,this is test text'; + @State options: object = matrix4.identity() + .translate({ x: 1, y: 1 }) + .scale({ x: 1, y: 1 }) + .rotate({ + x: 1, + y: 1, + z: 1, + angle: 1 + }); + + build() { + Row() { + Column() { + Text(this.text) + .fontSize(20) + .copyOption(CopyOptions.InApp) + .transform(this.options) + .key('UIComponentTextAffineTransformationInterface005_text_001') + Button('change scale').onClick(() => { + this.options = matrix4.identity() + .translate({ x: 50, y: 50 }) + .scale({ x: 1.5, y: 1 }) + .rotate({ + x: 0, + y: 0, + z: 1, + angle: 60 + }); + }).margin(80).key('UIComponentTextAffineTransformationInterface005_button_001') + } + .width('100%') + .height('100%') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface006.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface006.ets new file mode 100644 index 00000000..bf9f8225 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface006.ets @@ -0,0 +1,59 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentTextAffineTransformationInterface006 { + @State text: string = '这是测试文本,this is test text'; + @State scaleOptions: ScaleOptions = { x: 1, y: 1, z: 1 }; + @State transOptions: TranslateOptions = { x: 0, y: 0, z: 0 }; + @State rotateOptions: RotateOptions = { + x: 0, + y: 0, + z: 0, + centerX: '0%', + centerY: '0%', + angle: 0 + }; + + build() { + Row() { + Column() { + Text(this.text) + .fontSize(20) + .copyOption(CopyOptions.InApp) + .scale(this.scaleOptions) + .translate(this.transOptions) + .rotate(this.rotateOptions) + .key('UIComponentTextAffineTransformationInterface006_text_001') + Button('change').onClick(() => { + this.scaleOptions = { x: -2, y: 0.5, z: -5 }; + this.transOptions = { x: 10, y: 100, z: 10 }; + this.rotateOptions = { + x: 0, + y: 1, + z: 0, + centerX: '0%', + centerY: '0%', + angle: 300 + }; + }).margin(80).key('UIComponentTextAffineTransformationInterface006_button_001') + } + .width('100%') + .height('100%') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface007.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface007.ets new file mode 100644 index 00000000..987380e7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface007.ets @@ -0,0 +1,61 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentTextAffineTransformationInterface007 { + @State text: string = '这是测试文本,this is test text'; + @State scaleOptions: ScaleOptions = { x: 1, y: 1, z: 1 }; + @State transOptions: TranslateOptions = { x: 0, y: 0, z: 0 }; + @State rotateOptions: RotateOptions = { + x: 0, + y: 0, + z: 0, + centerX: '0%', + centerY: '0%', + angle: 0 + }; + + build() { + Row() { + Column() { + TextInput({ text: this.text }) + .fontSize(20) + .width(200) + .height(100) + .copyOption(CopyOptions.InApp) + .scale(this.scaleOptions) + .translate(this.transOptions) + .rotate(this.rotateOptions) + .key('UIComponentTextAffineTransformationInterface007_textInput_001') + Button('change').onClick(() => { + this.scaleOptions = { x: -2, y: 0.5, z: -5 }; + this.transOptions = { x: 10, y: 100, z: 10 }; + this.rotateOptions = { + x: 0, + y: 1, + z: 0, + centerX: '0%', + centerY: '0%', + angle: 300 + }; + }).margin(80).key('UIComponentTextAffineTransformationInterface007_button_001') + } + .width('100%') + .height('100%') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface008.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface008.ets new file mode 100644 index 00000000..c52fabef --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface008.ets @@ -0,0 +1,67 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentTextAffineTransformationInterface008 { + @State text: string = '这是测试文本,this is test text'; + @State scaleOptions: ScaleOptions = { x: 1, y: 1, z: 1 }; + @State transOptions: TranslateOptions = { x: 0, y: 0, z: 0 }; + @State rotateOptions: RotateOptions = { + x: 0, + y: 0, + z: 0, + centerX: '0%', + centerY: '0%', + angle: 0 + }; + @State start: number = 0; + @State end: number = 2; + + build() { + Row() { + Column() { + Text(this.text) + .width(300) + .height(100) + .copyOption(CopyOptions.InApp) + .scale(this.scaleOptions) + .selection(this.start, this.end) + .translate(this.transOptions) + .rotate(this.rotateOptions) + .key('UIComponentTextAffineTransformationInterface008_text_001') + Button('setSelectionText').onClick(() => { + this.start = 2; + this.end = 5; + }).key('UIComponentTextAffineTransformationInterface008_button_001') + Button('change').onClick(() => { + this.scaleOptions = { x: -2, y: 0.5, z: -5 }; + this.transOptions = { x: 10, y: 100, z: 10 }; + this.rotateOptions = { + x: 0, + y: 1, + z: 0, + centerX: '0%', + centerY: '0%', + angle: 300 + }; + }).margin(80).key('UIComponentTextAffineTransformationInterface008_button_002') + } + .width('100%') + .height('100%') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface009.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface009.ets new file mode 100644 index 00000000..eb815c3e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface009.ets @@ -0,0 +1,66 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentTextAffineTransformationInterface009 { + @State text: string = '这是测试文本,this is test text'; + @State scaleOptions: ScaleOptions = { x: 1, y: 1, z: 1 }; + @State transOptions: TranslateOptions = { x: 0, y: 0, z: 0 }; + @State rotateOptions: RotateOptions = { + x: 0, + y: 0, + z: 0, + centerX: '0%', + centerY: '0%', + angle: 0 + }; + @State start: number = 0; + @State end: number = 2; + controller = new TextInputController(); + + build() { + Row() { + Column() { + TextInput({ text: this.text, controller: this.controller }) + .width(200) + .height(100) + .copyOption(CopyOptions.InApp) + .scale(this.scaleOptions) + .translate(this.transOptions) + .rotate(this.rotateOptions) + .key('UIComponentTextAffineTransformationInterface009_textInput_001') + Button('setSelectionText').onClick(() => { + this.controller.setTextSelection(0,5); + }).key('UIComponentTextAffineTransformationInterface009_button_001') + Button('change').onClick(() => { + this.scaleOptions = { x: -2, y: 0.5, z: -5 }; + this.transOptions = { x: 10, y: 100, z: 10 }; + this.rotateOptions = { + x: 0, + y: 1, + z: 0, + centerX: '0%', + centerY: '0%', + angle: 300 + }; + }).margin(80).key('UIComponentTextAffineTransformationInterface009_button_002') + } + .width('100%') + .height('100%') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface001.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface001.ets new file mode 100644 index 00000000..ff05115e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface001.ets @@ -0,0 +1,117 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { it } from '@ohos/hypium' + + +class MyDataSource implements IDataSource { + private list: number[] = [] + + constructor(list: number[]) { + this.list = list + } + + totalCount(): number { + return this.list.length + } + + getData(index: number): number { + return this.list[index] + } + + registerDataChangeListener(listener: DataChangeListener): void { + } + + unregisterDataChangeListener() { + } +} + +@Entry +@Component +struct UIComponentTextCommonHandleInterface001 { + private swiperController: SwiperController = new SwiperController() + private data: MyDataSource = new MyDataSource([]) + @State text: string = 'this is test text'; + @State textInput: string = 'this is test text - textInput'; + @State textArea: string = 'this is test text - textInput'; + @State autoPlayer: boolean = false; + + aboutToAppear(): void { + let list: number[] = [] + for (let i = 1; i <= 3; i++) { + list.push(i); + } + this.data = new MyDataSource(list) + } + + build() { + Column({ space: 5 }) { + Swiper(this.swiperController) { + LazyForEach(this.data, (item: number) => { + if (item == 1) { + Text(this.text) + .copyOption(CopyOptions.InApp) + .height(160) + .textAlign(TextAlign.Center) + .key('UIComponentTextCommonHandleInterface001_text_001') + } else if (item == 2) { + TextInput({ text: this.textInput }) + .copyOption(CopyOptions.InApp) + .height(160) + .textAlign(TextAlign.Center) + .key('UIComponentTextCommonHandleInterface001_textInput_001') + } else if (item == 3) { + TextArea({ text: this.textArea }) + .width('90%') + .copyOption(CopyOptions.InApp) + .height(160) + .textAlign(TextAlign.Center) + .key('UIComponentTextCommonHandleInterface001_textArea_001') + } + }, (item: string) => item) + } + .cachedCount(2) + .vertical(false) + .index(0) + .autoPlay(this.autoPlayer) + .interval(4000) + .indicator(Indicator.digit() + .top(200) + .fontColor(Color.Gray) + .selectedFontColor(Color.Gray) + .digitFont({ size: 20, weight: FontWeight.Bold }) + .selectedDigitFont({ size: 20, weight: FontWeight.Normal })) + .loop(true) + .duration(4000) + .itemSpace(0) + .displayArrow(true, false) + + Row({ space: 12 }) { + Button('autoPlayer') + .onClick(() => { + this.autoPlayer = true; + }).key('UIComponentTextCommonHandleInterface001_button_001') + // Button('showNext') + // .onClick(() => { + // this.swiperController.showNext() + // }) + // Button('showPrevious') + // .onClick(() => { + // this.swiperController.showPrevious() + // }) + }.margin(5) + }.width('100%') + .margin({ top: 5 }) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface0010.ets new file mode 100644 index 00000000..5be5f929 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface0010.ets @@ -0,0 +1,96 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextCommonHandleInterface0010 { + @State numbers: number[] = []; + @State layoutDirection: number = GridDirection.Row; + scroller = new Scroller(); + @State isNext: boolean = false; + + aboutToAppear() { + for (let i = 0; i <= 3; i++) { + this.numbers.push(i); + } + } + + build() { + Column() { + Text('设置layoutDirection = GridDirection.Row') + .fontSize(15).fontColor(0xCCCCCC).width('90%') + Scroll(this.scroller) { + Column({ space: 5 }) { + Blank() + Grid() { + ForEach(this.numbers, (index: number) => { + GridItem() { + if (index == 0) { + TextInput({ text: '这是第' + 1 + '个textInput' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(100) + .fontSize(16) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface0010_textInput_001') + } else if (index == 1) { + Search({ value: '这是第' + 2 + '个search' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(100) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface0010_search_001') + } else if (index == 2) { + TextArea({ text: '这是第' + 3 + '个textInput' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(100) + .fontSize(16) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface0010_textArea_001') + } + }.borderWidth(2).borderColor(Color.Red) + }) + } + .height(400) + .columnsGap(10) + .rowsGap(10) + .backgroundColor(0xFAEEE0) + .maxCount(2) + .minCount(1) + .cellLength(0) + .layoutDirection(this.layoutDirection) + } + .width('90%').margin({ top: 5, left: 5, right: 5 }) + .align(Alignment.Center) + }.height(200) + + Button('Next page').onClick(() => { + this.isNext = !this.isNext; + this.scroller.scrollPage({ next: this.isNext }); + }).margin({ top: 20 }).key('UIComponentTextCommonHandleInterface0010_button_001') + + Button('change layoutDirection to Column').onClick(() => { + this.layoutDirection = GridDirection.Column; + }).margin({ top: 20 }).key('UIComponentTextCommonHandleInterface0010_button_002') + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface002.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface002.ets new file mode 100644 index 00000000..0192722c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface002.ets @@ -0,0 +1,119 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { it } from '@ohos/hypium' + + +class MyDataSource implements IDataSource { + private list: number[] = [] + + constructor(list: number[]) { + this.list = list + } + + totalCount(): number { + return this.list.length + } + + getData(index: number): number { + return this.list[index] + } + + registerDataChangeListener(listener: DataChangeListener): void { + } + + unregisterDataChangeListener() { + } +} + +@Entry +@Component +struct UIComponentTextCommonHandleInterface002 { + private swiperController: SwiperController = new SwiperController() + private data: MyDataSource = new MyDataSource([]) + @State text: string = 'this is test text'; + @State textInput: string = 'this is test text - textInput'; + @State textArea: string = 'this is test text - textInput'; + @State autoPlayer: boolean = false; + + aboutToAppear(): void { + let list: number[] = [] + for (let i = 1; i <= 3; i++) { + list.push(i); + } + this.data = new MyDataSource(list) + } + + build() { + Column({ space: 5 }) { + Swiper(this.swiperController) { + LazyForEach(this.data, (item: number) => { + if (item == 1) { + Text(this.text) + .width('90%') + .copyOption(CopyOptions.InApp) + .height(160) + .textAlign(TextAlign.Center) + .key('UIComponentTextCommonHandleInterface002_text_001') + } else if (item == 2) { + TextInput({ text: this.textInput }) + .width('90%') + .copyOption(CopyOptions.InApp) + .height(160) + .textAlign(TextAlign.Center) + .key('UIComponentTextCommonHandleInterface002_textInput_001') + } else if (item == 3) { + TextArea({ text: this.textArea }) + .width('90%') + .copyOption(CopyOptions.InApp) + .height(160) + .textAlign(TextAlign.Center) + .key('UIComponentTextCommonHandleInterface002_textArea_001') + } + }, (item: string) => item) + } + .cachedCount(2) + .vertical(true) + .index(0) + .autoPlay(this.autoPlayer) + .interval(4000) + .indicator(Indicator.digit() + .top(200) + .fontColor(Color.Gray) + .selectedFontColor(Color.Gray) + .digitFont({ size: 20, weight: FontWeight.Bold }) + .selectedDigitFont({ size: 20, weight: FontWeight.Normal })) + .loop(true) + .duration(1000) + .itemSpace(0) + .displayArrow(true, false) + + Row({ space: 12 }) { + Button('autoPlayer') + .onClick(() => { + this.autoPlayer = true; + }).key('UIComponentTextCommonHandleInterface002_button_001') + // Button('showNext') + // .onClick(() => { + // this.swiperController.showNext() + // }) + // Button('showPrevious') + // .onClick(() => { + // this.swiperController.showPrevious() + // }) + }.margin(5) + }.width('100%') + .margin({ top: 5 }) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface003.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface003.ets new file mode 100644 index 00000000..23e4c5f9 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface003.ets @@ -0,0 +1,97 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextCommonHandleInterface003 { + private arr: number[] = [0, 1, 2, 3, 4] + + build() { + Column() { + List({ space: 20, initialIndex: 0 }) { + ForEach(this.arr, (item: number) => { + ListItem() { + if (item == 0) { + TextInput({ text: '这是第' + item + '个textInput' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .fontSize(16) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface003_textInput_001') + } else if (item == 1) { + TextArea({ text: '这是第' + item + '个textArea' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .fontSize(16) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface003_textArea_001') + } else if (item == 2) { + Search({ value: '这是第' + item + '个Search' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface003_search_001') + } else { + Text('这是第' + item) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .fontSize(16) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface003_text_001') + } + + } + }, (item: string) => item) + } + .listDirection(Axis.Vertical) // Arrangement direction + .scrollBar(BarState.Off) + .friction(0.6) + .divider({ + strokeWidth: 2, + color: 0xFFFFFF, + startMargin: 20, + endMargin: 20 + }) // Divider + .edgeEffect(EdgeEffect.Spring) // Set the edge scrolling effect to Spring. + .onScrollIndex((firstIndex: number, lastIndex: number, centerIndex: number) => { + console.info('first' + firstIndex) + console.info('last' + lastIndex) + console.info('center' + centerIndex) + }) + .onScrollVisibleContentChange((start: VisibleListContentInfo, end: VisibleListContentInfo) => { + }) + .onDidScroll((scrollOffset: number, scrollState: ScrollState) => { + }) + .width('90%') + } + .width('100%') + .height('100%') + .backgroundColor(0xDCDCDC) + .padding({ top: 5 }) + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface004.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface004.ets new file mode 100644 index 00000000..f6ec459c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface004.ets @@ -0,0 +1,102 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextCommonHandleInterface004 { + scroller = new Scroller(); + private arr: number[] = [0, 1, 2, 3]; + @State isNext: boolean = false; + + build() { + Column() { + List({ space: 20, initialIndex: 0, scroller: this.scroller }) { + ForEach(this.arr, (item: number) => { + ListItem() { + if (item == 0) { + TextInput({ text: '这是第' + item + '个textInput' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .fontSize(16) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface004_textInput_001') + } else if (item == 1) { + TextArea({ text: '这是第' + item + '个textArea' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .fontSize(16) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface004_textArea_001') + } else if (item == 2) { + Search({ value: '这是第' + item + '个Search' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface004_search_001') + } else { + Text('这是第' + item) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .fontSize(16) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface004_text_001') + } + + } + }, (item: string) => item) + } + .listDirection(Axis.Horizontal) // Arrangement direction + .scrollBar(BarState.On) + .divider({ + strokeWidth: 2, + color: 0xFFFFFF, + startMargin: 20, + endMargin: 20 + }) // Divider + .edgeEffect(EdgeEffect.Spring) // Set the edge scrolling effect to Spring. + .onScrollIndex((firstIndex: number, lastIndex: number, centerIndex: number) => { + console.info('first' + firstIndex) + console.info('last' + lastIndex) + console.info('center' + centerIndex) + }) + .onScrollVisibleContentChange((start: VisibleListContentInfo, end: VisibleListContentInfo) => { + }) + .onDidScroll((scrollOffset: number, scrollState: ScrollState) => { + }) + .width('90%') + .height(300) + + Button('Next page').onClick(() => { + this.scroller.scrollPage({ next: !this.isNext }) + }).key('UIComponentTextCommonHandleInterface004_button_001') + } + .width('100%') + .backgroundColor(0xDCDCDC) + .padding({ top: 5 }) + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface005.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface005.ets new file mode 100644 index 00000000..149d3d9f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface005.ets @@ -0,0 +1,103 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextCommonHandleInterface005 { + @State minSize: number = 80 + @State maxSize: number = 180 + @State fontSize: number = 24 + scroller: Scroller = new Scroller() + private itemWidthArray: number[] = [] + private itemHeightArray: number[] = [] + private arr: number[] = [0, 1, 2, 3, 4, 5, 6, 7]; + private arrColor: number[] = [0, 1, 2, Color.Brown, Color.Pink, Color.Gray, Color.Orange, Color.Yellow]; + + + build() { + Column({ space: 2 }) { + WaterFlow() { + ForEach(this.arr, (item: number) => { + FlowItem() { + Column() { + if (item == 0) { + TextInput({ text: '这是第' + item + '个textInput' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(50) + .fontSize(16) + .textAlign(TextAlign.Start) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface005_textInput_001') + } else if (item == 1) { + TextArea({ text: '这是第' + item + '个TextArea' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(50) + .fontSize(16) + .textAlign(TextAlign.Start) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface005_textInput_001') + } else if (item == 2) { + Column() { + Search({ value: '这是第' + item + '个Search' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(50) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface005_textInput_001') + } + .justifyContent(FlexAlign.Center) + .height('100%') + .width('100%') + } else { + Column() + .backgroundColor(this.arrColor[item]) + .height('100%') + .width('100%') + } + } + } + .onAppear(() => { + }) + .width('100%') + .height(this.itemHeightArray[item % 100]) + }, (item: string) => item) + } + .layoutDirection(FlexDirection.Column) + .columnsTemplate("1fr 1fr") + .columnsGap(10) + .rowsGap(5) + .backgroundColor(0xFAEEE0) + .width('100%') + .height('50%') + .onReachStart(() => { + console.info('waterFlow reach start') + }) + .onScrollStart(() => { + console.info('waterFlow scroll start') + }) + .onScrollStop(() => { + console.info('waterFlow scroll stop') + }) + .onScrollFrameBegin((offset: number, state: ScrollState) => { + console.info('waterFlow scrollFrameBegin offset: ' + offset + ' state: ' + state.toString()) + return { offsetRemain: offset } + }) + } + } +} + + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface006.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface006.ets new file mode 100644 index 00000000..659c0cc5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface006.ets @@ -0,0 +1,132 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextCommonHandleInterface006 { + @State minSize: number = 80; + @State maxSize: number = 180; + @State fontSize: number = 24; + scroller: Scroller = new Scroller(); + private itemHeightArray: number[] = []; + private arr: number[] = [0, 1, 2, 3, 4, 5, 6, 7]; + private arrColor: number[] = [0, 1, 2, Color.Brown, Color.Pink, Color.Gray, Color.Orange, Color.Yellow]; + @State isNext: boolean = false; + scroll = new Scroller(); + + // // 计算FlowItem宽/高 + // getSize() { + // let ret = Math.floor(Math.random() * this.maxSize) + // return (ret > this.minSize ? ret : this.minSize) + // } + // + // // 设置FlowItem的宽/高数组 + // setItemSizeArray() { + // for (let i = 0; i < 100; i++) { + // this.itemWidthArray.push(this.getSize()) + // this.itemHeightArray.push(this.getSize()) + // } + // } + + // aboutToAppear() { + // this.setItemSizeArray() + // } + + build() { + Column() { + WaterFlow({ scroller: this.scroll }) { + ForEach(this.arr, (item: number) => { + FlowItem() { + Row() { + if (item == 0) { + TextInput({ text: '这是第' + item + '个textInput' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(100) + .fontSize(16) + .textAlign(TextAlign.Start) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface006_textInput_001') + } else if (item == 1) { + TextArea({ text: '这是第' + item + '个TextArea' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(100) + .fontSize(16) + .textAlign(TextAlign.Start) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface006_textInput_001') + } else if (item == 2) { + Column() { + Search({ value: '这是第' + item + '个Search' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(100) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface006_textInput_001') + } + .justifyContent(FlexAlign.Center) + .height('100%') + .width('100%') + + } else { + Column() + .backgroundColor(this.arrColor[item]) + .height('100%') + .width('100%') + // Text("N" + item).fontSize(12).height('16') + // Image($r('app.media.icon')) + // .objectFit(ImageFit.Fill) + // .width('100%') + // .layoutWeight(1) + } + } + } + .onAppear(() => { + }) + .width('100%') + .height(this.itemHeightArray[item % 100]) + }, (item: string) => item) + } + .layoutDirection(FlexDirection.Row) + .columnsTemplate("1fr 1fr") + .columnsGap(10) + .rowsGap(5) + .backgroundColor(0xFAEEE0) + .width('100%') + .height('100%') + .onReachStart(() => { + console.info('waterFlow reach start') + }) + .onScrollStart(() => { + console.info('waterFlow scroll start') + }) + .onScrollStop(() => { + console.info('waterFlow scroll stop') + }) + .onScrollFrameBegin((offset: number, state: ScrollState) => { + console.info('waterFlow scrollFrameBegin offset: ' + offset + ' state: ' + state.toString()) + return { offsetRemain: offset } + }) + + // + // Button('next page').onClick(() => { + // this.scroller.scrollPage({ next: true }) + // }) + } + } +} + + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface007.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface007.ets new file mode 100644 index 00000000..4207156b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface007.ets @@ -0,0 +1,72 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextCommonHandleInterface007 { + scroller = new Scroller(); + private arr: number[] = [0, 1, 2, 3]; + @State isNext: boolean = false; + + build() { + Column() { + Scroll(this.scroller) { + Column() { + TextInput({ text: '这是第' + 1 + '个textInput' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .fontSize(16) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface007_textInput_001') + Search({ value: '这是第' + 2 + '个search' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface007_search_001') + TextArea({ text: '这是第' + 3 + '个textInput' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .fontSize(16) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface007_textArea_001') + } + } + .scrollable(ScrollDirection.Vertical) + .scrollBar(BarState.On) + .edgeEffect(EdgeEffect.Spring) // Set the edge scrolling effect to Spring. + .onDidScroll((scrollOffset: number, scrollState: ScrollState) => { + }) + .width('90%') + .height(300) + + // Button('Next page').onClick(() => { + // this.scroller.scrollPage({ next: !this.isNext }) + // }).key('UIComponentTextCommonHandleInterface007_button_001') + } + .width('100%') + .backgroundColor(0xDCDCDC) + .padding({ top: 5 }) + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface008.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface008.ets new file mode 100644 index 00000000..3312afe8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface008.ets @@ -0,0 +1,72 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextCommonHandleInterface008 { + scroller = new Scroller(); + private arr: number[] = [0, 1, 2, 3]; + @State isNext: boolean = false; + + build() { + Column() { + Scroll(this.scroller) { + Row() { + TextInput({ text: '这是第' + 1 + '个textInput' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .fontSize(16) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface008_textInput_001') + Search({ value: '这是第' + 2 + '个search' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface008_search_001') + TextArea({ text: '这是第' + 3 + '个textInput' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .fontSize(16) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface008_textArea_001') + } + } + .scrollable(ScrollDirection.Horizontal) + .scrollBar(BarState.On) + .edgeEffect(EdgeEffect.Spring) // Set the edge scrolling effect to Spring. + .onDidScroll((scrollOffset: number, scrollState: ScrollState) => { + }) + .width('90%') + .height(300) + + Button('Next page').onClick(() => { + this.scroller.scrollPage({ next: !this.isNext }) + }).key('UIComponentTextCommonHandleInterface008_button_001') + } + .width('100%') + .backgroundColor(0xDCDCDC) + .padding({ top: 5 }) + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface009.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface009.ets new file mode 100644 index 00000000..289e02b5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface009.ets @@ -0,0 +1,51 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextCommonHandleInterface009 { + build() { + Column() { + TextInput({ text: '这是第' + 1 + '个textInput' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .fontSize(16) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFF88) + .key('UIComponentTextCommonHandleInterface009_textInput_001') + Search({ value: '这是第' + 2 + '个search' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface009_search_001') + TextArea({ text: '这是第' + 3 + '个textArea' }) + .copyOption(CopyOptions.InApp) + .width('100%') + .height(200) + .fontSize(16) + .textAlign(TextAlign.Center) + .borderRadius(10) + .backgroundColor(0xFFFFFF) + .key('UIComponentTextCommonHandleInterface009_textArea_001') + } + + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010.ets new file mode 100644 index 00000000..de59aeb6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010.ets @@ -0,0 +1,154 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextCommonSelectionState0010 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'Text:' + this.msg + @State taTxt: string = 'TextArea:' + this.msg + @State tiTxt: string = 'TextInput:' + this.msg + @State changeValue: string = 'search:' + this.msg + @State richEdTxt: string = 'RichEditor:' + this.msg + @State submitValue: string = '' + searchController: SearchController = new SearchController(); + textAreaController: TextAreaController = new TextAreaController() + textInputController: TextInputController = new TextInputController() + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + private editorMenuOptions: Array = + [{ icon: 'icon.png' }, { icon: 'cat.jpg' }, { icon: 'openeye.png' }, { icon: 'icon.png' }, { icon: 'openeye.png' }, + { icon: 'cat.jpg' }] + private expandedMenuOptions: Array = + [{ + startIcon: 'cat.jpg', content: '词典', action: () => { + console.log('click it>>'); + this.options.controller.closeSelectionMenu(); + } + }, { + startIcon: 'icon.png', content: '翻译', action: () => { + } + }, { + startIcon: 'openeye.png', content: '搜索', action: () => { + } + }] + private selectionMenuOptions: SelectionMenuOptions = { + editorMenuOptions: this.editorMenuOptions, + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + + build() { + Column() { + Text(this.txt) + .id('textCommonSelectionState0010_tx') + .width('100%') + .margin(20) + .height('10%') + .fontSize(16) + .copyOption(CopyOptions.InApp) + .fontColor('#182431') + + TextArea({ + text: this.taTxt, + placeholder: 'The text area can hold an unlimited amount of text. input your word...', + controller: this.textAreaController + }) + .id('textCommonSelectionState0010_txArea') + .width('90%') + .margin(10) + .height('20%') + .fontSize(20) + .fontColor('#182431') + .backgroundColor('#FFFFFF') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + + TextInput({ + text: this.tiTxt, + controller: this.textInputController + }) + .id('textCommonSelectionState0010_txInput') + .margin(10) + .fontColor(Color.Blue) + .fontSize(20) + .width('100%') + .height('20%') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + Search({ + value: this.changeValue, + placeholder: 'Type to search...', + controller: this.searchController + }) + .id('textCommonSelectionState0010_search') + .searchButton('SEARCH') + .width('100%') + .height(50) + .backgroundColor('#F5F5F5') + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .textFont({ size: 14, weight: 400 }) + .margin(20) + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log('onTextSelectionChange>>'); + }) + + RichEditor(this.options) + .id('textCommonSelectionState0010_richEd') + .onReady(() => { + this.controller.addTextSpan(this.richEdTxt, { style: { fontColor: Color.Orange, fontSize: 18 } }); + }) + .onSelect((value: RichEditorSelection) => { + console.log('onSelect >>>'); + }) + .bindSelectionMenu(RichEditorSpanType.TEXT, this.MyMenu(), RichEditorResponseType.LONG_PRESS) + .borderWidth(1) + .borderColor(Color.Red) + .width('100%') + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0190.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0190.ets new file mode 100644 index 00000000..ede0489c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0190.ets @@ -0,0 +1,59 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextCommonSelectionState0190 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'Text:' + this.msg + controller: TextController = new TextController(); + @State startNum: number = 0; + @State endNum: number = 0; + + build() { + Column() { + Text(this.txt) + .id('textCommonSelectionState0190_tx') + .width('100%') + .margin(20) + .height('10%') + .fontSize(16) + .copyOption(CopyOptions.InApp) + .fontColor('#182431') + .selection(this.startNum, this.endNum) + .onTextSelectionChange((selectionStart, selectionEnd) => { + console.log(`Text{select:[${selectionStart},${selectionEnd}]}`); + }) + + Button('SelectOpt') + .id('textCommonSelectionState0190_btn') + .onClick(() => { + this.startNum = 10; + this.endNum = this.txt.length - 10; + }) + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0200.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0200.ets new file mode 100644 index 00000000..f4f724df --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0200.ets @@ -0,0 +1,197 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextCommonSelectionState0200 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目" + @State txt: string = 'Text:' + this.msg + @State taTxt: string = 'TextArea:' + this.msg + @State tiTxt: string = 'TextInput:' + this.msg + @State changeValue: string = 'search:' + this.msg + @State richEdTxt: string = 'RichEditor:' + this.msg + @State submitValue: string = '' + searchController: SearchController = new SearchController(); + textAreaController: TextAreaController = new TextAreaController() + textInputController: TextInputController = new TextInputController() + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + private editorMenuOptions: Array = + [{ icon: 'icon.png' }, { icon: 'cat.jpg' }, { icon: 'openeye.png' }, { icon: 'icon.png' }, { icon: 'openeye.png' }, + { icon: 'cat.jpg' }] + private expandedMenuOptions: Array = + [{ + startIcon: 'cat.jpg', content: '词典', action: () => { + console.log('click it>>'); + this.options.controller.closeSelectionMenu(); + } + }, { + startIcon: 'icon.png', content: '翻译', action: () => { + } + }, { + startIcon: 'openeye.png', content: '搜索', action: () => { + } + }] + private selectionMenuOptions: SelectionMenuOptions = { + editorMenuOptions: this.editorMenuOptions, + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + @State curType: number = MenuPolicy.DEFAULT; + @State nextType: number = MenuPolicy.DEFAULT; + @State curTypeStr: string = 'MenuPolicy.DEFAULT' + @State curTypeMsg: string = this.curTypeStr + '\n' + this.curTypeStr + @State testRes: string = '' + @State btnEnable: boolean = true + @State selectionOptions: SelectionOptions = { + menuPolicy: this.curType + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + + build() { + Column() { + TextArea({ + text: this.curTypeMsg, + placeholder: 'The text area can hold an unlimited amount of text. input your word...', + controller: this.textAreaController + }) + .id('textCommonSelectionState0200_txArea') + .width('90%') + .margin(10) + .height(20) + .fontSize(16) + .fontColor('#182431') + .backgroundColor('#FFFFFF') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>> TextArea{point:[${selectionStart},${selectionEnd}]}`); + }) + + TextInput({ + text: this.tiTxt, + controller: this.textInputController + }) + .id('textCommonSelectionState0200_txInput') + .margin(10) + .fontColor(Color.Blue) + .fontSize(20) + .width('100%') + .height('20%') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + + Row() { + Button('Option') + .id('textCommonSelectionState0200_opBtn') + .enabled(this.btnEnable) + .onClick(() => { + console.log(`onClick>>> curTypeStr=${this.curTypeStr}`); + this.selectionOptions = { menuPolicy: MenuPolicy.SHOW } + switch (this.nextType) { + case MenuPolicy.DEFAULT: + this.curType = MenuPolicy.DEFAULT; + this.curTypeStr = 'MenuPolicy.DEFAULT'; + this.nextType = MenuPolicy.SHOW; + this.selectionOptions = { menuPolicy: MenuPolicy.DEFAULT } + break; + case MenuPolicy.SHOW: + this.curType = MenuPolicy.SHOW; + this.curTypeStr = 'MenuPolicy.SHOW'; + this.nextType = MenuPolicy.HIDE; + this.selectionOptions = { menuPolicy: MenuPolicy.SHOW } + break; + case MenuPolicy.HIDE: + this.curType = MenuPolicy.HIDE; + this.curTypeStr = 'MenuPolicy.HIDE'; + this.nextType = -1; + this.selectionOptions = { menuPolicy: MenuPolicy.HIDE } + this.btnEnable = false; + break; + } + console.log(`after onClick>>> curTypeStr=${this.curTypeStr}`); + }) + .width('40%') + .margin(10) + + Button('SelectOpt') + .id('textCommonSelectionState0200_selectBtn') + .onClick(() => { + this.textInputController + .setTextSelection(10, 30, this.selectionOptions); + }) + .width('40%') + .margin(10) + } + + Search({ + value: this.changeValue, + placeholder: 'Type to search...', + controller: this.searchController + }) + .id('textCommonSelectionState0200_search') + .searchButton('SEARCH') + .width('100%') + .height(50) + .backgroundColor('#F5F5F5') + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .textFont({ size: 14, weight: 400 }) + .margin(20) + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log('onTextSelectionChange>>'); + }) + + RichEditor(this.options) + .id('textCommonSelectionState0200_richEd') + .onReady(() => { + this.controller.addTextSpan(this.richEdTxt, { style: { fontColor: Color.Orange, fontSize: 18 } }); + }) + .onSelect((value: RichEditorSelection) => { + console.log('onSelect >>>'); + }) + .bindSelectionMenu(RichEditorSpanType.TEXT, this.MyMenu(), RichEditorResponseType.LONG_PRESS) + .borderWidth(1) + .borderColor(Color.Red) + .width('100%') + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0210.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0210.ets new file mode 100644 index 00000000..f420f680 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0210.ets @@ -0,0 +1,40 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UIComponentTextCommonSelectionState0210 { + controller = new TextInputController(); + @State isVisible: number = Visibility.Visible; + + build() { + Column() { + TextInput({ + text: 'this is test text -- TextInput 测试SelectOptions', controller: this.controller + }).margin(10).key('UIComponentTextCommonSelectionState0210_textInput') + + Button('set MenuPolicy = HIDE').onClick(() => { + let policy = MenuPolicy.HIDE; + this.isVisible = Visibility.Hidden; + this.controller.setTextSelection(1, 8, { menuPolicy: policy }) + }).visibility(this.isVisible).key('UIComponentTextCommonSelectionState0210_none') + Button('set MenuPolicy = SHOW').onClick(() => { + let policy = MenuPolicy.SHOW; + this.isVisible = Visibility.Hidden; + this.controller.setTextSelection(1, 8, { menuPolicy: policy }) + }).visibility(this.isVisible).margin({ top: 10 }).key('UIComponentTextCommonSelectionState0210_always') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_1.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_1.ets new file mode 100644 index 00000000..b38c0db2 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_1.ets @@ -0,0 +1,122 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import Settings from '../../../test/model/Settings' + +import Window from '@ohos.window' +import common from '@ohos.app.ability.common'; +import { BusinessError } from '@kit.BasicServicesKit'; + +@Entry +@Component +struct UIComponentTextCommonSelectionState0230_1 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'TextArea/TextInput/Search,' + this.msg + @State tiTxt: string = 'TextInput:' + this.msg + @State tiSelectRes: string = '' + @State tiScrollRes: string = '' + textInputController: TextInputController = new TextInputController() + @State nextType: number = InputType.Normal; + nextTypeStr: string = 'InputType.Number' + curTypeStr: string = 'InputType.Normal' + curTypeMsg: string = 'TextInputyuiewfi769\n%……&*(&))*(&*\n#$%^&YVJHG*HNT16545132' + // @State testRes: string = + // 'current InputType is:{' + this.curTypeStr + ',next InputType is' + this.nextTypeStr + '}\n'; + @State testRes: string = '' + @State btnEnable: boolean = true + + build() { + Column() { + TextInput({ + text: this.curTypeMsg, + placeholder: 'The text input can hold an unlimited amount of text. input your word...', + controller: this.textInputController + }) + .type(this.nextType) + .width('50%') + .height('50') + .margin(40) + .fontSize(16) + .id('textCommonSelectionState0230_txInput') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + this.tiScrollRes = `TextInput{scrolling:[${totalOffsetX},${totalOffsetY}]}`; + this.testRes += '{current InputType is:' + this.curTypeStr + ',onContentScroll[' + this.tiScrollRes + '}\n'; + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + if (selectionStart == selectionEnd) { + this.tiSelectRes = `TextInput{point:[${selectionStart},${selectionEnd}]}`; + } else { + let length = this.curTypeMsg.length; + if (selectionEnd < length) { + this.textInputController.setTextSelection(selectionStart, length); + } + this.tiTxt = `TextInput{select:[${selectionStart},${selectionEnd}]}`; + } + }) + Button('switch Type') + .id('textCommonSelectionState0230_1_btn') + .enabled(this.btnEnable).onClick(() => { + switch (this.nextType) { + case InputType.Normal: + this.nextType = InputType.Number; + this.curTypeStr = 'InputType.Number'; + this.nextTypeStr = 'InputType.PhoneNumber'; + this.curTypeMsg = 'sgughakjh5876980809806\ngdausihio8 9uyssh98f67yh\n798789y98y89y8'; + break; + case InputType.Number: + this.nextType = InputType.PhoneNumber; + this.curTypeStr = 'InputType.PhoneNumber'; + this.nextTypeStr = 'InputType.Email'; + this.curTypeMsg = '13912345678\n7698-4578978\n(79868-85645dsfsfa8)'; + break; + case InputType.PhoneNumber: + this.nextType = InputType.Email; + this.curTypeStr = 'InputType.Email'; + this.nextTypeStr = 'InputType.Password'; + this.curTypeMsg = 'sahgfuahoi@gsuhf\n7@@d98-4578978\n(79868-vdidfa8)'; + break; + case InputType.Email: + this.nextType = InputType.Password; + this.curTypeStr = 'InputType.Password'; + this.nextTypeStr = 'InputType.URL'; + this.curTypeMsg = 'sahgDFS3452fuahoi@gsuhf\n7@@d98-4578978\n(79868-vdidfa8)'; + break; + case InputType.Password: + this.nextType = InputType.URL; + this.curTypeStr = 'InputType.URL'; + this.nextTypeStr = 'nothing'; + this.curTypeMsg = 'https://docs.qq.com/sheet/safa?tab=tb0riy\dfa://safafvs./browse/sds-6565?filter=-1\n'; + this.btnEnable = false; + break; + case InputType.URL: + this.btnEnable = false; + return; + } + // this.testRes += '{current InputType is:' + this.curTypeStr + ',next InputType is' + this.nextTypeStr + '}\n'; + }) + + Text('test result is:\n' + this.testRes) + .fontColor(Color.Brown) + .fontSize(10) + .margin({ top: 20, bottom: 10 }) + .width('95%') + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_2.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_2.ets new file mode 100644 index 00000000..f0905400 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_2.ets @@ -0,0 +1,113 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import Settings from '../../../test/model/Settings' + +import Window from '@ohos.window' +import common from '@ohos.app.ability.common'; +import { BusinessError } from '@kit.BasicServicesKit'; + +@Entry +@Component +struct UIComponentTextCommonSelectionState0230_2 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'TextArea/TextInput/Search,' + this.msg + @State taTxt: string = 'TextInput:' + this.msg + @State taSelectRes: string = '' + @State taScrollRes: string = '' + textAreaController: TextAreaController = new TextAreaController() + @State nextType: number = TextAreaType.NORMAL; + nextTypeStr: string = 'TextAreaType.Number' + curTypeStr: string = 'TextAreaType.Normal' + curTypeMsg: string = 'Textfssautyuiewfi769\n%……&*(&))*(&*\n#$%^&YVJHG*HNT16545132' + @State testRes: string = + '{current TextAreaType is:' + this.curTypeStr + ',next TextAreaType is' + this.nextTypeStr + '}\n'; + @State btnEnable: boolean = true + + build() { + Column() { + TextArea({ + text: this.curTypeMsg, + placeholder: 'The text input can hold an unlimited amount of text. input your word...', + controller: this.textAreaController + }) + .type(this.nextType) + .width('100%') + .height('50') + .margin(40) + .fontSize(18) + .id('textCommonSelectionState0230_txArea') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + this.taScrollRes = `TextArea{scrolling:[${totalOffsetX},${totalOffsetY}]}`; + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + let length = this.curTypeMsg.length; + if (selectionEnd < length) { + this.textAreaController.setTextSelection(selectionStart, length); + } + }) + Button('switch Type') + .id('textCommonSelectionState0230_2_btn') + .enabled(this.btnEnable).onClick(() => { + switch (this.nextType) { + case TextAreaType.NORMAL: + this.nextType = TextAreaType.NUMBER; + this.curTypeStr = 'TextAreaType.Number'; + this.nextTypeStr = 'TextAreaType.PhoneNumber'; + this.curTypeMsg = 'sgughakjh5876980809806\\ngdausihio8 9uyssh98f67yh\\n798789y98y89y8'; + break; + case TextAreaType.NUMBER: + this.nextType = TextAreaType.PHONE_NUMBER; + this.curTypeStr = 'TextAreaType.PhoneNumber'; + this.nextTypeStr = 'TextAreaType.Email'; + this.curTypeMsg = '13912345678\\n7698-4578978\\n(79868-856458)'; + break; + case TextAreaType.PHONE_NUMBER: + this.nextType = TextAreaType.EMAIL; + this.curTypeStr = 'TextAreaType.Email'; + this.nextTypeStr = 'TextAreaType.URL'; + this.curTypeMsg = '13912345678\n7698-4578978\n(79868-85645dsfsfa8)'; + break; + case TextAreaType.EMAIL: + this.nextType = TextAreaType.URL; + this.curTypeStr = 'TextAreaType.URL'; + this.nextTypeStr = 'nothing'; + this.curTypeMsg = + 'https://docs.qq.com/sheet/safa?tab=tb0riy\\ndfa://safafvs./browse/sds-6565?filter=-1\na://safafvs./browsdgdwgdgjk.//fdsvv.vosm'; + this.btnEnable = false; + break; + case TextAreaType.URL: + this.btnEnable = false; + return; + } + this.testRes += '\n{current TextAreaType is:' + this.curTypeStr + + ',next TextAreaType is' + this.nextTypeStr + + ',onContentScroll[' + this.taScrollRes + ']' + + '}\n'; + }) + + Text('test result is:\n' + this.testRes) + .fontColor(Color.Brown) + .fontSize(20) + .margin({ top: 20, bottom: 10 }) + .width('95%') + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_3.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_3.ets new file mode 100644 index 00000000..fbbab127 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_3.ets @@ -0,0 +1,117 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import Settings from '../../../test/model/Settings' + +import Window from '@ohos.window' +import common from '@ohos.app.ability.common'; +import { BusinessError } from '@kit.BasicServicesKit'; + +@Entry +@Component +struct UIComponentTextCommonSelectionState0230_3 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'TextArea/TextInput/Search,' + this.msg + @State changeValue: string = 'search:' + this.msg + @State seSelectRes: string = '' + @State seScrollRes: string = '' + searchController: SearchController = new SearchController(); + @State nextType: number = SearchType.NORMAL; + nextTypeStr: string = 'SearchType.Number' + curTypeStr: string = 'SearchType.Normal' + curTypeMsg: string = 'asfsfafdsg4%^&*()_+(\n%……&*(&))*(&*\n#$%^&YVJHG*HNT16545132' + @State testRes: string = + 'current SearchType is:{' + this.curTypeStr + ',next SearchType is' + this.nextTypeStr + '}\n'; + @State btnEnable: boolean = true + + build() { + Column() { + Search({ + value: this.curTypeMsg, + placeholder: 'Type to search...', + controller: this.searchController + }) + .id('textSelectionOptimization0230_search') + .type(this.nextType) + .searchButton('SEARCH') + .width('100%') + .height(50) + .backgroundColor('#F5F5F5') + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .textFont({ size: 14, weight: 400 }) + .margin(20) + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + this.seScrollRes = `Search{scrolling:[${totalOffsetX},${totalOffsetY}]}`; + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log('onTextSelectionChange>>'); + let length = this.curTypeMsg.length; + if (selectionEnd < length) { + this.searchController.setTextSelection(selectionStart, length); + } + this.seSelectRes = `Search{select:[${selectionStart},${selectionEnd}]}`; + }) + Button('switch Type') + .id('textCommonSelectionState0230_3_btn') + .enabled(this.btnEnable) + .onClick(() => { + switch (this.nextType) { + case SearchType.NORMAL: + this.nextType = SearchType.NUMBER; + this.curTypeStr = 'SearchType.Number'; + this.nextTypeStr = 'SearchType.PhoneNumber'; + this.curTypeMsg = 'sgughakjh5876980809806\ngdausihio8 9uyssh98f67yh\n798789y98y89y8'; + break; + case SearchType.NUMBER: + this.nextType = SearchType.PHONE_NUMBER; + this.curTypeStr = 'SearchType.PhoneNumber'; + this.nextTypeStr = 'SearchType.Email'; + this.curTypeMsg = '13912345678\n7698-4578978\n(79868-856458)'; + break; + case SearchType.PHONE_NUMBER: + this.nextType = SearchType.EMAIL; + this.curTypeStr = 'SearchType.Email'; + this.nextTypeStr = 'SearchType.Password'; + this.curTypeMsg = 'sahgfuahoi@gsuhf\n7@@d98-4578978\n(79868-vdidfa8)'; + break; + case SearchType.EMAIL: + this.nextType = SearchType.URL; + this.curTypeStr = 'SearchType.URL'; + this.nextTypeStr = 'nothing'; + this.curTypeMsg = 'https://docs.qq.com/sheet/safa?tab=tb0riy\dfa://safafvs./browse/sds-6565?filter=-1\n'; + this.btnEnable = false; + break; + case SearchType.URL: + this.btnEnable = false; + return; + } + this.testRes += '\n{current SearchType is:' + this.curTypeStr + + ',next SearchType is' + this.nextTypeStr + + '}\n'; + }) + + Text('test result is:\n' + this.testRes) + .fontColor(Color.Brown) + .fontSize(20) + .margin({ top: 20, bottom: 10 }) + .width('95%') + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0240_1.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0240_1.ets new file mode 100644 index 00000000..38980170 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0240_1.ets @@ -0,0 +1,55 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import Settings from '../../../test/model/Settings' + +import Window from '@ohos.window' +import common from '@ohos.app.ability.common'; +import { BusinessError } from '@kit.BasicServicesKit'; + +@Entry +@Component +struct UIComponentTextCommonSelectionState0240_1 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'TextArea/TextInput/Search,' + this.msg + @State tiTxt: string = 'TextInput:' + this.msg + textInputController: TextInputController = new TextInputController() + + build() { + Column() { + TextInput({ + text: this.tiTxt, + placeholder: 'The text input can hold an unlimited amount of text. input your word...', + controller: this.textInputController + }) + .style(TextInputStyle.Inline) + .width('80%') + .height(200) + .margin(40) + .fontSize(16) + .copyOption(CopyOptions.InApp) + .id('textCommonSelectionState0240_txInput') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>TextInput{scrolling:[${totalOffsetX},${totalOffsetY}]}`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0240_2.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0240_2.ets new file mode 100644 index 00000000..84fe8554 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0240_2.ets @@ -0,0 +1,53 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import Settings from '../../../test/model/Settings' + +import Window from '@ohos.window' +import common from '@ohos.app.ability.common'; +import { BusinessError } from '@kit.BasicServicesKit'; + +@Entry +@Component +struct UIComponentTextCommonSelectionState0240_2 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State taTxt: string = 'TextInput:' + this.msg + textAreaController: TextAreaController = new TextAreaController() + + build() { + Column() { + TextArea({ + text: this.taTxt, + placeholder: 'The text input can hold an unlimited amount of text. input your word...', + controller: this.textAreaController + }) + .style(TextContentStyle.INLINE) + .width('100%') + .height('50') + .margin(40) + .fontSize(18) + .id('textCommonSelectionState0240_txArea') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>TextArea{scrolling:[${totalOffsetX},${totalOffsetY}]}`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0250.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0250.ets new file mode 100644 index 00000000..07c1914b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0250.ets @@ -0,0 +1,52 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextCommonSelectionState0250 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'Text:' + this.msg + + build() { + Column() { + Text() { + Span(this.txt) + ImageSpan('cat.jpg') + .width('100px') + .height('100px') + SymbolSpan($r('sys.symbol.ohos_wifi')) + .fontSize(96) + .fontColor([Color.Gray]) + } + .id('textCommonSelectionState0250_tx') + .width('100%') + .margin(20) + .fontSize(16) + .copyOption(CopyOptions.InApp) + .fontColor('#182431') + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0260.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0260.ets new file mode 100644 index 00000000..d215a3db --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0260.ets @@ -0,0 +1,85 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextCommonSelectionState0260 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State richEdTxt: string = 'RichEditor:' + this.msg + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + private editorMenuOptions: Array = + [{ icon: 'icon.png' }, { icon: 'cat.jpg' }, { icon: 'openeye.png' }, { icon: 'icon.png' }, { icon: 'openeye.png' }, + { icon: 'cat.jpg' }] + private expandedMenuOptions: Array = + [{ + startIcon: 'cat.jpg', content: '词典', action: () => { + console.log('click it>>'); + this.options.controller.closeSelectionMenu(); + } + }, { + startIcon: 'icon.png', content: '翻译', action: () => { + } + }, { + startIcon: 'openeye.png', content: '搜索', action: () => { + } + }] + private selectionMenuOptions: SelectionMenuOptions = { + editorMenuOptions: this.editorMenuOptions, + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + + build() { + Column() { + RichEditor(this.options) + .id('textCommonSelectionState0260_richEd') + .onReady(() => { + this.controller.addTextSpan(this.richEdTxt, { style: { fontColor: Color.Orange, fontSize: 18 } }); + this.controller.addSymbolSpan($r('sys.symbol.ohos_wifi'), { style: { fontSize: 18 } }); + this.controller.addImageSpan('cat.jpg',{imageStyle:{size:['100px','100px']}}) + }) + .onSelect((value: RichEditorSelection) => { + console.log('onSelect >>>'); + }) + .bindSelectionMenu(RichEditorSpanType.TEXT, this.MyMenu(), RichEditorResponseType.LONG_PRESS) + .bindSelectionMenu(RichEditorSpanType.IMAGE, this.MyMenu(), RichEditorResponseType.LONG_PRESS) + .bindSelectionMenu(RichEditorSpanType.MIXED, this.MyMenu(), RichEditorResponseType.LONG_PRESS) + .borderWidth(1) + .borderColor(Color.Red) + .width('100%') + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0050.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0050.ets new file mode 100755 index 00000000..6525c1e2 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0050.ets @@ -0,0 +1,247 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; +import { LengthMetrics } from '@kit.ArkUI'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0050 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('123') + .minFontSize(10) + .id('UIComponentTextCopyAttributeReplacement0050') + .copyOption(CopyOptions.LocalDevice) + Divider().margin(20) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + if (item.includes("fontSize")) { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0060.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0060.ets new file mode 100755 index 00000000..c3c087d1 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0060.ets @@ -0,0 +1,247 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; +import { LengthMetrics } from '@kit.ArkUI'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0060 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('123') + .id('UIComponentTextCopyAttributeReplacement0060') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .copyOption(CopyOptions.LocalDevice) + Divider().margin(20) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + if (item.includes("heightAdaptivePolicy")) { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0070.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0070.ets new file mode 100755 index 00000000..41efbe9a --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0070.ets @@ -0,0 +1,247 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; +import { LengthMetrics } from '@kit.ArkUI'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0070 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('123') + .id('UIComponentTextCopyAttributeReplacement0070') + .letterSpacing(0) + .copyOption(CopyOptions.LocalDevice) + Divider().margin(12) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + if (item.includes("letterSpacing")) { + Text(item) + .fontSize(20) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0080.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0080.ets new file mode 100755 index 00000000..47e8fc6e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0080.ets @@ -0,0 +1,247 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; +import { LengthMetrics } from '@kit.ArkUI'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0080 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('123') + .id('UIComponentTextCopyAttributeReplacement0080') + .lineHeight('16px') + .copyOption(CopyOptions.LocalDevice) + Divider().margin(12) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + if (item.includes("lineHeight")) { + Text(item) + .fontSize(20) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0090.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0090.ets new file mode 100755 index 00000000..baa67447 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0090.ets @@ -0,0 +1,247 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; +import { LengthMetrics } from '@kit.ArkUI'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0090 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('123') + .id('UIComponentTextCopyAttributeReplacement0090') + .lineSpacing(LengthMetrics.px(0)) + .copyOption(CopyOptions.LocalDevice) + Divider().margin(12) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + if (item.includes("lineSpacing")) { + Text(item) + .fontSize(20) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0100.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0100.ets new file mode 100755 index 00000000..eb3f9196 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0100.ets @@ -0,0 +1,246 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0100 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('123') + .id('UIComponentTextCopyAttributeReplacement0100') + .baselineOffset(0) + .copyOption(CopyOptions.LocalDevice) + Divider().margin(12) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + if (item.includes("baselineOffset")) { + Text(item) + .fontSize(20) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0110.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0110.ets new file mode 100755 index 00000000..60d064d2 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0110.ets @@ -0,0 +1,246 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0110 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('This is the setting of textOverflow to Clip text content This is the setting of textOverflow to None text content. This is the setting of textOverflow to Clip text content This is the setting of textOverflow to None text content') + .id('UIComponentTextCopyAttributeReplacement0110') + .textOverflow({ overflow: TextOverflow.Clip }) + .copyOption(CopyOptions.LocalDevice) + Divider().margin(20) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + if (item.includes("textOverflow")) { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0120.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0120.ets new file mode 100755 index 00000000..72862486 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0120.ets @@ -0,0 +1,247 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0120 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('123') + .id('UIComponentTextCopyAttributeReplacement0120') + .textAlign(TextAlign.Start) + .copyOption(CopyOptions.LocalDevice) + + Divider().margin(12) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + if (item.includes("textAlign")) { + Text(item) + .fontSize(20) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0130.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0130.ets new file mode 100755 index 00000000..736dcc27 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0130.ets @@ -0,0 +1,246 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0130 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('123') + .id('UIComponentTextCopyAttributeReplacement0130') + .maxLines(3) + .copyOption(CopyOptions.LocalDevice) + Divider().margin(12) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + if (item.includes("maxLines")) { + Text(item) + .fontSize(20) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0140.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0140.ets new file mode 100755 index 00000000..8534f9b4 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0140.ets @@ -0,0 +1,236 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0140 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('123') + .id('UIComponentTextCopyAttributeReplacement0140') + .copyOption(CopyOptions.LocalDevice) + Divider().margin(12) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0150.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0150.ets new file mode 100755 index 00000000..c1bf67f8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0150.ets @@ -0,0 +1,246 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0150 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('123') + .id('UIComponentTextCopyAttributeReplacement0150') + .textIndent(0) + .copyOption(CopyOptions.LocalDevice) + Divider().margin(20) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + if (item.includes("textIndent")) { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0160.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0160.ets new file mode 100755 index 00000000..564fedfa --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0160.ets @@ -0,0 +1,246 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0160 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('123') + .id('UIComponentTextCopyAttributeReplacement0160') + .wordBreak(WordBreak.BREAK_WORD) + .copyOption(CopyOptions.LocalDevice) + Divider().margin(20) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + if (item.includes("wordBreak")) { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0170.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0170.ets new file mode 100755 index 00000000..1281c1f8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0170.ets @@ -0,0 +1,246 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0170 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('123') + .id('UIComponentTextCopyAttributeReplacement0170') + .ellipsisMode(EllipsisMode.END) + .copyOption(CopyOptions.LocalDevice) + Divider().margin(20) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + if (item.includes("ellipsisMode")) { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0180.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0180.ets new file mode 100755 index 00000000..fccc9e2b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0180.ets @@ -0,0 +1,246 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0180 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('123') + .id('UIComponentTextCopyAttributeReplacement0180') + .lineBreakStrategy(LineBreakStrategy.GREEDY) + .copyOption(CopyOptions.LocalDevice) + Divider().margin(20) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + if (item.includes("lineBreakStrategy")) { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0190.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0190.ets new file mode 100755 index 00000000..0a4153b5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0190.ets @@ -0,0 +1,254 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0190 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('123'){ + Span('Hello World') + } + .id('UIComponentTextCopyAttributeReplacement0190') + .fontSize('16fp') + .fontColor(Color.Black) + .textShadow({ radius: 10, color: Color.Black, offsetX: 0, offsetY: 0 }) + .fontStyle(FontStyle.Normal) + .fontWeight(FontWeight.Normal) + .fontFamily('HarmonyOS Sans') + .copyOption(CopyOptions.LocalDevice) + .fontFeature( "\"ss01\" on") + Divider().margin(20) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0200.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0200.ets new file mode 100755 index 00000000..09642cac --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0200.ets @@ -0,0 +1,252 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0200 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + build() { + Column() { + Text('123'){ + Span('Hello World') + } + .id('UIComponentTextCopyAttributeReplacement0200') + .fontSize('16fp') + .fontColor(Color.Black) + .fontStyle(FontStyle.Normal) + .fontWeight(FontWeight.Normal) + .fontFamily('HarmonyOS Sans') + .copyOption(CopyOptions.LocalDevice) + Divider().margin(20) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0210.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0210.ets new file mode 100755 index 00000000..f6bfdf03 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0210.ets @@ -0,0 +1,254 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0210 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + build() { + Column() { + Text('123'){ + Span('Hello World') + } + .id('UIComponentTextCopyAttributeReplacement0210') + .decoration({ + type: TextDecorationType.None, + color: Color.Black, + style: TextDecorationStyle.SOLID + }) + .textCase(TextCase.Normal) + .copyOption(CopyOptions.LocalDevice) + Divider().margin(20) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0220.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0220.ets new file mode 100755 index 00000000..10b99369 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0220.ets @@ -0,0 +1,253 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0220 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + build() { + Column() { + Text('123') { + Span('Hello World') + } + .id('UIComponentTextCopyAttributeReplacement0220') + .minFontSize(10) + .maxFontSize(30) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .copyOption(CopyOptions.LocalDevice) + Divider().margin(20) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0230.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0230.ets new file mode 100755 index 00000000..fc7cd577 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0230.ets @@ -0,0 +1,313 @@ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} + +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0230 { + @State imagePixelMap: image.PixelMap | undefined = undefined + @State msgList: Array = []; + @State permission_state: boolean = true; + mutableStr: MutableStyledString = new MutableStyledString(''); + controller: TextController = new TextController(); + controllerShow: TextController = new TextController(); + richController: RichEditorController = new RichEditorController(); + mutableStyledString1: MutableStyledString = new MutableStyledString("hello world", [{ + start: 0, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Pink }) + }, { + start: 4, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Orange }) + }, + { + start: 6, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Blue }) + }, + ]); + + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + build() { + Scroll() { + Column({ space: 5 }) { + Divider() + Text("Text组件设置baselineoffset") + Text("带回家的好类扣手机端开发了健康的水立方") + .copyOption(CopyOptions.LocalDevice) + .draggable(true) + .fontSize(30) + .textShadow({ + radius: 10, + color: Color.Green, + offsetX: -10, + offsetY: 10 + }) + .fontWeight(900) + .width(300) + .height(100) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .focusable(true) + .decoration({ type: TextDecorationType.LineThrough, color: Color.Red }) + .id("text") + Divider() + + Divider() + Row() { + Button("读取剪贴板内容") + .onClick(() => { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + for (let i = 0; i < pasteData.getRecordCount(); i++) { + let record = pasteData.getRecord(i); + if (record.getData("openharmony.styled-string") == undefined) { + continue; + } + record.getData("openharmony.styled-string").then(async (value) => { + if (value instanceof ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(value); + this.msgList.push('剪贴板内容_转换:' + StyledString.toHtml(styledStringObject)); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + }); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + }) + .id("getData") + Button("重置") + .onClick(() => { + let mutableShow = new MutableStyledString(''); + this.controllerShow.setStyledString(mutableShow) + this.msgList = []; + }) + } + + Divider() + Text(undefined, { controller: this.controllerShow }).copyOption(CopyOptions.LocalDevice) + .margin({ top: 40 }) + Divider() + + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + } + .border({ width: 1, radius: 5 }) + .width('100%') + } + .height("90%") + .align(Alignment.Top) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0240.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0240.ets new file mode 100755 index 00000000..65243ca9 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0240.ets @@ -0,0 +1,312 @@ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} + +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0240 { + @State imagePixelMap: image.PixelMap | undefined = undefined + @State msgList: Array = []; + @State permission_state: boolean = true; + mutableStr: MutableStyledString = new MutableStyledString(''); + controller: TextController = new TextController(); + controllerShow: TextController = new TextController(); + richController: RichEditorController = new RichEditorController(); + mutableStyledString1: MutableStyledString = new MutableStyledString("hello world", [{ + start: 0, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Pink }) + }, { + start: 4, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Orange }) + }, + { + start: 6, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Blue }) + }, + ]); + + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + build() { + Scroll() { + Column({ space: 5 }) { + Divider() + Text("Text组件设置baselineoffset") + Text("带回家的好类扣手机端开发了健康的水立方") + .copyOption(CopyOptions.LocalDevice) + .draggable(true) + .fontSize(30) + .baselineOffset(-50) + .textShadow({ + radius: 10, + color: Color.Green, + offsetX: -10, + offsetY: 10 + }) + .fontWeight(900) + .width(300) + .height(100) + .letterSpacing(0) + .id("text") + Divider() + + Divider() + Row() { + Button("读取剪贴板内容") + .onClick(() => { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + for (let i = 0; i < pasteData.getRecordCount(); i++) { + let record = pasteData.getRecord(i); + if (record.getData("openharmony.styled-string") == undefined) { + continue; + } + record.getData("openharmony.styled-string").then(async (value) => { + if (value instanceof ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(value); + this.msgList.push('剪贴板内容_转换:' + StyledString.toHtml(styledStringObject)); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + }); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + }) + .id("getData") + Button("重置") + .onClick(() => { + let mutableShow = new MutableStyledString(''); + this.controllerShow.setStyledString(mutableShow) + this.msgList = []; + }) + } + + Divider() + Text(undefined, { controller: this.controllerShow }).copyOption(CopyOptions.LocalDevice) + .margin({ top: 40 }) + Divider() + + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + } + .border({ width: 1, radius: 5 }) + .width('100%') + } + .height("90%") + .align(Alignment.Top) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0250.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0250.ets new file mode 100755 index 00000000..e8eec184 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0250.ets @@ -0,0 +1,314 @@ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} + +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0250 { + @State imagePixelMap: image.PixelMap | undefined = undefined + @State msgList: Array = []; + @State permission_state: boolean = true; + mutableStr: MutableStyledString = new MutableStyledString(''); + controller: TextController = new TextController(); + controllerShow: TextController = new TextController(); + richController: RichEditorController = new RichEditorController(); + mutableStyledString1: MutableStyledString = new MutableStyledString("hello world", [{ + start: 0, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Pink }) + }, { + start: 4, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Orange }) + }, + { + start: 6, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Blue }) + }, + ]); + + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + build() { + Scroll() { + Column({ space: 5 }) { + Divider() + Text("Text组件设置baselineoffset") + Text("带回家的好类扣手机端开发了健康的水立方") + .copyOption(CopyOptions.LocalDevice) + .draggable(true) + .fontSize(30) + .textShadow({ + radius: 10, + color: Color.Green, + offsetX: -10, + offsetY: 10 + }) + .fontWeight(900) + .width(300) + .lineHeight('16px') + .height(100) + .focusable(true) + .textSelectable(TextSelectableMode.SELECTABLE_FOCUSABLE) + .decoration({ type: TextDecorationType.LineThrough, color: Color.Red }) + .id("text") + Divider() + + Divider() + Row() { + Button("读取剪贴板内容") + .onClick(() => { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + for (let i = 0; i < pasteData.getRecordCount(); i++) { + let record = pasteData.getRecord(i); + if (record.getData("openharmony.styled-string") == undefined) { + continue; + } + record.getData("openharmony.styled-string").then(async (value) => { + if (value instanceof ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(value); + this.msgList.push('剪贴板内容_转换:' + StyledString.toHtml(styledStringObject)); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + }); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + }) + .id("getData") + Button("重置") + .onClick(() => { + let mutableShow = new MutableStyledString(''); + this.controllerShow.setStyledString(mutableShow) + this.msgList = []; + }) + } + + Divider() + Text(undefined, { controller: this.controllerShow }).copyOption(CopyOptions.LocalDevice) + .margin({ top: 40 }) + Divider() + + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + } + .border({ width: 1, radius: 5 }) + .width('100%') + } + .height("90%") + .align(Alignment.Top) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0260.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0260.ets new file mode 100755 index 00000000..36dfe2f7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0260.ets @@ -0,0 +1,313 @@ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} + +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0260 { + @State imagePixelMap: image.PixelMap | undefined = undefined + @State msgList: Array = []; + @State permission_state: boolean = true; + mutableStr: MutableStyledString = new MutableStyledString(''); + controller: TextController = new TextController(); + controllerShow: TextController = new TextController(); + richController: RichEditorController = new RichEditorController(); + mutableStyledString1: MutableStyledString = new MutableStyledString("hello world", [{ + start: 0, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Pink }) + }, { + start: 4, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Orange }) + }, + { + start: 6, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Blue }) + }, + ]); + + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + build() { + Scroll() { + Column({ space: 5 }) { + Divider() + Text("Text组件设置baselineoffset") + Text("带回家的好类扣手机端开发了健康的水立方") + .copyOption(CopyOptions.LocalDevice) + .draggable(true) + .fontSize(30) + .textShadow({ + radius: 10, + color: Color.Green, + offsetX: -10, + offsetY: 10 + }) + .fontWeight(900) + .width(300) + .lineHeight('16px') + .height(100) + .lineSpacing(LengthMetrics.px(0)) + .focusable(true) + .id("text") + Divider() + + Divider() + Row() { + Button("读取剪贴板内容") + .onClick(() => { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + for (let i = 0; i < pasteData.getRecordCount(); i++) { + let record = pasteData.getRecord(i); + if (record.getData("openharmony.styled-string") == undefined) { + continue; + } + record.getData("openharmony.styled-string").then(async (value) => { + if (value instanceof ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(value); + this.msgList.push('剪贴板内容_转换:' + StyledString.toHtml(styledStringObject)); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + }); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + }) + .id("getData") + Button("重置") + .onClick(() => { + let mutableShow = new MutableStyledString(''); + this.controllerShow.setStyledString(mutableShow) + this.msgList = []; + }) + } + + Divider() + Text(undefined, { controller: this.controllerShow }).copyOption(CopyOptions.LocalDevice) + .margin({ top: 40 }) + Divider() + + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + } + .border({ width: 1, radius: 5 }) + .width('100%') + } + .height("90%") + .align(Alignment.Top) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0270.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0270.ets new file mode 100755 index 00000000..9cd0ff41 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0270.ets @@ -0,0 +1,313 @@ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} + +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0270 { + @State imagePixelMap: image.PixelMap | undefined = undefined + @State msgList: Array = []; + @State permission_state: boolean = true; + mutableStr: MutableStyledString = new MutableStyledString(''); + controller: TextController = new TextController(); + controllerShow: TextController = new TextController(); + richController: RichEditorController = new RichEditorController(); + mutableStyledString1: MutableStyledString = new MutableStyledString("hello world", [{ + start: 0, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Pink }) + }, { + start: 4, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Orange }) + }, + { + start: 6, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Blue }) + }, + ]); + + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + build() { + Scroll() { + Column({ space: 5 }) { + Divider() + Text("Text组件设置baselineoffset") + Text("带回家的好类扣手机端开发了健康的水立方") + .copyOption(CopyOptions.LocalDevice) + .draggable(true) + .fontSize(30) + .textShadow({ + radius: 10, + color: Color.Green, + offsetX: -10, + offsetY: 10 + }) + .fontWeight(900) + .width(300) + .baselineOffset(0) + .height(100) + .focusable(true) + .decoration({ type: TextDecorationType.LineThrough, color: Color.Red }) + .id("text") + Divider() + + Divider() + Row() { + Button("读取剪贴板内容") + .onClick(() => { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + for (let i = 0; i < pasteData.getRecordCount(); i++) { + let record = pasteData.getRecord(i); + if (record.getData("openharmony.styled-string") == undefined) { + continue; + } + record.getData("openharmony.styled-string").then(async (value) => { + if (value instanceof ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(value); + this.msgList.push('剪贴板内容_转换:' + StyledString.toHtml(styledStringObject)); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + }); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + }) + .id("getData") + Button("重置") + .onClick(() => { + let mutableShow = new MutableStyledString(''); + this.controllerShow.setStyledString(mutableShow) + this.msgList = []; + }) + } + + Divider() + Text(undefined, { controller: this.controllerShow }).copyOption(CopyOptions.LocalDevice) + .margin({ top: 40 }) + Divider() + + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + } + .border({ width: 1, radius: 5 }) + .width('100%') + } + .height("90%") + .align(Alignment.Top) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0280.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0280.ets new file mode 100755 index 00000000..53360227 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0280.ets @@ -0,0 +1,314 @@ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} + +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0280 { + @State imagePixelMap: image.PixelMap | undefined = undefined + @State msgList: Array = []; + @State permission_state: boolean = true; + mutableStr: MutableStyledString = new MutableStyledString(''); + controller: TextController = new TextController(); + controllerShow: TextController = new TextController(); + richController: RichEditorController = new RichEditorController(); + mutableStyledString1: MutableStyledString = new MutableStyledString("hello world", [{ + start: 0, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Pink }) + }, { + start: 4, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Orange }) + }, + { + start: 6, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Blue }) + }, + ]); + + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + build() { + Scroll() { + Column({ space: 5 }) { + Divider() + Text("Text组件设置baselineoffset") + Text("带回家的好类扣手机端开发了健康的水立方") + .copyOption(CopyOptions.LocalDevice) + .draggable(true) + .fontSize(30) + .textShadow({ + radius: 10, + color: Color.Green, + offsetX: -10, + offsetY: 10 + }) + .fontWeight(900) + .textOverflow({ overflow: TextOverflow.Clip }) + .width(300) + .height(100) + .focusable(true) + .textSelectable(TextSelectableMode.SELECTABLE_FOCUSABLE) + .decoration({ type: TextDecorationType.LineThrough, color: Color.Red }) + .id("text") + Divider() + + Divider() + Row() { + Button("读取剪贴板内容") + .onClick(() => { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + for (let i = 0; i < pasteData.getRecordCount(); i++) { + let record = pasteData.getRecord(i); + if (record.getData("openharmony.styled-string") == undefined) { + continue; + } + record.getData("openharmony.styled-string").then(async (value) => { + if (value instanceof ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(value); + this.msgList.push('剪贴板内容_转换:' + StyledString.toHtml(styledStringObject)); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + }); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + }) + .id("getData") + Button("重置") + .onClick(() => { + let mutableShow = new MutableStyledString(''); + this.controllerShow.setStyledString(mutableShow) + this.msgList = []; + }) + } + + Divider() + Text(undefined, { controller: this.controllerShow }).copyOption(CopyOptions.LocalDevice) + .margin({ top: 40 }) + Divider() + + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + } + .border({ width: 1, radius: 5 }) + .width('100%') + } + .height("90%") + .align(Alignment.Top) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0290.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0290.ets new file mode 100755 index 00000000..ff20cb1d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0290.ets @@ -0,0 +1,314 @@ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} + +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0290 { + @State imagePixelMap: image.PixelMap | undefined = undefined + @State msgList: Array = []; + @State permission_state: boolean = true; + mutableStr: MutableStyledString = new MutableStyledString(''); + controller: TextController = new TextController(); + controllerShow: TextController = new TextController(); + richController: RichEditorController = new RichEditorController(); + mutableStyledString1: MutableStyledString = new MutableStyledString("hello world", [{ + start: 0, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Pink }) + }, { + start: 4, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Orange }) + }, + { + start: 6, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Blue }) + }, + ]); + + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + build() { + Scroll() { + Column({ space: 5 }) { + Divider() + Text("Text组件设置baselineoffset") + Text("带回家的好类扣手机端开发了健康的水立方") + .copyOption(CopyOptions.LocalDevice) + .draggable(true) + .fontSize(30) + .textShadow({ + radius: 10, + color: Color.Green, + offsetX: -10, + offsetY: 10 + }) + .fontWeight(900) + .textAlign(TextAlign.Start) + .width(300) + .height(100) + .focusable(true) + .textSelectable(TextSelectableMode.SELECTABLE_FOCUSABLE) + .decoration({ type: TextDecorationType.LineThrough, color: Color.Red }) + .id("text") + Divider() + + Divider() + Row() { + Button("读取剪贴板内容") + .onClick(() => { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + for (let i = 0; i < pasteData.getRecordCount(); i++) { + let record = pasteData.getRecord(i); + if (record.getData("openharmony.styled-string") == undefined) { + continue; + } + record.getData("openharmony.styled-string").then(async (value) => { + if (value instanceof ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(value); + this.msgList.push('剪贴板内容_转换:' + StyledString.toHtml(styledStringObject)); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + }); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + }) + .id("getData") + Button("重置") + .onClick(() => { + let mutableShow = new MutableStyledString(''); + this.controllerShow.setStyledString(mutableShow) + this.msgList = []; + }) + } + + Divider() + Text(undefined, { controller: this.controllerShow }).copyOption(CopyOptions.LocalDevice) + .margin({ top: 40 }) + Divider() + + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + } + .border({ width: 1, radius: 5 }) + .width('100%') + } + .height("90%") + .align(Alignment.Top) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0300.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0300.ets new file mode 100755 index 00000000..48d2c398 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0300.ets @@ -0,0 +1,315 @@ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} + +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0300 { + @State imagePixelMap: image.PixelMap | undefined = undefined + @State msgList: Array = []; + @State permission_state: boolean = true; + mutableStr: MutableStyledString = new MutableStyledString(''); + controller: TextController = new TextController(); + controllerShow: TextController = new TextController(); + richController: RichEditorController = new RichEditorController(); + mutableStyledString1: MutableStyledString = new MutableStyledString("hello world", [{ + start: 0, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Pink }) + }, { + start: 4, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Orange }) + }, + { + start: 6, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Blue }) + }, + ]); + + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + build() { + Scroll() { + Column({ space: 5 }) { + Divider() + Text("Text组件设置baselineoffset") + Text("带回家的好类扣手机端开发了健康的水立方") + .copyOption(CopyOptions.LocalDevice) + .draggable(true) + .fontSize(30) + .textShadow({ + radius: 10, + color: Color.Green, + offsetX: -10, + offsetY: 10 + }) + .fontWeight(900) + .margin(10) + .width(300) + .height(100) + .maxLines(3) + .focusable(true) + .textSelectable(TextSelectableMode.SELECTABLE_FOCUSABLE) + .decoration({ type: TextDecorationType.LineThrough, color: Color.Red }) + .id("text") + Divider() + + Divider() + Row() { + Button("读取剪贴板内容") + .onClick(() => { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + for (let i = 0; i < pasteData.getRecordCount(); i++) { + let record = pasteData.getRecord(i); + if (record.getData("openharmony.styled-string") == undefined) { + continue; + } + record.getData("openharmony.styled-string").then(async (value) => { + if (value instanceof ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(value); + this.msgList.push('剪贴板内容_转换:' + StyledString.toHtml(styledStringObject)); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + }); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + }) + .id("getData") + Button("重置") + .onClick(() => { + let mutableShow = new MutableStyledString(''); + this.controllerShow.setStyledString(mutableShow) + this.msgList = []; + }) + } + + Divider() + Text(undefined, { controller: this.controllerShow }).copyOption(CopyOptions.LocalDevice) + .margin({ top: 40 }) + Divider() + + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + } + .border({ width: 1, radius: 5 }) + .width('100%') + } + .height("90%") + .align(Alignment.Top) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0310.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0310.ets new file mode 100755 index 00000000..95077e1e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0310.ets @@ -0,0 +1,315 @@ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} + +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0310 { + @State imagePixelMap: image.PixelMap | undefined = undefined + @State msgList: Array = []; + @State permission_state: boolean = true; + mutableStr: MutableStyledString = new MutableStyledString(''); + controller: TextController = new TextController(); + controllerShow: TextController = new TextController(); + richController: RichEditorController = new RichEditorController(); + mutableStyledString1: MutableStyledString = new MutableStyledString("hello world", [{ + start: 0, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Pink }) + }, { + start: 4, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Orange }) + }, + { + start: 6, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Blue }) + }, + ]); + + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + build() { + Scroll() { + Column({ space: 5 }) { + Divider() + Text("Text组件设置baselineoffset") + Text("带回家的好类扣手机端开发了健康的水立方") + .copyOption(CopyOptions.LocalDevice) + .draggable(true) + .fontSize(30) + .textShadow({ + radius: 10, + color: Color.Green, + offsetX: -10, + offsetY: 10 + }) + .fontWeight(900) + .margin(10) + .width(300) + .lineHeight('16px') + .height(100) + .focusable(true) + .textSelectable(TextSelectableMode.SELECTABLE_FOCUSABLE) + .decoration({ type: TextDecorationType.LineThrough, color: Color.Red }) + .id("text") + Divider() + + Divider() + Row() { + Button("读取剪贴板内容") + .onClick(() => { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + for (let i = 0; i < pasteData.getRecordCount(); i++) { + let record = pasteData.getRecord(i); + if (record.getData("openharmony.styled-string") == undefined) { + continue; + } + record.getData("openharmony.styled-string").then(async (value) => { + if (value instanceof ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(value); + this.msgList.push('剪贴板内容_转换:' + StyledString.toHtml(styledStringObject)); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + }); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + }) + .id("getData") + Button("重置") + .onClick(() => { + let mutableShow = new MutableStyledString(''); + this.controllerShow.setStyledString(mutableShow) + this.msgList = []; + }) + } + + Divider() + Text(undefined, { controller: this.controllerShow }).copyOption(CopyOptions.LocalDevice) + .margin({ top: 40 }) + Divider() + + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + } + .border({ width: 1, radius: 5 }) + .width('100%') + } + .height("90%") + .align(Alignment.Top) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0320.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0320.ets new file mode 100755 index 00000000..c9e874f0 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0320.ets @@ -0,0 +1,315 @@ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} + +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0310 { + @State imagePixelMap: image.PixelMap | undefined = undefined + @State msgList: Array = []; + @State permission_state: boolean = true; + mutableStr: MutableStyledString = new MutableStyledString(''); + controller: TextController = new TextController(); + controllerShow: TextController = new TextController(); + richController: RichEditorController = new RichEditorController(); + mutableStyledString1: MutableStyledString = new MutableStyledString("hello world", [{ + start: 0, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Pink }) + }, { + start: 4, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Orange }) + }, + { + start: 6, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Blue }) + }, + ]); + + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + build() { + Scroll() { + Column({ space: 5 }) { + Divider() + Text("Text组件设置baselineoffset") + Text("带回家的好类扣手机端开发了健康的水立方") + .copyOption(CopyOptions.LocalDevice) + .draggable(true) + .fontSize(30) + .textShadow({ + radius: 10, + color: Color.Green, + offsetX: -10, + offsetY: 10 + }) + .fontWeight(900) + .margin(10) + .width(300) + .height(100) + .textIndent(0) + .focusable(true) + .textSelectable(TextSelectableMode.SELECTABLE_FOCUSABLE) + .decoration({ type: TextDecorationType.LineThrough, color: Color.Red }) + .id("text") + Divider() + + Divider() + Row() { + Button("读取剪贴板内容") + .onClick(() => { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + for (let i = 0; i < pasteData.getRecordCount(); i++) { + let record = pasteData.getRecord(i); + if (record.getData("openharmony.styled-string") == undefined) { + continue; + } + record.getData("openharmony.styled-string").then(async (value) => { + if (value instanceof ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(value); + this.msgList.push('剪贴板内容_转换:' + StyledString.toHtml(styledStringObject)); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + }); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + }) + .id("getData") + Button("重置") + .onClick(() => { + let mutableShow = new MutableStyledString(''); + this.controllerShow.setStyledString(mutableShow) + this.msgList = []; + }) + } + + Divider() + Text(undefined, { controller: this.controllerShow }).copyOption(CopyOptions.LocalDevice) + .margin({ top: 40 }) + Divider() + + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + } + .border({ width: 1, radius: 5 }) + .width('100%') + } + .height("90%") + .align(Alignment.Top) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0330.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0330.ets new file mode 100755 index 00000000..7f9b0166 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0330.ets @@ -0,0 +1,315 @@ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} + +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0330 { + @State imagePixelMap: image.PixelMap | undefined = undefined + @State msgList: Array = []; + @State permission_state: boolean = true; + mutableStr: MutableStyledString = new MutableStyledString(''); + controller: TextController = new TextController(); + controllerShow: TextController = new TextController(); + richController: RichEditorController = new RichEditorController(); + mutableStyledString1: MutableStyledString = new MutableStyledString("hello world", [{ + start: 0, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Pink }) + }, { + start: 4, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Orange }) + }, + { + start: 6, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Blue }) + }, + ]); + + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + build() { + Scroll() { + Column({ space: 5 }) { + Divider() + Text("Text组件设置baselineoffset") + Text("带回家的好类扣手机端开发了健康的水立方") + .copyOption(CopyOptions.LocalDevice) + .draggable(true) + .fontSize(30) + .textShadow({ + radius: 10, + color: Color.Green, + offsetX: -10, + offsetY: 10 + }) + .fontWeight(900) + .margin(10) + .width(300) + .height(100) + .wordBreak(WordBreak.BREAK_WORD) + .focusable(true) + .textSelectable(TextSelectableMode.SELECTABLE_FOCUSABLE) + .decoration({ type: TextDecorationType.LineThrough, color: Color.Red }) + .id("text") + Divider() + + Divider() + Row() { + Button("读取剪贴板内容") + .onClick(() => { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + for (let i = 0; i < pasteData.getRecordCount(); i++) { + let record = pasteData.getRecord(i); + if (record.getData("openharmony.styled-string") == undefined) { + continue; + } + record.getData("openharmony.styled-string").then(async (value) => { + if (value instanceof ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(value); + this.msgList.push('剪贴板内容_转换:' + StyledString.toHtml(styledStringObject)); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + }); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + }) + .id("getData") + Button("重置") + .onClick(() => { + let mutableShow = new MutableStyledString(''); + this.controllerShow.setStyledString(mutableShow) + this.msgList = []; + }) + } + + Divider() + Text(undefined, { controller: this.controllerShow }).copyOption(CopyOptions.LocalDevice) + .margin({ top: 40 }) + Divider() + + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + } + .border({ width: 1, radius: 5 }) + .width('100%') + } + .height("90%") + .align(Alignment.Top) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0340.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0340.ets new file mode 100755 index 00000000..06a25b33 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0340.ets @@ -0,0 +1,316 @@ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} + +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0330 { + @State imagePixelMap: image.PixelMap | undefined = undefined + @State msgList: Array = []; + @State permission_state: boolean = true; + mutableStr: MutableStyledString = new MutableStyledString(''); + controller: TextController = new TextController(); + controllerShow: TextController = new TextController(); + richController: RichEditorController = new RichEditorController(); + mutableStyledString1: MutableStyledString = new MutableStyledString("hello world", [{ + start: 0, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Pink }) + }, { + start: 4, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Orange }) + }, + { + start: 6, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Blue }) + }, + ]); + + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + build() { + Scroll() { + Column({ space: 5 }) { + Divider() + Text("Text组件设置baselineoffset") + Text("带回家的好类扣手机端开发了健康的水立方") + .copyOption(CopyOptions.LocalDevice) + .draggable(true) + .fontSize(30) + .textShadow({ + radius: 10, + color: Color.Green, + offsetX: -10, + offsetY: 10 + }) + .fontWeight(900) + .margin(10) + .width(300) + .height(100) + .textIndent(0) + .ellipsisMode(EllipsisMode.END) + .focusable(true) + .textSelectable(TextSelectableMode.SELECTABLE_FOCUSABLE) + .decoration({ type: TextDecorationType.LineThrough, color: Color.Red }) + .id("text") + Divider() + + Divider() + Row() { + Button("读取剪贴板内容") + .onClick(() => { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + for (let i = 0; i < pasteData.getRecordCount(); i++) { + let record = pasteData.getRecord(i); + if (record.getData("openharmony.styled-string") == undefined) { + continue; + } + record.getData("openharmony.styled-string").then(async (value) => { + if (value instanceof ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(value); + this.msgList.push('剪贴板内容_转换:' + StyledString.toHtml(styledStringObject)); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + }); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + }) + .id("getData") + Button("重置") + .onClick(() => { + let mutableShow = new MutableStyledString(''); + this.controllerShow.setStyledString(mutableShow) + this.msgList = []; + }) + } + + Divider() + Text(undefined, { controller: this.controllerShow }).copyOption(CopyOptions.LocalDevice) + .margin({ top: 40 }) + Divider() + + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + } + .border({ width: 1, radius: 5 }) + .width('100%') + } + .height("90%") + .align(Alignment.Top) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0350.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0350.ets new file mode 100755 index 00000000..b63974b3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0350.ets @@ -0,0 +1,316 @@ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} + +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0350 { + @State imagePixelMap: image.PixelMap | undefined = undefined + @State msgList: Array = []; + @State permission_state: boolean = true; + mutableStr: MutableStyledString = new MutableStyledString(''); + controller: TextController = new TextController(); + controllerShow: TextController = new TextController(); + richController: RichEditorController = new RichEditorController(); + mutableStyledString1: MutableStyledString = new MutableStyledString("hello world", [{ + start: 0, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Pink }) + }, { + start: 4, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Orange }) + }, + { + start: 6, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Blue }) + }, + ]); + + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + build() { + Scroll() { + Column({ space: 5 }) { + Divider() + Text("Text组件设置baselineoffset") + Text("带回家的好类扣手机端开发了健康的水立方") + .copyOption(CopyOptions.LocalDevice) + .draggable(true) + .fontSize(30) + .textShadow({ + radius: 10, + color: Color.Green, + offsetX: -10, + offsetY: 10 + }) + .fontWeight(900) + .margin(10) + .width(300) + .height(100) + .lineBreakStrategy(LineBreakStrategy.GREEDY) + + .focusable(true) + .textSelectable(TextSelectableMode.SELECTABLE_FOCUSABLE) + .decoration({ type: TextDecorationType.LineThrough, color: Color.Red }) + .id("text") + Divider() + + Divider() + Row() { + Button("读取剪贴板内容") + .onClick(() => { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + for (let i = 0; i < pasteData.getRecordCount(); i++) { + let record = pasteData.getRecord(i); + if (record.getData("openharmony.styled-string") == undefined) { + continue; + } + record.getData("openharmony.styled-string").then(async (value) => { + if (value instanceof ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(value); + this.msgList.push('剪贴板内容_转换:' + StyledString.toHtml(styledStringObject)); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + }); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + }) + .id("getData") + Button("重置") + .onClick(() => { + let mutableShow = new MutableStyledString(''); + this.controllerShow.setStyledString(mutableShow) + this.msgList = []; + }) + } + + Divider() + Text(undefined, { controller: this.controllerShow }).copyOption(CopyOptions.LocalDevice) + .margin({ top: 40 }) + Divider() + + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + } + .border({ width: 1, radius: 5 }) + .width('100%') + } + .height("90%") + .align(Alignment.Top) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0360.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0360.ets new file mode 100755 index 00000000..17b3c99e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0360.ets @@ -0,0 +1,320 @@ +import { image } from '@kit.ImageKit'; +import { LengthMetrics } from '@kit.ArkUI'; +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} + +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0360 { + @State imagePixelMap: image.PixelMap | undefined = undefined + @State msgList: Array = []; + @State permission_state: boolean = true; + mutableStr: MutableStyledString = new MutableStyledString(''); + controller: TextController = new TextController(); + controllerShow: TextController = new TextController(); + richController: RichEditorController = new RichEditorController(); + mutableStyledString1: MutableStyledString = new MutableStyledString("hello world", [{ + start: 0, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Pink }) + }, { + start: 4, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Orange }) + }, + { + start: 6, + length: 3, + styledKey: StyledStringKey.FONT, + styledValue: new TextStyle({ fontColor: Color.Blue }) + }, + ]); + + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + + build() { + Scroll() { + Column({ space: 5 }) { + Divider() + Text("Text组件设置baselineoffset") + Text("带回家的好类扣手机端开发了健康的水立方") + .copyOption(CopyOptions.LocalDevice) + .draggable(true) + .fontSize(30) + .textShadow({ + radius: 10, + color: Color.Green, + offsetX: -10, + offsetY: 10 + }) + .fontWeight(900) + .textAlign(TextAlign.Start) + .margin(10) + .width(300) + .height(100) + .textIndent(0) + .focusable(true) + .backgroundColor(Color.Gray) + .textSelectable(TextSelectableMode.SELECTABLE_FOCUSABLE) + .decoration({ type: TextDecorationType.LineThrough, color: Color.Red }) + .id("text") + Divider() + + + + + Divider() + Row() { + Button("读取剪贴板内容") + .onClick(() => { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + for (let i = 0; i < pasteData.getRecordCount(); i++) { + let record = pasteData.getRecord(i); + if (record.getData("openharmony.styled-string") == undefined) { + continue; + } + record.getData("openharmony.styled-string").then(async (value) => { + if (value instanceof ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(value); + this.msgList.push('剪贴板内容_转换:' + StyledString.toHtml(styledStringObject)); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + }); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + }) + .id("getData") + Button("重置") + .onClick(() => { + let mutableShow = new MutableStyledString(''); + this.controllerShow.setStyledString(mutableShow) + this.msgList = []; + }) + } + + Divider() + Text(undefined, { controller: this.controllerShow }).copyOption(CopyOptions.LocalDevice) + .margin({ top: 40 }) + Divider() + + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + } + .border({ width: 1, radius: 5 }) + .width('100%') + } + .height("90%") + .align(Alignment.Top) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0370.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0370.ets new file mode 100755 index 00000000..d1677127 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0370.ets @@ -0,0 +1,248 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0370 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + build() { + Column() { + Text('123') { + Span('Hello World') + .textBackgroundStyle({ radius: '10vp' }) + } + .id('UIComponentTextCopyAttributeReplacement0370') + .offset({ x: 10, y: 20 }) + .copyOption(CopyOptions.LocalDevice) + Divider().margin(20) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0380.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0380.ets new file mode 100755 index 00000000..57dc5dfc --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0380.ets @@ -0,0 +1,251 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import hilog from '@ohos.hilog'; +import { BusinessError } from '@ohos.base'; +import abilityAccessCtrl, { Permissions } from '@ohos.abilityAccessCtrl'; +import common from '@ohos.app.ability.common'; +import bundleManager from '@ohos.bundle.bundleManager'; +import pasteboard from '@ohos.pasteboard'; + +async function checkAccessToken(permission: Permissions): Promise { + let atManager: abilityAccessCtrl.AtManager = abilityAccessCtrl.createAtManager(); + let grantStatus: abilityAccessCtrl.GrantStatus = abilityAccessCtrl.GrantStatus.PERMISSION_DENIED; + // 获取应用程序的accessTokenID + let tokenId: number = 0; + try { + let bundleInfo: bundleManager.BundleInfo = + await bundleManager.getBundleInfoForSelf(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION); + let appInfo: bundleManager.ApplicationInfo = bundleInfo.appInfo; + tokenId = appInfo.accessTokenId; + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to get bundle info for self. Code is ${err.code}, message is ${err.message}`); + } + // 校验应用是否被授予权限 + try { + grantStatus = await atManager.checkAccessToken(tokenId, permission); + } catch (error) { + let err: BusinessError = error as BusinessError; + console.error(`Failed to check access token. Code is ${err.code}, message is ${err.message}`); + } + return grantStatus; +} +@Entry +@Component +struct UIComponentTextCopyAttributeReplacement0380 { + @State msgList: Array = []; + controllerShow: TextController = new TextController(); + @State permission_state: boolean = true; + reqPermissionsFromUser(permissions: Array): void { + let context = getContext(this) as common.UIAbilityContext; + let atManager = abilityAccessCtrl.createAtManager(); + // requestPermissionsFromUser会判断权限的授权状态来决定是否唤起弹窗 + atManager.requestPermissionsFromUser(context, permissions).then((data) => { + let grantStatus: Array = data.authResults; + let length: number = grantStatus.length; + for (let i = 0; i < length; i++) { + if (grantStatus[i] === 0) { + // 用户授权,可以继续访问目标操作 + this.permission_state = true; + this.msgList.push('申请权限成功'); + } else { + // 用户拒绝授权,提示用户必须授权才能访问当前页面的功能,并引导用户到系统设置中打开相应的权限 + this.permission_state = false; + this.msgList.push('申请权限失败'); + } + } + }).catch((err: String) => { + }) + } + + async onPageShow() { + const permissions: Array = ['ohos.permission.READ_PASTEBOARD']; + let grantStatus: abilityAccessCtrl.GrantStatus = await checkAccessToken(permissions[0]); + if (grantStatus === abilityAccessCtrl.GrantStatus.PERMISSION_GRANTED) { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + let text: string = pasteData.getPrimaryText(); + if (text != "") { + this.msgList.push('权限校验,可以读取剪贴板内容'); + } + }); + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `get oaid by promise catch error: ${err.code} ${err.message}`); + } + } else if (this.permission_state) { + // 申请权限 + this.reqPermissionsFromUser(permissions) + } + } + readPasteboardData() { + try { + let systemPasteboard: pasteboard.SystemPasteboard = pasteboard.getSystemPasteboard(); + systemPasteboard.getData((err: BusinessError, pasteData: pasteboard.PasteData) => { + if (err) { + console.error('Failed to get PasteData. Cause: ' + err.message); + return; + } + this.msgList.push('剪贴板内容_PrimaryText:' + pasteData.getPrimaryText()); + this.msgList.push('剪贴板内容_RecordCount:' + pasteData.getRecordCount()); + + for (let i = 0; i < pasteData.getRecordCount(); i++) { + this.readRecord(pasteData.getRecord(i)); + } + }) + } catch (err) { + hilog.error(0x0000, 'testTag', '%{public}s', `catch error: ${err.code} ${err.message}`); + } + } + + readRecord(record: pasteboard.PasteDataRecord) { + if (record.getData("openharmony.styled-string") == undefined) { + return; + } + record.getData("openharmony.styled-string").then((value) => { + if (value instanceof ArrayBuffer) { + this.readData(value); + } + }); + } + + async readData(data: ArrayBuffer) { + let styledStringObject = await StyledString.unmarshalling(data); + this.readStyledStringObject(styledStringObject); + let mutableShow = new MutableStyledString(''); + mutableShow.appendStyledString(styledStringObject) + this.controllerShow.setStyledString(mutableShow) + } + + readStyledStringObject(styledStringObject: StyledString) { + this.msgList.push('剪贴板内容_styledStringObject.length' + styledStringObject.length); + this.msgList.push('剪贴板内容_styledStringObject.getString' + styledStringObject.getString()); + console.info('result==='+JSON.stringify(styledStringObject)) + for (let i = 0; i < 1000; i++) { + this.readStyledSpan(styledStringObject.getStyles(0, styledStringObject.length, i)); + } + } + + readStyledSpan(spanStyleArray: Array) { + if (spanStyleArray == undefined) { + return; + } + console.info('result==='+JSON.stringify(spanStyleArray)) + for (let k = 0; k < spanStyleArray.length; k++) { + let spanStyle = spanStyleArray[k]; + this.msgList.push('剪贴板内容_spanStyle.start ' + spanStyle.start); + this.msgList.push('剪贴板内容_spanStyle.length ' + spanStyle.length); + this.msgList.push('剪贴板内容_spanStyle.styledKey ' + spanStyle.styledKey); + let value = spanStyle.styledValue; + if (value instanceof TextStyle) { + this.msgList.push('剪贴板内容_value.TextStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontColor?.toString() ' + value.fontColor?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontFamily?.toString() ' + value.fontFamily?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontSize?.toString() ' + value.fontSize?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontWeight?.toString() ' + value.fontWeight?.toString()); + this.msgList.push('剪贴板内容_value.TextStyle.fontStyle?.toString() ' + value.fontStyle?.toString()); + + } + if (value instanceof DecorationStyle) { + this.msgList.push('剪贴板内容_value.DecorationStyle.type?.toString() ' + value.type?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.color?.toString() ' + value.color?.toString()); + this.msgList.push('剪贴板内容_value.DecorationStyle.style?.toString() ' + value.style?.toString()); + } + if (value instanceof BaselineOffsetStyle) { + this.msgList.push('剪贴板内容_value.BaselineOffsetStyle.baselineOffset?.toString() ' + + value.baselineOffset?.toString()); + } + if (value instanceof LetterSpacingStyle) { + this.msgList.push('剪贴板内容_value.LetterSpacingStyle.letterSpacing?.toString() ' + + value.letterSpacing?.toString()); + } + if (value instanceof TextShadowStyle) { + this.msgList.push('剪贴板内容_value.TextShadowStyle.textShadow?.toString() ' + value.textShadow?.toString()); + } + if (value instanceof ImageAttachment) { + this.msgList.push('剪贴板内容_value.ImageAttachment.value?.toString() ' + value.value?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.size?.toString() ' + value.size?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.verticalAlign?.toString() ' + + value.verticalAlign?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.objectFit?.toString() ' + value.objectFit?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.margin?.toString() ' + + value.layoutStyle?.margin?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.padding?.toString() ' + + value.layoutStyle?.padding?.toString()); + this.msgList.push('剪贴板内容_value.ImageAttachment.borderRadius?.toString() ' + + value.layoutStyle?.borderRadius?.toString()); + } + if (value instanceof ParagraphStyle) { + this.msgList.push('剪贴板内容_value.ParagraphStyle.textAlign?.toString() ' + value.textAlign?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.textIndent?.toString() ' + value.textIndent?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.maxLines?.toString() ' + value.maxLines?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.overflow?.toString() ' + value.overflow?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.wordBreak?.toString() ' + value.wordBreak?.toString()); + this.msgList.push('剪贴板内容_value.ParagraphStyle.leadingMargin?.toString() ' + + value.leadingMargin?.toString()); + } + if (value instanceof LineHeightStyle) { + this.msgList.push('剪贴板内容_value.LineHeightStyle.lineHeight?.toString() ' + value.lineHeight?.toString()); + } + if (value instanceof UrlStyle) { + this.msgList.push('剪贴板内容_value.UrlStyle.url?.toString() ' + value.url?.toString()); + } + + if (value instanceof BackgroundColorStyle) { + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.color?.toString() ' + + value.textBackgroundStyle.color?.toString()); + this.msgList.push('剪贴板内容_value.BackgroundColorStyle.radius?.toString() ' + + value.textBackgroundStyle.radius?.toString()); + } + } + } + + build() { + Column() { + Text('123') { + ImageSpan('cat.jpg') + .width('57px') + .height('57px') + .margin(20) + Span('Hello World') + } + .id('UIComponentTextCopyAttributeReplacement0380') + .offset({x:10,y:20}) + .copyOption(CopyOptions.LocalDevice) + Divider().margin(20) + Row() { + Button("读取剪贴板内容") + .id('read') + .onClick(() => { + this.readPasteboardData(); + }) + } + Divider() + Text('剪切板获取内容:') + ForEach(this.msgList, (item: string) => { + Text(item) + .fontSize(12) + .width('90%') + .margin({ top: 5 }) + .copyOption(CopyOptions.LocalDevice) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0040.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0040.ets new file mode 100644 index 00000000..7c4432cd --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0040.ets @@ -0,0 +1,216 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextEditMenuOptions0040 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'Text:' + this.msg + @State taTxt: string = 'TextArea:' + this.msg + @State tiTxt: string = 'TextInput:' + this.msg + @State changeValue: string = 'search:' + this.msg + @State richEdTxt: string = 'RichEditor:' + this.msg + @State submitValue: string = '' + searchController: SearchController = new SearchController(); + textAreaController: TextAreaController = new TextAreaController() + textInputController: TextInputController = new TextInputController() + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + private editorMenuOptions: Array = + [{ icon: 'icon.png' }, { icon: 'cat.jpg' }, { icon: 'openeye.png' }, { icon: 'icon.png' }, { icon: 'openeye.png' }, + { icon: 'cat.jpg' }] + private expandedMenuOptions: Array = + [{ + startIcon: 'cat.jpg', content: '词典', action: () => { + console.log('click it>>'); + this.options.controller.closeSelectionMenu(); + } + }, { + startIcon: 'icon.png', content: '翻译', action: () => { + } + }, { + startIcon: 'openeye.png', content: '搜索', action: () => { + } + }] + private selectionMenuOptions: SelectionMenuOptions = { + editorMenuOptions: this.editorMenuOptions, + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + + onCreateMenu(menuItems: Array) { + let item1: TextMenuItem = { + content: 'custom1', + icon: 'icon.png', + id: TextMenuItemId.of('custom1'), + } + let item2: TextMenuItem = { + content: 'custom2', + id: TextMenuItemId.of('custom2'), + icon: 'cat.jpg', + } + menuItems.push(item1) + menuItems.unshift(item2) + return menuItems + } + + build() { + Column() { + Text(this.txt) + .id('textEditMenuOptions0040_tx') + .width('100%') + .margin(20) + .height('10%') + .fontSize(16) + .copyOption(CopyOptions.InApp) + .fontColor('#182431') + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + TextArea({ + text: this.taTxt, + placeholder: 'The text area can hold an unlimited amount of text. input your word...', + controller: this.textAreaController + }) + .id('textEditMenuOptions0040_txArea') + .width('90%') + .margin(10) + .height('20%') + .fontSize(16) + .fontColor('#182431') + .backgroundColor('#FFFFFF') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + TextInput({ + text: this.tiTxt, + controller: this.textInputController + }) + .id('textEditMenuOptions0040_txInput') + .margin(10) + .fontColor(Color.Blue) + .fontSize(20) + .width('100%') + .height('20%') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + Search({ value: 'It is Search', placeholder: 'Type to search...', controller: this.searchController }) + .id('textEditMenuOptions0040_search') + .searchButton('SEARCH') + .width('100%') + .height(50) + .backgroundColor('#F5F5F5') + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .textFont({ size: 14, weight: 400 }) + .margin(20) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0050.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0050.ets new file mode 100644 index 00000000..4725339c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0050.ets @@ -0,0 +1,214 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextEditMenuOptions0050 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'Text:' + this.msg + @State taTxt: string = 'TextArea:' + this.msg + @State tiTxt: string = 'TextInput:' + this.msg + @State changeValue: string = 'search:' + this.msg + @State richEdTxt: string = 'RichEditor:' + this.msg + @State submitValue: string = '' + searchController: SearchController = new SearchController(); + textAreaController: TextAreaController = new TextAreaController() + textInputController: TextInputController = new TextInputController() + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + private editorMenuOptions: Array = + [{ icon: 'icon.png' }, { icon: 'cat.jpg' }, { icon: 'openeye.png' }, { icon: 'icon.png' }, { icon: 'openeye.png' }, + { icon: 'cat.jpg' }] + private expandedMenuOptions: Array = + [{ + startIcon: 'cat.jpg', content: '词典', action: () => { + console.log('click it>>'); + this.options.controller.closeSelectionMenu(); + } + }, { + startIcon: 'icon.png', content: '翻译', action: () => { + } + }, { + startIcon: 'openeye.png', content: '搜索', action: () => { + } + }] + private selectionMenuOptions: SelectionMenuOptions = { + editorMenuOptions: this.editorMenuOptions, + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + + onCreateMenu(menuItems: Array) { + let item1: TextMenuItem = { + content: 'custom1', + id: TextMenuItemId.of('custom1') + } + let item2: TextMenuItem = { + content: 'custom2', + id: TextMenuItemId.of('custom2') + } + menuItems.push(item1) + menuItems.unshift(item2) + return menuItems + } + + build() { + Column() { + Text(this.txt) + .id('textEditMenuOptions0050_tx') + .width('100%') + .margin(20) + .height('10%') + .fontSize(16) + .copyOption(CopyOptions.InApp) + .fontColor('#182431') + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + TextArea({ + text: this.taTxt, + placeholder: 'The text area can hold an unlimited amount of text. input your word...', + controller: this.textAreaController + }) + .id('textEditMenuOptions0050_txArea') + .width('90%') + .margin(10) + .height('20%') + .fontSize(16) + .fontColor('#182431') + .backgroundColor('#FFFFFF') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + TextInput({ + text: this.tiTxt, + controller: this.textInputController + }) + .id('textEditMenuOptions0050_txInput') + .margin(10) + .fontColor(Color.Blue) + .fontSize(20) + .width('100%') + .height('20%') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + Search({ value: 'It is Search', placeholder: 'Type to search...', controller: this.searchController }) + .id('textEditMenuOptions0050_search') + .searchButton('SEARCH') + .width('100%') + .height(50) + .backgroundColor('#F5F5F5') + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .textFont({ size: 14, weight: 400 }) + .margin(20) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0060.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0060.ets new file mode 100644 index 00000000..6d088672 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0060.ets @@ -0,0 +1,264 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextEditMenuOptions0060 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'Text:' + this.msg + @State taTxt: string = 'TextArea:' + this.msg + @State tiTxt: string = 'TextInput:' + this.msg + @State changeValue: string = 'search:' + this.msg + @State richEdTxt: string = 'RichEditor:' + this.msg + @State submitValue: string = '' + searchController: SearchController = new SearchController(); + textAreaController: TextAreaController = new TextAreaController() + textInputController: TextInputController = new TextInputController() + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + private editorMenuOptions: Array = + [{ icon: 'icon.png' }, { icon: 'cat.jpg' }, { icon: 'openeye.png' }, { icon: 'icon.png' }, { icon: 'openeye.png' }, + { icon: 'cat.jpg' }] + private expandedMenuOptions: Array = + [{ + startIcon: 'cat.jpg', content: '词典', action: () => { + console.log('click it>>'); + this.options.controller.closeSelectionMenu(); + } + }, { + startIcon: 'icon.png', content: '翻译', action: () => { + } + }, { + startIcon: 'openeye.png', content: '搜索', action: () => { + } + }] + private selectionMenuOptions: SelectionMenuOptions = { + editorMenuOptions: this.editorMenuOptions, + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + + onCreateMenu(menuItems: Array) { + let item1: TextMenuItem = { + content: 'custom1', + icon: 'cat.jpg', + id: TextMenuItemId.of('custom1') + } + let item2: TextMenuItem = { + content: 'custom2', + icon: 'icon.png', + id: TextMenuItemId.of('custom2') + } + let item3: TextMenuItem = { + content: 'custom3', + icon: 'image2.png', + id: TextMenuItemId.of('custom3') + } + let item4: TextMenuItem = { + content: 'custom4', + icon: 'opensys.png', + id: TextMenuItemId.of('custom4') + } + let item5: TextMenuItem = { + content: 'custom5', + icon: 'icon.png', + id: TextMenuItemId.of('custom5') + } + let item6: TextMenuItem = { + content: 'custom6', + icon: 'cat.jpg', + id: TextMenuItemId.of('custom6') + } + let item7: TextMenuItem = { + content: 'custom7', + icon: 'icon.png', + id: TextMenuItemId.of('custom7') + } + let item8: TextMenuItem = { + content: 'custom8', + icon: 'cat.jpg', + id: TextMenuItemId.of('custom8') + } + let item9: TextMenuItem = { + content: 'custom9', + icon: 'icon.png', + id: TextMenuItemId.of('custom9') + } + let item10: TextMenuItem = { + content: 'custom10', + icon: 'cat.jpg', + id: TextMenuItemId.of('custom10') + } + menuItems.push(item1) + menuItems.push(item2) + menuItems.push(item3) + menuItems.push(item4) + menuItems.push(item5) + menuItems.push(item6) + menuItems.push(item7) + menuItems.push(item8) + menuItems.push(item9) + menuItems.push(item10) + return menuItems + } + + build() { + Column() { + Text(this.txt) + .id('textEditMenuOptions0060_tx') + .width('100%') + .margin(20) + .height('10%') + .fontSize(16) + .copyOption(CopyOptions.InApp) + .fontColor('#182431') + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + TextArea({ + text: this.taTxt, + placeholder: 'The text area can hold an unlimited amount of text. input your word...', + controller: this.textAreaController + }) + .id('textEditMenuOptions0060_txArea') + .width('90%') + .margin(10) + .height('20%') + .fontSize(16) + .fontColor('#182431') + .backgroundColor('#FFFFFF') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + TextInput({ + text: this.tiTxt, + controller: this.textInputController + }) + .id('textEditMenuOptions0060_txInput') + .margin(10) + .fontColor(Color.Blue) + .fontSize(20) + .width('100%') + .height('20%') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + Search({ value: 'It is Search', placeholder: 'Type to search...', controller: this.searchController }) + .id('textEditMenuOptions0060_search') + .searchButton('SEARCH') + .width('100%') + .height(50) + .backgroundColor('#F5F5F5') + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .textFont({ size: 14, weight: 400 }) + .margin(20) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0090.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0090.ets new file mode 100644 index 00000000..e4db34c0 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0090.ets @@ -0,0 +1,225 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextEditMenuOptions0090 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'Text:' + this.msg + @State taTxt: string = 'TextArea:' + this.msg + @State tiTxt: string = 'TextInput:' + this.msg + @State changeValue: string = 'search:' + this.msg + @State richEdTxt: string = 'RichEditor:' + this.msg + @State submitValue: string = '' + searchController: SearchController = new SearchController(); + textAreaController: TextAreaController = new TextAreaController() + textInputController: TextInputController = new TextInputController() + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + private editorMenuOptions: Array = + [{ icon: 'icon.png' }, { icon: 'cat.jpg' }, { icon: 'openeye.png' }, { icon: 'icon.png' }, { icon: 'openeye.png' }, + { icon: 'cat.jpg' }] + private expandedMenuOptions: Array = + [{ + startIcon: 'cat.jpg', content: '词典', action: () => { + console.log('click it>>'); + this.options.controller.closeSelectionMenu(); + } + }, { + startIcon: 'icon.png', content: '翻译', action: () => { + } + }, { + startIcon: 'openeye.png', content: '搜索', action: () => { + } + }] + private selectionMenuOptions: SelectionMenuOptions = { + editorMenuOptions: this.editorMenuOptions, + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + + onCreateMenu(menuItems: Array) { + menuItems.forEach((value, index) => { + // value.icon = 'opensys.png' + if (value.id.equals(TextMenuItemId.COPY)) { + value.content = "复制change" + } + if (value.id.equals(TextMenuItemId.SELECT_ALL)) { + value.content = "全选change" + } + }) + let item1: TextMenuItem = { + content: 'custom1', + icon: 'cat.jpg', + id: TextMenuItemId.of('custom1') + } + let item2: TextMenuItem = { + content: 'custom2', + icon: 'icon.png', + id: TextMenuItemId.of('custom2') + } + menuItems.push(item1) + menuItems.push(item2) + return menuItems + } + + build() { + Column() { + Text(this.txt) + .id('textEditMenuOptions0090_tx') + .width('100%') + .margin(20) + .height('10%') + .fontSize(16) + .copyOption(CopyOptions.InApp) + .fontColor('#182431') + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("不拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return false; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + TextArea({ + text: this.taTxt, + placeholder: 'The text area can hold an unlimited amount of text. input your word...', + controller: this.textAreaController + }) + .id('textEditMenuOptions0090_txArea') + .width('90%') + .margin(10) + .height('20%') + .fontSize(16) + .fontColor('#182431') + .backgroundColor('#FFFFFF') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + TextInput({ + text: this.tiTxt, + controller: this.textInputController + }) + .id('textEditMenuOptions0090_txInput') + .margin(10) + .fontColor(Color.Blue) + .fontSize(20) + .width('100%') + .height('20%') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + Search({ value: 'It is Search', placeholder: 'Type to search...', controller: this.searchController }) + .id('textEditMenuOptions0090_search') + .searchButton('SEARCH') + .width('100%') + .height(50) + .backgroundColor('#F5F5F5') + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .textFont({ size: 14, weight: 400 }) + .margin(20) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0110.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0110.ets new file mode 100644 index 00000000..ffbd861e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0110.ets @@ -0,0 +1,260 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextEditMenuOptions0110 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'Text:' + this.msg + @State taTxt: string = 'TextArea:' + this.msg + @State tiTxt: string = 'TextInput:' + this.msg + @State changeValue: string = 'search:' + this.msg + @State richEdTxt: string = 'RichEditor:' + this.msg + @State submitValue: string = '' + searchController: SearchController = new SearchController(); + textAreaController: TextAreaController = new TextAreaController() + textInputController: TextInputController = new TextInputController() + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + private editorMenuOptions: Array = + [{ icon: 'icon.png' }, { icon: 'cat.jpg' }, { icon: 'openeye.png' }, { icon: 'icon.png' }, { icon: 'openeye.png' }, + { icon: 'cat.jpg' }] + private expandedMenuOptions: Array = + [{ + startIcon: 'cat.jpg', content: '词典', action: () => { + console.log('click it>>'); + this.options.controller.closeSelectionMenu(); + } + }, { + startIcon: 'icon.png', content: '翻译', action: () => { + } + }, { + startIcon: 'openeye.png', content: '搜索', action: () => { + } + }] + private selectionMenuOptions: SelectionMenuOptions = { + editorMenuOptions: this.editorMenuOptions, + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + + onCreateMenu(menuItems: Array) { + menuItems.forEach((value, index) => { + // value.icon = 'opensys.png' + if (value.id.equals(TextMenuItemId.COPY)) { + value.content = "复制change" + } + if (value.id.equals(TextMenuItemId.CUT)) { + value.content = "剪切change" + } + if (value.id.equals(TextMenuItemId.SELECT_ALL)) { + value.content = "全选change" + } + }) + let item1: TextMenuItem = { + content: 'custom1', + icon: 'cat.jpg', + id: TextMenuItemId.of('custom1') + } + let item2: TextMenuItem = { + content: 'custom2', + id: TextMenuItemId.of('custom2') + } + let item3: TextMenuItem = { + content: 'custom3', + icon: 'image2.png', + id: TextMenuItemId.of('custom3') + } + let item4: TextMenuItem = { + content: 'custom4', + id: TextMenuItemId.of('custom4') + } + let item5: TextMenuItem = { + content: 'custom5', + icon: 'icon.png', + id: TextMenuItemId.of('custom5') + } + let item6: TextMenuItem = { + content: 'custom6', + id: TextMenuItemId.of('custom6') + } + let item7: TextMenuItem = { + content: 'custom7', + icon: 'icon.png', + id: TextMenuItemId.of('custom7') + } + let item8: TextMenuItem = { + content: 'custom8', + icon: 'cat.jpg', + id: TextMenuItemId.of('custom8') + } + menuItems.push(item1) + menuItems.push(item2) + menuItems.push(item3) + menuItems.push(item4) + menuItems.push(item5) + menuItems.unshift(item6) + menuItems.unshift(item7) + return menuItems + } + + build() { + Column() { + Text(this.txt) + .id('textEditMenuOptions0110_tx') + .width('100%') + .margin(20) + .height('10%') + .fontSize(16) + .copyOption(CopyOptions.InApp) + .fontColor('#182431') + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + TextArea({ + text: this.taTxt, + placeholder: 'The text area can hold an unlimited amount of text. input your word...', + controller: this.textAreaController + }) + .id('textEditMenuOptions0110_txArea') + .width('90%') + .margin(10) + .height('20%') + .fontSize(16) + .fontColor('#182431') + .backgroundColor('#FFFFFF') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + TextInput({ + text: this.tiTxt, + controller: this.textInputController + }) + .id('textEditMenuOptions0110_txInput') + .margin(10) + .fontColor(Color.Blue) + .fontSize(20) + .width('100%') + .height('20%') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + Search({ value: 'It is Search', placeholder: 'Type to search...', controller: this.searchController }) + .id('textEditMenuOptions0110_search') + .searchButton('SEARCH') + .width('100%') + .height(50) + .backgroundColor('#F5F5F5') + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .textFont({ size: 14, weight: 400 }) + .margin(20) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0150.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0150.ets new file mode 100644 index 00000000..ba2b77dc --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0150.ets @@ -0,0 +1,217 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextEditMenuOptions0150 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'Text:' + this.msg + @State taTxt: string = 'TextArea:' + this.msg + @State tiTxt: string = 'TextInput:' + this.msg + @State changeValue: string = 'search:' + this.msg + @State richEdTxt: string = 'RichEditor:' + this.msg + @State submitValue: string = '' + searchController: SearchController = new SearchController(); + textAreaController: TextAreaController = new TextAreaController() + textInputController: TextInputController = new TextInputController() + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + private editorMenuOptions: Array = + [{ icon: 'icon.png' }, { icon: 'cat.jpg' }, { icon: 'openeye.png' }, { icon: 'icon.png' }, { icon: 'openeye.png' }, + { icon: 'cat.jpg' }] + private expandedMenuOptions: Array = + [{ + startIcon: 'cat.jpg', content: '词典', action: () => { + console.log('click it>>'); + this.options.controller.closeSelectionMenu(); + } + }, { + startIcon: 'icon.png', content: '翻译', action: () => { + } + }, { + startIcon: 'openeye.png', content: '搜索', action: () => { + } + }] + private selectionMenuOptions: SelectionMenuOptions = { + editorMenuOptions: this.editorMenuOptions, + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + + onCreateMenu(menuItems: Array) { + menuItems.forEach((value, index) => { + // value.icon = 'opensys.png' + if (value.id.equals(TextMenuItemId.COPY)) { + value.content = "复制change" + } + if (value.id.equals(TextMenuItemId.CUT)) { + value.content = "剪切change" + } + if (value.id.equals(TextMenuItemId.SELECT_ALL)) { + value.content = "全选change" + } + }) + menuItems.splice(0,5) + return menuItems + } + + build() { + Column() { + Text(this.txt) + .id('textEditMenuOptions0150_tx') + .width('100%') + .margin(20) + .height('10%') + .fontSize(16) + .copyOption(CopyOptions.InApp) + .fontColor('#182431') + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + TextArea({ + text: this.taTxt, + placeholder: 'The text area can hold an unlimited amount of text. input your word...', + controller: this.textAreaController + }) + .id('textEditMenuOptions0150_txArea') + .width('90%') + .margin(10) + .height('20%') + .fontSize(16) + .fontColor('#182431') + .backgroundColor('#FFFFFF') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + TextInput({ + text: this.tiTxt, + controller: this.textInputController + }) + .id('textEditMenuOptions0150_txInput') + .margin(10) + .fontColor(Color.Blue) + .fontSize(20) + .width('100%') + .height('20%') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + Search({ value: 'It is Search', placeholder: 'Type to search...', controller: this.searchController }) + .id('textEditMenuOptions0150_search') + .searchButton('SEARCH') + .width('100%') + .height(50) + .backgroundColor('#F5F5F5') + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .textFont({ size: 14, weight: 400 }) + .margin(20) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0160.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0160.ets new file mode 100644 index 00000000..9fbdd580 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0160.ets @@ -0,0 +1,192 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextEditMenuOptions0160 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'Text:' + this.msg + @State taTxt: string = 'TextArea:' + this.msg + @State tiTxt: string = 'TextInput:' + this.msg + @State changeValue: string = 'search:' + this.msg + @State richEdTxt: string = 'RichEditor:' + this.msg + @State submitValue: string = '' + searchController: SearchController = new SearchController(); + textAreaController: TextAreaController = new TextAreaController() + textInputController: TextInputController = new TextInputController() + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + private editorMenuOptions: Array = + [{ icon: 'icon.png' }, { icon: 'cat.jpg' }, { icon: 'openeye.png' }, { icon: 'icon.png' }, { icon: 'openeye.png' }, + { icon: 'cat.jpg' }] + private expandedMenuOptions: Array = + [{ + startIcon: 'cat.jpg', content: '词典', action: () => { + console.log('click it>>'); + this.options.controller.closeSelectionMenu(); + } + }, { + startIcon: 'icon.png', content: '翻译', action: () => { + } + }, { + startIcon: 'openeye.png', content: '搜索', action: () => { + } + }] + private selectionMenuOptions: SelectionMenuOptions = { + editorMenuOptions: this.editorMenuOptions, + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + + onCreateMenu(menuItems: Array) { + let item1: TextMenuItem = { + content: 'custom1', + icon: 'cat.jpg', + id: TextMenuItemId.of('custom1') + } + let item2: TextMenuItem = { + content: 'custom2', + icon: 'icon.png', + id: TextMenuItemId.of('custom2') + } + menuItems.push(item1) + menuItems.push(item2) + return menuItems + } + + build() { + Column() { + Text(this.txt) + .id('textEditMenuOptions0160_tx') + .width('100%') + .margin(20) + .height('10%') + .fontSize(16) + .copyOption(CopyOptions.InApp) + .fontColor('#182431') + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return true; + } + }) + + TextArea({ + text: this.taTxt, + placeholder: 'The text area can hold an unlimited amount of text. input your word...', + controller: this.textAreaController + }) + .id('textEditMenuOptions0160_txArea') + .width('90%') + .margin(10) + .height('20%') + .fontSize(16) + .fontColor('#182431') + .backgroundColor('#FFFFFF') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return true; + } + }) + + TextInput({ + text: this.tiTxt, + controller: this.textInputController + }) + .id('textEditMenuOptions0160_txInput') + .margin(10) + .fontColor(Color.Blue) + .fontSize(20) + .width('100%') + .height('20%') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + Search({ value: 'It is Search', placeholder: 'Type to search...', controller: this.searchController }) + .id('textEditMenuOptions0160_search') + .searchButton('SEARCH') + .width('100%') + .height(50) + .backgroundColor('#F5F5F5') + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .textFont({ size: 14, weight: 400 }) + .margin(20) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0170.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0170.ets new file mode 100644 index 00000000..b5da2e02 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0170.ets @@ -0,0 +1,259 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextEditMenuOptions0170 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'Text:' + this.msg + @State taTxt: string = 'TextArea:' + this.msg + @State tiTxt: string = 'TextInput:' + this.msg + @State changeValue: string = 'search:' + this.msg + @State richEdTxt: string = 'RichEditor:' + this.msg + @State submitValue: string = '' + searchController: SearchController = new SearchController(); + textAreaController: TextAreaController = new TextAreaController() + textInputController: TextInputController = new TextInputController() + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + private editorMenuOptions: Array = + [{ icon: 'icon.png' }, { icon: 'cat.jpg' }, { icon: 'openeye.png' }, { icon: 'icon.png' }, { icon: 'openeye.png' }, + { icon: 'cat.jpg' }] + private expandedMenuOptions: Array = + [{ + startIcon: 'cat.jpg', content: '词典', action: () => { + console.log('click it>>'); + this.options.controller.closeSelectionMenu(); + } + }, { + startIcon: 'icon.png', content: '翻译', action: () => { + } + }, { + startIcon: 'openeye.png', content: '搜索', action: () => { + } + }] + private selectionMenuOptions: SelectionMenuOptions = { + editorMenuOptions: this.editorMenuOptions, + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + + onCreateMenu(menuItems: Array) { + menuItems.forEach((value, index) => { + // value.icon = 'opensys.png' + if (value.id.equals(TextMenuItemId.COPY)) { + value.content = "复制change" + } + if (value.id.equals(TextMenuItemId.CUT)) { + value.content = "剪切change" + } + if (value.id.equals(TextMenuItemId.SELECT_ALL)) { + value.content = "全选change" + } + }) + let item1: TextMenuItem = { + content: 'custom1custom1custom1custom1custom1', + icon: 'cat.jpg', + id: TextMenuItemId.of('custom1') + } + let item2: TextMenuItem = { + content: 'custom2', + id: TextMenuItemId.of('custom2') + } + let item3: TextMenuItem = { + content: 'custom3', + icon: 'image2.png', + id: TextMenuItemId.of('custom3') + } + let item4: TextMenuItem = { + content: 'custom4', + id: TextMenuItemId.of('custom4') + } + let item5: TextMenuItem = { + content: 'custom5', + icon: 'icon.png', + id: TextMenuItemId.of('custom5') + } + let item6: TextMenuItem = { + content: 'custom6', + id: TextMenuItemId.of('custom6') + } + let item7: TextMenuItem = { + content: 'custom7custom7custom7', + icon: 'icon.png', + id: TextMenuItemId.of('custom7') + } + let item8: TextMenuItem = { + content: 'custom8custom8custom8', + icon: 'cat.jpg', + id: TextMenuItemId.of('custom8') + } + menuItems.unshift(item1) + menuItems.push(item2) + menuItems.push(item3) + menuItems.push(item4) + // menuItems.unshift(item7) + // menuItems.unshift(item8) + return menuItems + } + + build() { + Column() { + Text(this.txt) + .id('textEditMenuOptions0170_tx') + .width('100%') + .margin(20) + .height('10%') + .fontSize(16) + .copyOption(CopyOptions.InApp) + .fontColor('#182431') + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + TextArea({ + text: this.taTxt, + placeholder: 'The text area can hold an unlimited amount of text. input your word...', + controller: this.textAreaController + }) + .id('textEditMenuOptions0170_txArea') + .width('90%') + .margin(10) + .height('20%') + .fontSize(16) + .fontColor('#182431') + .backgroundColor('#FFFFFF') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + TextInput({ + text: this.tiTxt, + controller: this.textInputController + }) + .id('textEditMenuOptions0170_txInput') + .margin(10) + .fontColor(Color.Blue) + .fontSize(20) + .width('100%') + .height('20%') + .onContentScroll((totalOffsetX: number, totalOffsetY: number) => { + console.log(`onContentScroll>>>`); + }) + .onTextSelectionChange((selectionStart: number, selectionEnd: number) => { + console.log(`onTextSelectionChange>>>`); + }) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + Search({ value: 'It is Search', placeholder: 'Type to search...', controller: this.searchController }) + .id('textEditMenuOptions0170_search') + .searchButton('SEARCH') + .width('100%') + .height(50) + .backgroundColor('#F5F5F5') + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .textFont({ size: 14, weight: 400 }) + .margin(20) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0180.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0180.ets new file mode 100644 index 00000000..e93e2af9 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0180.ets @@ -0,0 +1,213 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextEditMenuOptions0180 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'Text:' + this.msg + @State taTxt: string = 'TextArea:' + this.msg + @State tiTxt: string = 'TextInput:' + this.msg + @State changeValue: string = 'search:' + this.msg + @State richEdTxt: string = 'RichEditor:' + this.msg + @State submitValue: string = '' + searchController: SearchController = new SearchController(); + textAreaController: TextAreaController = new TextAreaController() + textInputController: TextInputController = new TextInputController() + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + private editorMenuOptions: Array = + [{ icon: 'icon.png' }, { icon: 'cat.jpg' }, { icon: 'openeye.png' }, { icon: 'icon.png' }, { icon: 'openeye.png' }, + { icon: 'cat.jpg' }] + private expandedMenuOptions: Array = + [{ + startIcon: 'cat.jpg', content: '词典', action: () => { + console.log('click it>>'); + this.options.controller.closeSelectionMenu(); + } + }, { + startIcon: 'icon.png', content: '翻译', action: () => { + } + }, { + startIcon: 'openeye.png', content: '搜索', action: () => { + } + }] + private selectionMenuOptions: SelectionMenuOptions = { + editorMenuOptions: this.editorMenuOptions, + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + + onCreateMenu(menuItems: Array) { + menuItems.forEach((value, index) => { + // value.icon = 'opensys.png' + if (value.id.equals(TextMenuItemId.COPY)) { + value.content = "复制change" + } + if (value.id.equals(TextMenuItemId.CUT)) { + value.content = "剪切change" + } + if (value.id.equals(TextMenuItemId.SELECT_ALL)) { + value.content = "全选change" + } + }) + let item1: TextMenuItem = { + content: 'custom1', + icon: 'cat.jpg', + id: TextMenuItemId.of('custom1') + } + let item2: TextMenuItem = { + content: 'custom2', + id: TextMenuItemId.of('custom2') + } + let item3: TextMenuItem = { + content: 'custom3', + icon: 'image2.png', + id: TextMenuItemId.of('custom3') + } + let item4: TextMenuItem = { + content: 'custom4', + id: TextMenuItemId.of('custom4') + } + let item5: TextMenuItem = { + content: 'custom5', + icon: 'icon.png', + id: TextMenuItemId.of('custom5') + } + let item6: TextMenuItem = { + content: 'custom6', + id: TextMenuItemId.of('custom6') + } + let item7: TextMenuItem = { + content: 'custom7', + icon: 'icon.png', + id: TextMenuItemId.of('custom7') + } + let item8: TextMenuItem = { + content: 'custom8', + icon: 'cat.jpg', + id: TextMenuItemId.of('custom8') + } + menuItems.push(item1) + menuItems.push(item2) + menuItems.push(item3) + menuItems.push(item4) + menuItems.push(item5) + menuItems.unshift(item6) + menuItems.unshift(item7) + return menuItems + } + + build() { + Column() { + Text(this.txt) + .id('textEditMenuOptions0180_tx') + .width('100%') + .margin(20) + .height('10%') + .fontSize(16) + .copyOption(CopyOptions.InApp) + .fontColor('#182431') + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return false; + } + }) + + TextArea({ + text: this.taTxt, + placeholder: 'The text area can hold an unlimited amount of text. input your word...', + controller: this.textAreaController + }) + .id('textEditMenuOptions0180_txArea') + .width('90%') + .margin(10) + .height('20%') + .fontSize(16) + .fontColor('#182431') + .backgroundColor('#FFFFFF') + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return false; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + + TextInput({ + text: this.tiTxt, + controller: this.textInputController + }) + .id('textEditMenuOptions0180_txInput') + .margin(10) + .fontColor(Color.Blue) + .fontSize(20) + .width('100%') + .height('20%') + .style(TextContentStyle.INLINE) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return false; + } + }) + + Search({ value: 'It is Search', placeholder: 'Type to search...', controller: this.searchController }) + .id('textEditMenuOptions0180_search') + .searchButton('SEARCH') + .width('100%') + .height(50) + .backgroundColor('#F5F5F5') + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .textFont({ size: 14, weight: 400 }) + .margin(20) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return false; + } + }) + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0190.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0190.ets new file mode 100644 index 00000000..439b5a51 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0190.ets @@ -0,0 +1,179 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; + +@Entry +@Component +struct UIComponentTextEditMenuOptions0190 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'Text:' + this.msg + @State taTxt: string = 'TextArea:' + this.msg + @State tiTxt: string = 'TextInput:' + this.msg + @State changeValue: string = 'search:' + this.msg + @State richEdTxt: string = 'RichEditor:' + this.msg + @State submitValue: string = '' + searchController: SearchController = new SearchController(); + textAreaController: TextAreaController = new TextAreaController() + textInputController: TextInputController = new TextInputController() + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + private editorMenuOptions: Array = + [{ icon: 'icon.png' }, { icon: 'cat.jpg' }, { icon: 'openeye.png' }, { icon: 'icon.png' }, { icon: 'openeye.png' }, + { icon: 'cat.jpg' }] + private expandedMenuOptions: Array = + [{ + startIcon: 'cat.jpg', content: '词典', action: () => { + console.log('click it>>'); + this.options.controller.closeSelectionMenu(); + } + }, { + startIcon: 'icon.png', content: '翻译', action: () => { + } + }, { + startIcon: 'openeye.png', content: '搜索', action: () => { + } + }] + private selectionMenuOptions: SelectionMenuOptions = { + editorMenuOptions: this.editorMenuOptions, + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + + onCreateMenu(menuItems: Array) { + menuItems.forEach((value, index) => { + // value.icon = 'opensys.png' + if (value.id.equals(TextMenuItemId.COPY)) { + value.content = "复制change" + } + if (value.id.equals(TextMenuItemId.CUT)) { + value.content = "剪切change" + } + if (value.id.equals(TextMenuItemId.SELECT_ALL)) { + value.content = "全选change" + } + }) + let item1: TextMenuItem = { + content: 'custom1custom1custom1custom1custom1', + icon: 'cat.jpg', + id: TextMenuItemId.of('custom1') + } + let item2: TextMenuItem = { + content: 'custom2custom2custom2custom2custom2custom2', + id: TextMenuItemId.of('custom2') + } + let item3: TextMenuItem = { + content: 'custom3', + icon: 'image2.png', + id: TextMenuItemId.of('custom3') + } + let item4: TextMenuItem = { + content: 'custom4', + id: TextMenuItemId.of('custom4') + } + menuItems.push(item1) + menuItems.push(item2) + menuItems.unshift(item3) + menuItems.unshift(item4) + return menuItems + } + + build() { + Column() { + Text(this.txt) + .id('textEditMenuOptions0190_tx') + .width('100%') + .margin(20) + .height('10%') + .fontSize(16) + .copyOption(CopyOptions.InApp) + .fontColor('#182431') + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return false; + } + }) + + TextArea({ + text: this.taTxt, + placeholder: 'The text area can hold an unlimited amount of text. input your word...', + controller: this.textAreaController + }) + .id('textEditMenuOptions0190_txArea') + .width('90%') + .margin(10) + .height('20%') + .fontSize(16) + .fontColor('#182431') + .backgroundColor('#FFFFFF') + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return false; + } + }) + + TextInput({ + text: this.tiTxt, + controller: this.textInputController + }) + .id('textEditMenuOptions0190_txInput') + .margin(10) + .fontColor(Color.Blue) + .fontSize(20) + .width('100%') + .height('20%') + .type(InputType.Password) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return false; + } + }) + + Search({ value: 'It is Search', placeholder: 'Type to search...', controller: this.searchController }) + .id('textEditMenuOptions0190_search') + .searchButton('SEARCH') + .width('100%') + .height(50) + .backgroundColor('#F5F5F5') + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .textFont({ size: 14, weight: 400 }) + .margin(20) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return false; + } + }) + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0260.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0260.ets new file mode 100644 index 00000000..784ec7f1 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0260.ets @@ -0,0 +1,88 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextEditMenuOptions0260 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'Text:' + this.msg + textController:TextController = new TextController() + + onCreateMenu(menuItems: Array) { + let item1: TextMenuItem = { + content: 'custom1', + icon: 'icon.png', + id: TextMenuItemId.of('custom1'), + } + let item2: TextMenuItem = { + content: 'custom2', + id: TextMenuItemId.of('custom2'), + icon: 'cat.jpg', + } + menuItems.push(item1) + menuItems.unshift(item2) + return menuItems + } + + @Builder + TextCustomMenu() { + Column() { + Menu() { + MenuItemGroup() { + MenuItem({ startIcon: 'cat.jpg', content: "Menu 1", labelInfo: "" }) + .onClick((event) => { + this.textController.closeSelectionMenu(); + }) + MenuItem({ startIcon: 'icon.png', content: "Menu 2", labelInfo: "" }) + MenuItem({ startIcon: 'openeye.png', content: "Menu 3", labelInfo: "" }) + } + } + } + } + build() { + Column() { + Text(this.txt) + .id('textEditMenuOptions0260_tx') + .width('100%') + .margin(20) + .height('10%') + .fontSize(16) + .copyOption(CopyOptions.InApp) + .fontColor('#182431') + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + .bindSelectionMenu(TextSpanType.TEXT, this.TextCustomMenu(), TextResponseType.LONG_PRESS) + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface001.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface001.ets new file mode 100644 index 00000000..cb7b9aa3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface001.ets @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextInputDeleteCallbackInterface001 { + @State text: string = '这是测试文本.'; + @State insertValue: string = ''; + @State insertOffset: number = -1; + + build() { + Row() { + Column() { + TextInput({ text: this.text }) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.insertOffset = info.insertOffset; + return false; + }).key('UIComponentTextInputDeleteCallbackInterface001_textInput_001') + Text("insertValue:" + this.insertValue + " insertOffset:" + this.insertOffset) + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0010.ets new file mode 100644 index 00000000..65f0a3f8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0010.ets @@ -0,0 +1,59 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextInputDeleteCallbackInterface0010 { + @State insertValue: string = ""; + @State deleteValue: string = ""; + @State insertOffset: number = 0; + @State deleteOffset: number = 0; + @State deleteDirection: number = 0; + @State callback_order: string = ''; + + build() { + Row() { + Column() { + TextInput({ text: "这是测试文本" }) + .height(60) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.callback_order = this.callback_order + '>onWillInsert'; + return false; + }) + .onDidInsert((info: InsertValue) => { + this.insertOffset = info.insertOffset; + this.callback_order = this.callback_order + '>onDidInsert'; + }) + .onWillDelete((info: DeleteValue) => { + this.deleteValue = info.deleteValue; + this.callback_order = this.callback_order + '>onWillDelete'; + return false; + }) + .onDidDelete((info: DeleteValue) => { + this.deleteOffset = info.deleteOffset; + this.deleteDirection = info.direction; + this.callback_order = this.callback_order + '>onDidDelete'; + }) + .key('UIComponentTextInputDeleteCallbackInterface0010_textInput_001') + Text("insertValue:" + this.insertValue + " insertOffset:" + this.insertOffset).height(30) + Text("deleteValue:" + this.deleteValue + " deleteOffset:" + this.deleteOffset).height(30) + Text("deleteDirection:" + this.deleteDirection).height(30) + Text("callback order:" + this.callback_order).height(30) + + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0011.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0011.ets new file mode 100644 index 00000000..4d4f518b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0011.ets @@ -0,0 +1,68 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextInputDeleteCallbackInterface0011 { + @State insertValue: string = ""; + @State deleteValue: string = ""; + @State insertOffset: number = 0; + @State deleteOffset: number = 0; + @State deleteDirection: number = 0; + @State callback_order: string = ''; + @State indent: number = 20; + @State inputType: number = InputType.Normal; + + build() { + Row() { + Column() { + TextInput({ text: "这是测试文本,数字:12345794561423" }) + .height(60) + .textIndent(this.indent) + .type(this.inputType) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.callback_order = this.callback_order + '>onWillInsert'; + return true; + }) + .onDidInsert((info: InsertValue) => { + this.insertOffset = info.insertOffset; + this.callback_order = this.callback_order + '>onDidInsert'; + }) + .onWillDelete((info: DeleteValue) => { + this.deleteValue = info.deleteValue; + this.callback_order = this.callback_order + '>onWillDelete'; + return true; + }) + .onDidDelete((info: DeleteValue) => { + this.deleteOffset = info.deleteOffset; + this.deleteDirection = info.direction; + this.callback_order = this.callback_order + '>onDidDelete'; + }) + .key('UIComponentTextInputDeleteCallbackInterface0011_textInput_001') + Text("insertValue:" + this.insertValue + " insertOffset:" + this.insertOffset).height(30) + Text("deleteValue:" + this.deleteValue + " deleteOffset:" + this.deleteOffset).height(30) + Text("deleteDirection:" + this.deleteDirection).height(30) + Text("callback order:" + this.callback_order).height(30) + Button("change indent") + .margin({ top: 20 }).onClick(() => { + this.indent = 40; + this.inputType = InputType.Number; + }).key('UIComponentTextInputDeleteCallbackInterface0011_button_001') + + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0012.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0012.ets new file mode 100644 index 00000000..a3adbb5f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0012.ets @@ -0,0 +1,67 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextInputDeleteCallbackInterface0012 { + @State insertValue: string = ""; + @State deleteValue: string = ""; + @State insertOffset: number = 0; + @State deleteOffset: number = 0; + @State deleteDirection: number = 0; + @State callback_order: string = ''; + @State flow: number = TextOverflow.None; + @State inputStyle: number = TextInputStyle.Default; + + build() { + Row() { + Column() { + TextInput({ text: "这是测试文本,数字:12345794561423,这里使用长文本测试,158566221125302,this is test Text" }) + .height(60) + .textOverflow(this.flow) + .style(this.inputStyle) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.callback_order = this.callback_order + '>onWillInsert'; + return true; + }) + .onDidInsert((info: InsertValue) => { + this.insertOffset = info.insertOffset; + this.callback_order = this.callback_order + '>onDidInsert'; + }) + .onWillDelete((info: DeleteValue) => { + this.deleteValue = info.deleteValue; + this.callback_order = this.callback_order + '>onWillDelete'; + return true; + }) + .onDidDelete((info: DeleteValue) => { + this.deleteOffset = info.deleteOffset; + this.deleteDirection = info.direction; + this.callback_order = this.callback_order + '>onDidDelete'; + }) + .key('UIComponentTextInputDeleteCallbackInterface0012_textInput_001') + Text("insertValue:" + this.insertValue + " insertOffset:" + this.insertOffset).height(30) + Text("deleteValue:" + this.deleteValue + " deleteOffset:" + this.deleteOffset).height(30) + Text("deleteDirection:" + this.deleteDirection).height(30) + Text("callback order:" + this.callback_order).height(30) + Button("change indent").margin({ top: 20 }).onClick(() => { + this.flow = TextOverflow.Ellipsis; + this.inputStyle = TextInputStyle.Inline; + }).key('UIComponentTextInputDeleteCallbackInterface0012_button_001') + + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0013.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0013.ets new file mode 100644 index 00000000..555533b0 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0013.ets @@ -0,0 +1,62 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextInputDeleteCallbackInterface0013 { + @State insertValue: string = ""; + @State deleteValue: string = ""; + @State insertOffset: number = 0; + @State deleteOffset: number = 0; + @State deleteDirection: number = 0; + @State callback_order: string = ''; + @State flow: number = TextOverflow.None; + @State inputStyle: number = TextInputStyle.Default; + + build() { + Row() { + Column() { + TextInput({ placeholder: "这是测试文本,This is test Text AcV" }) + .height(60) + .inputFilter('[A-Z]') + .style(this.inputStyle) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.callback_order = this.callback_order + '>onWillInsert'; + return true; + }) + .onDidInsert((info: InsertValue) => { + this.insertOffset = info.insertOffset; + this.callback_order = this.callback_order + '>onDidInsert'; + }) + .onWillDelete((info: DeleteValue) => { + this.deleteValue = info.deleteValue; + this.callback_order = this.callback_order + '>onWillDelete'; + return true; + }) + .onDidDelete((info: DeleteValue) => { + this.deleteOffset = info.deleteOffset; + this.deleteDirection = info.direction; + this.callback_order = this.callback_order + '>onDidDelete'; + }) + .key('UIComponentTextInputDeleteCallbackInterface0013_textInput_001') + Text("insertValue:" + this.insertValue + " insertOffset:" + this.insertOffset).height(30) + Text("deleteValue:" + this.deleteValue + " deleteOffset:" + this.deleteOffset).height(30) + Text("deleteDirection:" + this.deleteDirection).height(30) + Text("callback order:" + this.callback_order).height(30) + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0014.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0014.ets new file mode 100644 index 00000000..e76ceee9 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0014.ets @@ -0,0 +1,69 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextInputDeleteCallbackInterface0014 { + @State insertValue: string = ""; + @State insertOffset: number = 0; + @State insertValue_did: string = ""; + @State insertOffset_did: number = 0; + @State deleteOffset: number = 0; + @State deleteDirection: number = 0; + @State callback_order: string = ''; + @State count: number = 0; + + build() { + Row() { + Column() { + TextArea({ text: "这是测试文本\n" }) + .height(60) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.insertOffset = info.insertOffset; + if (info.insertValue == "\n") { + this.count++; + if (this.count >= 3) { + return false; + } + return true; + } else { + this.count = 0; + return true; + } + }) + .onDidInsert((info: InsertValue) => { + this.insertOffset_did = info.insertOffset; + this.insertValue_did = info.insertValue; + this.callback_order = this.callback_order + '>onDidInsert'; + }) + .onWillDelete((info: DeleteValue) => { + this.callback_order = this.callback_order + '>onWillDelete'; + return true; + }) + .onDidDelete((info: DeleteValue) => { + this.deleteOffset = info.deleteOffset; + this.deleteDirection = info.direction; + this.callback_order = this.callback_order + '>onDidDelete'; + }) + .key('UIComponentTextInputDeleteCallbackInterface0014_textInput_001') + Text("将要插入的位置:" + this.insertOffset + " 插入的值是:" + this.insertValue).height(30) + Text("已插入的位置:" + this.insertOffset_did + " 插入的值是:" + this.insertValue_did).height(30) + Text("deleteDirection:" + this.deleteDirection).height(30) + Text("callback order:" + this.callback_order).height(30) + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0015.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0015.ets new file mode 100644 index 00000000..db1416e6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0015.ets @@ -0,0 +1,67 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { TextInputModifier } from '@ohos.arkui.modifier' +import promptAction from '@ohos.promptAction'; + +class MyTextInputModifier implements AttributeModifier { + insertValue: string = ""; + deleteValue: string = ""; + insertOffset: number = 0; + deleteOffset: number = 0; + deleteDirection: number = 0; + callback_order: string = ''; + didinsertValue: string = ''; + + applyNormalAttribute(instance: TextInputAttribute): void { + instance.onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + promptAction.showToast({ + message: 'onWillInsert value = ' + info.insertValue, + duration: 2000, + }) + return true; + }) + .onDidInsert((info: InsertValue) => { + this.insertOffset = info.insertOffset; + this.didinsertValue = info.insertValue; + this.callback_order = this.callback_order + '>onDidInsert'; + }) + .onWillDelete((info: DeleteValue) => { + this.deleteValue = info.deleteValue; + this.callback_order = this.callback_order + '>onWillDelete'; + return true; + }) + .onDidDelete((info: DeleteValue) => { + this.deleteOffset = info.deleteOffset; + this.deleteDirection = info.direction; + this.callback_order = this.callback_order + '>onDidDelete'; + }) + } +} + +@Entry +@Component +struct UIComponentTextInputDeleteCallbackInterface0015 { + @State textValue: string = ''; + @State modifier: MyTextInputModifier = new MyTextInputModifier(); + + build() { + Column() { + TextInput({ placeholder: 'www.' }).attributeModifier(this.modifier) + .key('UIComponentTextInputDeleteCallbackInterface0015_textInput_001') + }.width('100%').margin({ top: 5 }) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface002.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface002.ets new file mode 100644 index 00000000..9daa7b29 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface002.ets @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextInputDeleteCallbackInterface002 { + @State text: string = '这是测试文本.'; + @State insertValue: string = ''; + @State insertOffset: number = -1; + + build() { + Row() { + Column() { + TextInput({ text: this.text }) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.insertOffset = info.insertOffset; + return true; + }).key('UIComponentTextInputDeleteCallbackInterface002_textInput_001') + Text("insertValue:" + this.insertValue + " insertOffset:" + this.insertOffset) + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface003.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface003.ets new file mode 100644 index 00000000..3104730f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface003.ets @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextInputDeleteCallbackInterface003 { + @State text: string = '这是测试文本.'; + @State insertValue: string = ''; + @State insertOffset: number = -1; + + build() { + Row() { + Column() { + TextInput({ text: this.text }) + .onDidInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.insertOffset = info.insertOffset; + }).key('UIComponentTextInputDeleteCallbackInterface003_textInput_001') + Text("insertValue:" + this.insertValue + " insertOffset:" + this.insertOffset) + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface004.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface004.ets new file mode 100644 index 00000000..3d1d9f3f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface004.ets @@ -0,0 +1,39 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextInputDeleteCallbackInterface004 { + @State text: string = '这是测试文本'; + @State deleteValue: string = ''; + @State deleteOffset: number = -1; + @State deleteDirection: number = 0 + + build() { + Row() { + Column() { + TextInput({ text: this.text }) + .onWillDelete((info: DeleteValue) => { + this.deleteValue = info.deleteValue; + this.deleteOffset = info.deleteOffset; + this.deleteDirection = info.direction; + return true; + }).key('UIComponentTextInputDeleteCallbackInterface004_textInput_001') + Text("deleteValue:" + this.deleteValue + " deleteOffset:" + this.deleteOffset + " direction:" + + this.deleteDirection) + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface005.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface005.ets new file mode 100644 index 00000000..bb3b646f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface005.ets @@ -0,0 +1,39 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextInputDeleteCallbackInterface005 { + @State text: string = '这是测试文本'; + @State deleteValue: string = ''; + @State deleteOffset: number = -1; + @State deleteDirection: number = 0 + + build() { + Row() { + Column() { + TextInput({ text: this.text }) + .onWillDelete((info: DeleteValue) => { + this.deleteValue = info.deleteValue; + this.deleteOffset = info.deleteOffset; + this.deleteDirection = info.direction; + return false; + }).key('UIComponentTextInputDeleteCallbackInterface005_textInput_001') + Text("deleteValue:" + this.deleteValue + " deleteOffset:" + this.deleteOffset + " direction:" + + this.deleteDirection) + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface006.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface006.ets new file mode 100644 index 00000000..9705b427 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface006.ets @@ -0,0 +1,38 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextInputDeleteCallbackInterface006 { + @State text: string = '这是测试文本'; + @State deleteValue: string = ''; + @State deleteOffset: number = -1; + @State deleteDirection: number = 0 + + build() { + Row() { + Column() { + TextInput({ text: this.text }) + .onDidDelete((info: DeleteValue) => { + this.deleteValue = info.deleteValue; + this.deleteOffset = info.deleteOffset; + this.deleteDirection = info.direction; + }).key('UIComponentTextInputDeleteCallbackInterface006_textInput_001') + Text("deleteValue:" + this.deleteValue + " deleteOffset:" + this.deleteOffset + " direction:" + + this.deleteDirection) + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface007.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface007.ets new file mode 100644 index 00000000..0e013d3e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface007.ets @@ -0,0 +1,63 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextInputDeleteCallbackInterface007 { + @State insertValue: string = ""; + @State deleteValue: string = ""; + @State insertOffset: number = 0; + @State deleteOffset: number = 0; + @State deleteDirection: number = 0; + @State callback_order: string = ''; + @State didinsertValue: string = ''; + + build() { + Row() { + Column() { + TextInput({ text: "这是测试文本" }) + .height(60) + .draggable(true) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.callback_order = this.callback_order + '>onWillInsert'; + return true; + }) + .onDidInsert((info: InsertValue) => { + this.insertOffset = info.insertOffset; + this.didinsertValue = info.insertValue; + this.callback_order = this.callback_order + '>onDidInsert'; + }) + .onWillDelete((info: DeleteValue) => { + this.deleteValue = info.deleteValue; + this.callback_order = this.callback_order + '>onWillDelete'; + return true; + }) + .onDidDelete((info: DeleteValue) => { + this.deleteOffset = info.deleteOffset; + this.deleteDirection = info.direction; + this.callback_order = this.callback_order + '>onDidDelete'; + }) + .key('UIComponentTextInputDeleteCallbackInterface007_textInput_001') + Text("insertValue:" + this.insertValue + " insertOffset:" + this.insertOffset).height(30) + Text("Did insertValue:" + this.didinsertValue).height(30) + Text("deleteValue:" + this.deleteValue + " deleteOffset:" + this.deleteOffset).height(30) + Text("deleteDirection:" + this.deleteDirection).height(30) + Text("callback order:" + this.callback_order).height(30) + + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface008.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface008.ets new file mode 100644 index 00000000..ce439127 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface008.ets @@ -0,0 +1,59 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextInputDeleteCallbackInterface008 { + @State insertValue: string = ""; + @State deleteValue: string = ""; + @State insertOffset: number = 0; + @State deleteOffset: number = 0; + @State deleteDirection: number = 0; + @State callback_order: string = ''; + + build() { + Row() { + Column() { + TextInput({ text: "这是测试文本" }) + .height(60) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.callback_order = this.callback_order + '>onWillInsert'; + return false; + }) + .onDidInsert((info: InsertValue) => { + this.insertOffset = info.insertOffset; + this.callback_order = this.callback_order + '>onDidInsert'; + }) + .onWillDelete((info: DeleteValue) => { + this.deleteValue = info.deleteValue; + this.callback_order = this.callback_order + '>onWillDelete'; + return true; + }) + .onDidDelete((info: DeleteValue) => { + this.deleteOffset = info.deleteOffset; + this.deleteDirection = info.direction; + this.callback_order = this.callback_order + '>onDidDelete'; + }) + .key('UIComponentTextInputDeleteCallbackInterface008_textInput_001') + Text("insertValue:" + this.insertValue + " insertOffset:" + this.insertOffset).height(30) + Text("deleteValue:" + this.deleteValue + " deleteOffset:" + this.deleteOffset).height(30) + Text("deleteDirection:" + this.deleteDirection).height(30) + Text("callback order:" + this.callback_order).height(30) + + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface009.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface009.ets new file mode 100644 index 00000000..2bb158b5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface009.ets @@ -0,0 +1,59 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextInputDeleteCallbackInterface009 { + @State insertValue: string = ""; + @State deleteValue: string = ""; + @State insertOffset: number = 0; + @State deleteOffset: number = 0; + @State deleteDirection: number = 0; + @State callback_order: string = ''; + + build() { + Row() { + Column() { + TextInput({ text: "这是测试文本" }) + .height(60) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.callback_order = this.callback_order + '>onWillInsert'; + return true; + }) + .onDidInsert((info: InsertValue) => { + this.insertOffset = info.insertOffset; + this.callback_order = this.callback_order + '>onDidInsert'; + }) + .onWillDelete((info: DeleteValue) => { + this.deleteValue = info.deleteValue; + this.callback_order = this.callback_order + '>onWillDelete'; + return false; + }) + .onDidDelete((info: DeleteValue) => { + this.deleteOffset = info.deleteOffset; + this.deleteDirection = info.direction; + this.callback_order = this.callback_order + '>onDidDelete'; + }) + .key('UIComponentTextInputDeleteCallbackInterface009_textInput_001') + Text("insertValue:" + this.insertValue + " insertOffset:" + this.insertOffset).height(30) + Text("deleteValue:" + this.deleteValue + " deleteOffset:" + this.deleteOffset).height(30) + Text("deleteDirection:" + this.deleteDirection).height(30) + Text("callback order:" + this.callback_order).height(30) + + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface001.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface001.ets new file mode 100644 index 00000000..29a5e92e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface001.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentTextRefactorAdjustMentInterface001 { + @State text: string = '这是个长的测试文本,This is long test text.'; + + build() { + Row() { + Column() { + TextInput({ text: this.text }) + .fontSize(20) + .margin({ top: 20 }) + .key('UIComponentTextRefactorAdjustMentInterface001_textInput_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface002.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface002.ets new file mode 100644 index 00000000..23488bc6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface002.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentTextRefactorAdjustMentInterface002 { + @State text: string = 'abc'; + + build() { + Row() { + Column() { + TextInput({ text: this.text }) + .fontSize(20) + .style(TextInputStyle.Inline) + .margin({ top: 20 }) + .key('UIComponentTextRefactorAdjustMentInterface002_textInput_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface003.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface003.ets new file mode 100644 index 00000000..23010f09 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface003.ets @@ -0,0 +1,37 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentTextRefactorAdjustMentInterface003 { + @State text: string = '这是个长的测试文本,This is long test text.'; + + build() { + Row() { + Column() { + TextInput({ text: this.text }) + .fontSize(20) + .margin({ top: 20 }) + .key('UIComponentTextRefactorAdjustMentInterface003_textInput_001') + TextInput({ text: 'This is test text,This is test textThis is' }) + .fontSize(20) + .draggable(true) + .margin({ top: 20 }) + .key('UIComponentTextRefactorAdjustMentInterface003_textInput_002') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface004.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface004.ets new file mode 100644 index 00000000..3de6f1d8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface004.ets @@ -0,0 +1,126 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentTextRefactorAdjustMentInterface004 { + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller }; + private start: number = 0; + private end: number = 1; + @State message: string = "[-1, -1]" + @State content: string = "" + + build() { + Column() { + Row() { + Button("删除[0,1]").onClick(() => { + this.controller.deleteSpans({ + start: this.start, + end: this.end + }) + this.start = -1; + this.end = -1; + this.message = "[" + this.start + ", " + this.end + "]" + }).key('UIComponentTextRefactorAdjustMentInterface004_button_001') + Button("删除[1,2]").onClick(() => { + this.controller.deleteSpans({ + start: 1, + end: 2 + }) + }).key('UIComponentTextRefactorAdjustMentInterface004_button_002') + Button("删除[100,101]").onClick(() => { + this.controller.deleteSpans({ + start: 100, + end: 101 + }) + }).key('UIComponentTextRefactorAdjustMentInterface004_button_003') + } + .width("100%") + .height("10%") + + Column() { + Row() { + Button("删除[2,1]").onClick(() => { + this.controller.deleteSpans({ + start: 2, + end: 1 + }) + }).key('UIComponentTextRefactorAdjustMentInterface004_button_004') + Button("删除All").onClick(() => { + this.controller.deleteSpans({ + start: -1, + end: -1 + }) + }).key('UIComponentTextRefactorAdjustMentInterface004_button_005') + } + } + .width("100%") + .height("10%") + + Column() { + RichEditor(this.options) + .onReady(() => { + this.controller.addTextSpan("012345", + { + style: + { + fontColor: Color.Orange, + fontSize: 30 + } + }) + this.controller.addSymbolSpan($r("sys.symbol.ohos_trash"), + { + style: + { + fontSize: 30 + } + }) + this.controller.addImageSpan($r("app.media.icon"), + { + imageStyle: + { + size: ["57px", "57px"] + } + }) + this.controller.addTextSpan("56789", + { + style: + { + fontColor: Color.Black, + fontSize: 30 + } + }) + }) + .placeholder("input...", { + fontColor: Color.Gray, + font: { + size: 16, + weight: FontWeight.Normal, + family: "HarmonyOS Sans", + style: FontStyle.Normal + } + }) + .borderWidth(1) + .borderColor(Color.Green) + .width("100%") + .height("30%") + } + .width("100%") + .height("70%") + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface005.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface005.ets new file mode 100644 index 00000000..b648803e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface005.ets @@ -0,0 +1,53 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextRefactorAdjustMentInterface005 { + controller: RichEditorController = new RichEditorController(); + private spanParagraphs: RichEditorParagraphResult[] = []; + @State log: string = ''; + + build() { + Column() { + RichEditor({ controller: this.controller }) + .onReady(() => { + this.controller.addTextSpan("0123456789\n", { + style: { + fontColor: Color.Pink, + fontSize: "32", + }, + paragraphStyle: { + textAlign: TextAlign.Start, + leadingMargin: 16 + } + }) + this.controller.addTextSpan("0123456789") + }) + .width("80%") + .height("30%") + .border({ width: 1, radius: 5 }) + .draggable(false) + + Column({ space: 5 }) { + Text(this.log) + Button("getParagraphs").onClick(() => { + this.spanParagraphs = this.controller.getParagraphs({ start: 0, end: 1 }); + this.log = "RichEditor getParagraphs:" + JSON.stringify(this.spanParagraphs); + }).key('UIComponentTextRefactorAdjustMentInterface005_button_01') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface006.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface006.ets new file mode 100644 index 00000000..ed876104 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface006.ets @@ -0,0 +1,109 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentTextRefactorAdjustMentInterface006 { + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller }; + private start: number = 0; + private end: number = 1; + @State message: string = "[-1, -1]" + @State content: string = "" + + build() { + Column() { + Row() { + Button("选中[0,1]").onClick(() => { + this.controller.setSelection(0, 1) + }).key('UIComponentTextRefactorAdjustMentInterface006_button_001') + Button("选中[1,2]").onClick(() => { + this.controller.setSelection(1, 2) + }).key('UIComponentTextRefactorAdjustMentInterface006_button_002') + Button("选中[100,101]").onClick(() => { + this.controller.setSelection(100, 101) + }).key('UIComponentTextRefactorAdjustMentInterface006_button_003') + } + .width("100%") + .height("10%") + + Column() { + Row() { + Button("选中[2,1]").onClick(() => { + this.controller.setSelection(2, 1) + }).key('UIComponentTextRefactorAdjustMentInterface006_button_003') + Button("选中All").onClick(() => { + this.controller.setSelection(-1, -1) + }).key('UIComponentTextRefactorAdjustMentInterface006_button_005') + } + } + .width("100%") + .height("10%") + + Column() { + RichEditor(this.options) + .key('UIComponentTextRefactorAdjustMentInterface006_richEditor_001') + .onReady(() => { + this.controller.addTextSpan("012345", + { + style: + { + fontColor: Color.Orange, + fontSize: 30 + } + }) + this.controller.addSymbolSpan($r("sys.symbol.ohos_trash"), + { + style: + { + fontSize: 30 + } + }) + this.controller.addImageSpan($r("app.media.icon"), + { + imageStyle: + { + size: ["57px", "57px"] + } + }) + this.controller.addTextSpan("56789", + { + style: + { + fontColor: Color.Black, + fontSize: 30 + } + }) + }) + .placeholder("input...", { + fontColor: Color.Gray, + font: { + size: 16, + weight: FontWeight.Normal, + family: "HarmonyOS Sans", + style: FontStyle.Normal + } + }) + .borderWidth(1) + .borderColor(Color.Green) + .width("100%") + .height("30%") + } + .width("100%") + .height("70%") + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface007.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface007.ets new file mode 100644 index 00000000..a655b659 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface007.ets @@ -0,0 +1,131 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { LengthMetrics } from '@kit.ArkUI'; + + +@Entry +@Component +struct UIComponentTextRefactorAdjustMentInterface007 { + + @State message: string = "[-1, -1]"; + @State content: string = ""; + fontStyle1: TextStyle = new TextStyle({ fontColor: Color.Blue }); + fontStyle2: TextStyle = new TextStyle({ + fontWeight: FontWeight.Bolder, + fontFamily: 'Arial', + fontColor: Color.Orange, + fontSize: LengthMetrics.vp(30), + fontStyle: FontStyle.Italic + }) + controller1: RichEditorController = new RichEditorController() + options1: RichEditorOptions = { controller: this.controller1 }; + // 创建属性字符串对象 + mutableStyledString: MutableStyledString = new MutableStyledString("初始属性字符串", + [{ + start: 0, + length: 5, + styledKey: StyledStringKey.FONT, + styledValue: this.fontStyle1 + }]); + styledString: StyledString = new StyledString("插入属性字符串", + [{ + start: 2, + length: 4, + styledKey: StyledStringKey.FONT, + styledValue: this.fontStyle2 + }]); + controller: RichEditorStyledStringController = new RichEditorStyledStringController(); + options: RichEditorStyledStringOptions = { controller: this.controller }; + + build() { + Column() { + Row() { + Button("toStyled[0,1]").onClick(() => { + this.controller.setStyledString(this.controller1.toStyledString({ start: 0, end: 1 })) + }).key('UIComponentTextRefactorAdjustMentInterface007_button_001') + Button("toStyled[1,2]").onClick(() => { + this.controller.setStyledString(this.controller1.toStyledString({ start: 1, end: 2 })) + }).key('UIComponentTextRefactorAdjustMentInterface007_button_002') + Button("toStyled[100,101]").onClick(() => { + this.controller.setStyledString(this.controller1.toStyledString({ start: 100, end: 101 })) + }).key('UIComponentTextRefactorAdjustMentInterface007_button_003') + } + .width("100%") + .height("10%") + + Column() { + Row() { + Button("toStyled[2,1]").onClick(() => { + this.controller.setStyledString(this.controller1.toStyledString({ start: 2, end: 1 })) + }).key('UIComponentTextRefactorAdjustMentInterface007_button_003') + Button("toStyled[-1,-1]").onClick(() => { + this.controller.setStyledString(this.controller1.toStyledString({ start: -1, end: -1 })) + }).key('UIComponentTextRefactorAdjustMentInterface007_button_005') + } + } + .width("100%") + .height("10%") + + Column() { + RichEditor(this.options) + .onReady(() => { + // 设定组件展示的属性字符串 + this.controller.setStyledString(this.mutableStyledString); + }) + .height("20%") + .width("100%") + RichEditor(this.options1) + .onReady(() => { + this.controller1.addTextSpan("把这些文字转换成属性字符串") + this.controller1.addSymbolSpan($r("sys.symbol.ohos_trash"), + { + style: + { + fontSize: 30 + } + }) + this.controller1.addImageSpan($r("app.media.icon"), + { + imageStyle: + { + size: ["57px", "57px"] + } + }) + this.controller1.addTextSpan("56789", + { + style: + { + fontColor: Color.Black, + fontSize: 30 + } + }) + }) + .placeholder("input...", { + fontColor: Color.Gray, + font: { + size: 16, + weight: FontWeight.Normal, + family: "HarmonyOS Sans", + style: FontStyle.Normal + } + }) + .width("100%") + .height("30%") + } + .width("100%") + .height("70%") + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface001.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface001.ets new file mode 100644 index 00000000..439e4af3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface001.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentTextSearchActionInterface001 { + @State value: string = '这是预置文本.' + + build() { + Row() { + Column() { + Search({ value: this.value }) + .key('UIComponentTextSearchActionInterface001_search_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface002.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface002.ets new file mode 100644 index 00000000..6cb62ad5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface002.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +@Entry +@Component +struct UIComponentTextSearchActionInterface002 { + @State value: string = '这是预置文本.this is test text.' + + build() { + Row() { + Column() { + Search({ value: this.value }) + .key('UIComponentTextSearchActionInterface002_search_001') + Search({ value: this.value }) + .key('UIComponentTextSearchActionInterface002_search_002') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface003.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface003.ets new file mode 100644 index 00000000..83714a40 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface003.ets @@ -0,0 +1,47 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchActionInterface003 { + controller: SearchController = new SearchController() + @State inputValue: string = "" + + @Builder CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Search({ controller: this.controller, value: this.inputValue}) + .customKeyboard(this.CustomKeyboardBuilder()).margin(10).border({ width: 1 }) + .key('UIComponentTextSearchActionInterface003_search_001') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface001.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface001.ets new file mode 100644 index 00000000..6ac9a688 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface001.ets @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface001 { + @State placeholder: string = 'This is placeholder text.' + + build() { + Row() { + Scroll() { + Column() { + Search({ placeholder: this.placeholder + ' top' }).layoutWeight(1) + .key('UIComponentTextSearchInterface001_textInput_001') + Search({ placeholder: this.placeholder + ' center' }).layoutWeight(1) + .key('UIComponentTextSearchInterface001_textInput_002') + Search({ placeholder: this.placeholder + ' end' }).layoutWeight(1) + .key('UIComponentTextSearchInterface001_textInput_003') + } + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0010.ets new file mode 100644 index 00000000..af7bc8a6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0010.ets @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface0010 { + @State placeholder: string = 'This is placeholder text.' + @State enable: boolean = true; + + build() { + Row() { + Column() { + Search({ placeholder: this.placeholder }) + .enabled(this.enable) + .key('UIComponentTextSearchInterface0010_search_001') + + Button('change fontSize ').onClick(() => { + this.enable = false; + }).key('UIComponentTextSearchInterface0010_button_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0011.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0011.ets new file mode 100644 index 00000000..7dc1e388 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0011.ets @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface0011 { + @State placeholder: string = '这是预置文本.'; + @State dirType: number = Direction.Auto; + + build() { + Row() { + Column() { + Search({ placeholder: this.placeholder }) + .direction(this.dirType) + .key('UIComponentTextSearchInterface0011_search_001') + + Button('change Direction').onClick(() => { + this.dirType = Direction.Rtl; + }).key('UIComponentTextSearchInterface0011_button_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0012.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0012.ets new file mode 100644 index 00000000..15ec82c0 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0012.ets @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface0012 { + @State value: string = '这是预置文本.' + + build() { + Row() { + Column() { + Search({ value: this.value }) + .key('UIComponentTextSearchInterface0012_search_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0013.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0013.ets new file mode 100644 index 00000000..dc7786ea --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0013.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface0013 { + @State placeholder: string = '这是预置文本.'; + + build() { + Row() { + Column() { + Search({ placeholder: this.placeholder }) + .caretStyle({ + width: 10, + color: '#ffff0066' + }) + .key('UIComponentTextSearchInterface0013_search_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0014.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0014.ets new file mode 100644 index 00000000..94fa84d3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0014.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface0014 { + @State placeholder: string = '这是预置文本.'; + + build() { + Row() { + Column() { + Search({ placeholder: this.placeholder }) + .caretStyle({ + width: 'icon.png', + color: '#ffff0066' + }) + .key('UIComponentTextSearchInterface0014_search_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface002.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface002.ets new file mode 100644 index 00000000..3b646c74 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface002.ets @@ -0,0 +1,60 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface002 { + @State placeholder: string = 'This is placeholder text.' + @State textSize: number = 15; + + build() { + Row() { + Column() { + Search({ value: ' vp' }) + .searchIcon({ + src: 'icon.png', + size: '10vp' + }) + .textFont({ size: this.textSize }) + .key('UIComponentTextSearchInterface002_textInput_001') + Search({ value: ' px' }) + .searchIcon({ + src: 'icon.png', + size: '10px' + }) + .textFont({ size: this.textSize }) + .key('UIComponentTextSearchInterface002_textInput_002') + Search({ value: ' fp' }) + .searchIcon({ + src: 'icon.png', + size: '10fp' + }) + .textFont({ size: this.textSize }) + .key('UIComponentTextSearchInterface002_textInput_003') + Search({ value: this.placeholder }) + .searchIcon({ + src: 'icon.png', + size: 10 + }) + .textFont({ size: this.textSize }) + .key('UIComponentTextSearchInterface002_textInput_004') + + Button('change fontSize').onClick(() => { + this.textSize = 30; + }).key('UIComponentTextSearchInterface002_button_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0020.ets new file mode 100644 index 00000000..6a184a79 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0020.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface0020 { + @State placeholder: string = '这是提示文本'; + + build() { + Row() { + Column() { + Search({ placeholder: this.placeholder }) + .width('50%') + .copyOption(CopyOptions.None) + .id('SearchUIComponentTextSearchInterface0020') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface003.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface003.ets new file mode 100644 index 00000000..89511c82 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface003.ets @@ -0,0 +1,45 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface003 { + @State placeholder: string = 'This is placeholder text.' + @State index: number = 0; + @State icon: string = 'icon.png'; + + build() { + Row() { + Column() { + Search({ placeholder: 'set searchIcon' }) + .searchIcon({ + src: this.icon, + size: '20vp' + }) + .key('UIComponentTextSearchInterface003_textInput_001') + + Button('change icon').onClick(() => { + this.index = this.index + 1; + if (this.index == 1) { + this.icon = ''; + } else if (this.index == 2) { + this.index = 0; + this.icon = 'icon.png'; + } + }).key('UIComponentTextSearchInterface003_button_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0030.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0030.ets new file mode 100644 index 00000000..ef72f7f7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0030.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface0030 { + @State placeholder: string = '这是提示文本.'; + + build() { + Row() { + Column() { + Search({ placeholder: this.placeholder }) + .caretStyle({ + }) + .id('UIComponentTextSearchInterface0030') + } + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface004.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface004.ets new file mode 100644 index 00000000..da602d4a --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface004.ets @@ -0,0 +1,47 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface004 { + @State placeholder: string = 'This is placeholder text.' + @State index: number = 0; + @State icon: string = 'icon.png'; + + build() { + Row() { + Column() { + Search({ placeholder: 'set cancelButton' }) + .cancelButton({ + style: CancelButtonStyle.CONSTANT, + icon: { + src: this.icon + } + }) + .key('UIComponentTextSearchInterface004_textInput_001') + + Button('change icon').onClick(() => { + this.index = this.index + 1; + if (this.index == 1) { + this.icon = ''; + } else if (this.index == 2) { + this.index = 0; + this.icon = 'icon.png'; + } + }).key('UIComponentTextSearchInterface004_button_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0040.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0040.ets new file mode 100644 index 00000000..bce32fd5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0040.ets @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface0040 { + @State placeholder: string = '这是提示文本.'; + + build() { + Row() { + Column() { + Search({ placeholder: this.placeholder,value:'12345' }) + .id('UIComponentTextSearchInterface0040') + } + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface005.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface005.ets new file mode 100644 index 00000000..476da3a5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface005.ets @@ -0,0 +1,44 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface005 { + @State placeholder: string = 'This is placeholder text.' + @State index: number = 0; + @State icon: string = 'icon.png'; + + build() { + Row() { + Column() { + Search({ placeholder: 'set cancelButton' }) + .cancelButton({ + style: CancelButtonStyle.CONSTANT, + icon: { + src: this.icon + } + }) + .searchIcon({ + src: this.icon + }) + .key('UIComponentTextSearchInterface005_textInput_001') + + Button('change icon = null ').onClick(() => { + this.icon = ''; + }).key('UIComponentTextSearchInterface005_button_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface006.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface006.ets new file mode 100644 index 00000000..1ec68701 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface006.ets @@ -0,0 +1,48 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface006 { + @State placeholder: string = 'This is placeholder text.' + @State textSize: number = 15; + @State icon: string = 'icon.png'; + + build() { + Row() { + Column() { + Search({ placeholder: 'set cancelButton' }) + .cancelButton({ + style: CancelButtonStyle.CONSTANT, + icon: { + src: this.icon, + size: '20fp' + } + }) + .searchIcon({ + src: this.icon, + size: '20fp' + + }) + .textFont({ size: this.textSize }) + .key('UIComponentTextSearchInterface006_search_001') + + Button('change fontSize ').onClick(() => { + this.textSize = 30; + }).key('UIComponentTextSearchInterface006_button_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface007.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface007.ets new file mode 100644 index 00000000..88d1992b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface007.ets @@ -0,0 +1,50 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface007 { + @State placeholder: string = 'This is placeholder text.' + @State textSize: number = 15; + @State weight: number = 1; + @State icon: string = 'icon.png'; + + build() { + Row() { + Column() { + Search({ placeholder: 'set cancelButton' }) + .cancelButton({ + style: CancelButtonStyle.CONSTANT, + icon: { + src: this.icon, + size: '20fp' + } + }) + .searchIcon({ + src: this.icon, + size: '20fp' + + }) + .textFont({ size: this.textSize, weight: this.weight }) + .key('UIComponentTextSearchInterface007_search_001') + + Button('change weight ').onClick(() => { + // this.textSize = 30; + this.weight = 400; + }).key('UIComponentTextSearchInterface007_button_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface008.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface008.ets new file mode 100644 index 00000000..58ab33df --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface008.ets @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface008 { + @State placeholder: string = 'This is placeholder text.' + @State textSize: number = 30; + @State weight: number = 1; + @State icon: string = 'icon.png'; + + build() { + Row() { + Column() { + Search({ placeholder: this.placeholder }) + .cancelButton({ + style:CancelButtonStyle.CONSTANT + }) + .textFont({ size: this.textSize, weight: this.weight }) + .key('UIComponentTextSearchInterface008_search_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface009.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface009.ets new file mode 100644 index 00000000..e68d7feb --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface009.ets @@ -0,0 +1,44 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface009 { + @State placeholder: string = 'This is placeholder text.' + @State iconSize: number = 15; + + build() { + Row() { + Column() { + Search({ placeholder: 'set cancelButton' }) + .cancelButton({ + style: CancelButtonStyle.CONSTANT, + icon: { + size: this.iconSize + } + }) + .searchIcon({ + size: this.iconSize + + }) + .key('UIComponentTextSearchInterface009_search_001') + + Button('change fontSize ').onClick(() => { + this.iconSize = 100; + }).key('UIComponentTextSearchInterface009_button_001') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0370.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0370.ets new file mode 100644 index 00000000..bc189f46 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0370.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface0370 { + @State placeholder: string = '这是提示文本.'; + + build() { + Row() { + Column() { + Search({ placeholder: this.placeholder }) + .caretStyle({ + color: getContext().resourceManager.getColorSync($r('app.color.colorRed')) + }) + .id('UIComponentTextSearchInterface0370') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0390.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0390.ets new file mode 100644 index 00000000..45982d40 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0390.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface0390 { + @State placeholder: string = '这是提示文本.'; + + build() { + Row() { + Column() { + Search({ placeholder: this.placeholder }) + .caretStyle({ + color: 0xff0000 + }) + .id('UIComponentTextSearchInterface0390') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0400.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0400.ets new file mode 100644 index 00000000..08a30b07 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0400.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface0400 { + @State placeholder: string = '这是提示文本.'; + + build() { + Row() { + Column() { + Search({ placeholder: this.placeholder }) + .caretStyle({ + color: Color.Pink + }) + .id('UIComponentTextSearchInterface0400') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0410.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0410.ets new file mode 100644 index 00000000..75ee5f7d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0410.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface0410 { + @State placeholder: string = '这是提示文本.'; + + build() { + Row() { + Column() { + Search({ placeholder: this.placeholder }) + .caretStyle({ + color: 'rgba(0,0,255)' + }) + .id('UIComponentTextSearchInterface0410') + } + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0420.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0420.ets new file mode 100644 index 00000000..c0af2376 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0420.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface0420 { + @State placeholder: string = '这是提示文本.'; + + build() { + Row() { + Column() { + Search({ placeholder: this.placeholder }) + .caretStyle({ + color: 'rgba(0,255,0,0)' + }) + .id('UIComponentTextSearchInterface0420') + } + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0430.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0430.ets new file mode 100644 index 00000000..f627f591 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0430.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface0430 { + @State placeholder: string = '这是提示文本.'; + + build() { + Row() { + Column() { + Search({ placeholder: this.placeholder }) + .caretStyle({ + width:-10 + }) + .id('UIComponentTextSearchInterface0430') + } + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0530.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0530.ets new file mode 100644 index 00000000..b73c5677 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0530.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface0530 { + @State placeholder: string = '这是提示文本'; + + build() { + Row() { + Column() { + Search({ placeholder: this.placeholder }) + .width('50%') + .copyOption(CopyOptions.None) + .id('SearchUIComponentTextSearchInterface0530') + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Interface200.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Interface200.ets new file mode 100755 index 00000000..bc97e3c1 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Interface200.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface_Interface200 { + controller: SearchController = new SearchController(); + @State placeholder: string = 'This is test text.'; + + build() { + Column() { + Button('change carePotion=0').onClick(() => { + this.controller.caretPosition(0); + }).key('Interface200_button_001') + Search({ value: this.placeholder, controller: this.controller }) + .key('Interface200_search_001') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol020.ets new file mode 100755 index 00000000..3a46757c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol020.ets @@ -0,0 +1,38 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface_Symbol020 { + @State placeholder: string = 'This is test text.'; + @State iconSize: Length | undefined = '16vp'; + + build() { + Column() { + Button('size=0').onClick(() => { + this.iconSize = 0; + }).key('Symbol020_button_001') + Button('size=-10').onClick(() => { + this.iconSize = -10; + }).margin(10).key('Symbol020_button_002') + Button('size=undefined').onClick(() => { + this.iconSize = undefined; + }).margin({ bottom: 10 }).key('Symbol020_button_003') + Search({ value: this.placeholder }) + .searchIcon({ size: this.iconSize }) + .key('Symbol020_search_001') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol030.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol030.ets new file mode 100755 index 00000000..28ca788c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol030.ets @@ -0,0 +1,38 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface_Symbol030 { + @State placeholder: string = 'This is test text.'; + @State iconColor: Color | number | string | Resource = Color.Black; + + build() { + Column() { + Button('color').onClick(() => { + this.iconColor = Color.Pink; + }).key('Symbol030_button_001') + Button('number').onClick(() => { + this.iconColor = getContext().resourceManager.getColorSync($r('app.color.yellow')); + }).margin(10).key('Symbol030_button_002') + Button('string').onClick(() => { + this.iconColor = '#fff000'; + }).margin({ bottom: 10 }).key('Symbol030_button_003') + Search({ value: this.placeholder }) + .searchIcon({ color: this.iconColor }) + .key('Symbol030_search_001') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol040.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol040.ets new file mode 100755 index 00000000..90287867 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol040.ets @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface_Symbol040 { + @State placeholder: string = 'This is test text.'; + + build() { + Column() { + Search({ value: this.placeholder }) + .searchIcon({ src: $r('app.media.cat') }) + .key('Symbol040_search_001') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol050.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol050.ets new file mode 100755 index 00000000..b996f745 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol050.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface_Symbol050 { + @State placeholder: string = 'This is test text.'; + + build() { + Column() { + Text('CancelButtonStyle.CONSTANT').margin({ bottom: 10 }) + Search({ placeholder: this.placeholder }) + .cancelButton({ style: CancelButtonStyle.CONSTANT }) + .key('Symbol050_search_001') + Text('CancelButtonStyle.INVISIBLE').margin({ top: 10, bottom: 10 }) + Search({ value: this.placeholder }) + .cancelButton({ style: CancelButtonStyle.INVISIBLE }) + .key('Symbol050_search_002') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol060.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol060.ets new file mode 100755 index 00000000..f2a40554 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol060.ets @@ -0,0 +1,41 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface_Symbol060 { + @State placeholder: string = 'This is test text.'; + @State iconSize: Length | undefined = '16vp'; + + build() { + Column() { + Button('size=fp').onClick(() => { + this.iconSize = '20fp'; + }).key('Symbol060_button_001') + Button('size=vp').onClick(() => { + this.iconSize = '20vp'; + }).margin(10).key('Symbol060_button_002') + Button('size=px').onClick(() => { + this.iconSize = '20px'; + }).margin({ bottom: 10 }).key('Symbol060_button_003') + Button('size=number').onClick(() => { + this.iconSize = 20; + }).margin({ bottom: 10 }).key('Symbol060_button_004') + Search({ value: this.placeholder }) + .searchIcon({ size: this.iconSize }) + .key('Symbol060_search_001') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol070.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol070.ets new file mode 100755 index 00000000..b22ed263 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol070.ets @@ -0,0 +1,38 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface_Symbol070 { + @State placeholder: string = 'This is test text.'; + @State iconSize: Length | undefined = '16vp'; + + build() { + Column() { + Button('size=0').onClick(() => { + this.iconSize = 0; + }).key('Symbol070_button_001') + Button('size=-10').onClick(() => { + this.iconSize = -10; + }).margin(10).key('Symbol070_button_002') + Button('size=undefined').onClick(() => { + this.iconSize = undefined; + }).margin({ bottom: 10 }).key('Symbol070_button_003') + Search({ value: this.placeholder }) + .cancelButton({ icon: { size: this.iconSize } }) + .key('Symbol070_search_001') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol080.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol080.ets new file mode 100755 index 00000000..ff2f96eb --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol080.ets @@ -0,0 +1,38 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSearchInterface_Symbol080 { + @State placeholder: string = 'This is test text.'; + @State iconColor: Color | number | string | Resource = Color.Black; + + build() { + Column() { + Button('color').onClick(() => { + this.iconColor = Color.Pink; + }).key('Symbol080_button_001') + Button('number').onClick(() => { + this.iconColor = getContext().resourceManager.getColorSync($r('app.color.yellow')); + }).margin(10).key('Symbol080_button_002') + Button('string').onClick(() => { + this.iconColor = '#fff000'; + }).margin({ bottom: 10 }).key('Symbol080_button_003') + Search({ value: this.placeholder }) + .cancelButton({ icon: { color: this.iconColor } }) + .key('Symbol080_search_001') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020.ets new file mode 100644 index 00000000..b004e005 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020.ets @@ -0,0 +1,40 @@ +/* + * Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSelectionAction0020 { + @State text: string = '0123456' + @State res: string = 'before opt: '; + @State style001: TextInputStyle = TextInputStyle.Default; + @State start: number = 0 + @State end: number = 20 + controller: TextInputController = new TextInputController() + + build() { + Column() { + TextInput({ + placeholder: 'input', + controller: this.controller + }) + .width('80%') + .height('50') + .margin(20) + .fontSize(16) + .id('textSelectionAction0020') + } + + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0110.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0110.ets new file mode 100644 index 00000000..e689d014 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0110.ets @@ -0,0 +1,63 @@ +/* + * Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSelectionAction0110 { + @State text: string = '0123456' + @State res: string = 'before opt: '; + @State style001: TextInputStyle = TextInputStyle.Default; + @State start: number = 0 + @State end: number = 20 + controller: TextAreaController = new TextAreaController() + + @Builder + MyMenu() { + Menu() { + MenuItem({ startIcon: 'cat.jpg', content: "Menu 1", labelInfo: "" }) + MenuItem({ startIcon: 'icon.png', content: "Menu 2", labelInfo: "" }) + MenuItem({ startIcon: 'openeye.png', content: "Menu 3", labelInfo: "" }) + } + } + + build() { + Column() { + TextArea({ + placeholder: 'input', + controller: this.controller + }) + .width('80%') + .height('50') + .margin(20) + .fontSize(16) + .id('textSelectionAction0110') + .bindContextMenu(this.MyMenu(), + ResponseType.RightClick, { + previewAnimationOptions: { + transition: TransitionEffect.OPACITY.animation({ duration: 250, curve: Curve.Ease }) + }, + aboutToAppear: () => { + console.log('aboutToAppear>>'); + }, + onAppear: () => { + console.log('onAppear>>'); + } + } + ) + //{ transition: TransitionEffect.OPACITY.animation({duration:2000,curve:Curve.Ease}).combine()}) + } + + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0120.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0120.ets new file mode 100644 index 00000000..a26a4396 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0120.ets @@ -0,0 +1,65 @@ +/* + * Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSelectionAction0120 { + @State text: string = '0123456' + @State res: string = 'before opt: '; + @State style001: TextInputStyle = TextInputStyle.Default; + @State start: number = 0 + @State end: number = 20 + controller: TextInputController = new TextInputController() + option: ContextMenuAnimationOptions |null =null + + @Builder + TextCustomMenu() { + Column() { + Menu() { + MenuItemGroup() { + MenuItem({ startIcon: 'cat.jpg', content: "Menu 1", labelInfo: "" }) + MenuItem({ startIcon: 'icon.png', content: "Menu 2", labelInfo: "" }) + MenuItem({ startIcon: 'openeye.png', content: "Menu 3", labelInfo: "" }) + } + } + } + } + + build() { + Column() { + TextInput({ + placeholder: 'input', + controller: this.controller + }) + .width('80%') + .height('50') + .margin(20) + .fontSize(16) + .id('textSelectionAction0120') + .bindContextMenu(this.TextCustomMenu(), + ResponseType.RightClick, + { + aboutToAppear: () => { + console.log('aboutToAppear>>'); + }, + aboutToDisappear:()=> { + console.log('aboutToDisappear>>'); + }, + transition: TransitionEffect.OPACITY.animation({ duration: 200, curve: Curve.Ease }), + }) + } + + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0160.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0160.ets new file mode 100644 index 00000000..7cd0e523 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0160.ets @@ -0,0 +1,42 @@ +/* + * Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSelectionAction0160 { + @State text: string = 'TextInput:UIComponentTextSelectionAction0160 disable' + @State res: string = 'before opt: '; + @State style001: TextInputStyle = TextInputStyle.Default; + @State start: number = 0 + @State end: number = 20 + controller: TextInputController = new TextInputController() + + build() { + Column() { + TextInput({ + text: this.text, + placeholder: 'input', + controller: this.controller + }) + .width('80%') + .height('50') + .margin(20) + .fontSize(16) + .enabled(false) + .id('textSelectionAction0160') + } + + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0430.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0430.ets new file mode 100644 index 00000000..bde7b3be --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0430.ets @@ -0,0 +1,48 @@ +/* + * Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSelectionAction0430 { + @State text: string = + 'TextInput:UIComponentTextSelectionAction maxLines n' + + '\nTextInput:UIComponentTextSelectionAction maxLines' + + '\nTextInput:UIComponentTextSelectionAction maxLines' + + '\nTextInput:UIComponentTextSelectionAction maxLines' + + '\nTextInput:UIComponentTextSelectionAction maxLines' + @State res: string = 'before opt: '; + @State style001: TextInputStyle = TextInputStyle.Default; + @State start: number = 0 + @State end: number = 20 + controller: TextInputController = new TextInputController() + + build() { + Column() { + TextInput({ + text: this.text, + placeholder: 'input', + controller: this.controller + }) + .width('80%') + .style(TextInputStyle.Inline) + .height('100') + .margin(20) + .fontSize(16) + .maxLines(3) + .id('textSelectionAction0430') + } + + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0630.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0630.ets new file mode 100644 index 00000000..43f20608 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0630.ets @@ -0,0 +1,51 @@ +/* + * Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSelectionAction0630 { + @State text: string = '0123456' + @State res: string = 'before opt: '; + @State style001: TextInputStyle = TextInputStyle.Default; + @State start: number = 0 + @State end: number = 20 + controller: TextInputController = new TextInputController() + + build() { + Column() { + TextInput({ + placeholder: 'input', + controller: this.controller + }) + .width('80%') + .height('50') + .margin(20) + .fontSize(16) + .draggable(true) + .id('textSelectionAction0630_1') + + TextInput({ + placeholder: 'get drag:', + controller: this.controller + }) + .width('80%') + .margin(30) + .fontSize(16) + .draggable(true) + .id('textSelectionAction0630_2') + } + + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface.ets new file mode 100755 index 00000000..cf842a0c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface.ets @@ -0,0 +1,114 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import promptAction from '@ohos.promptAction' + +@Entry +@Component +struct UIComponentTextSelectionInterface { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + @State text: string = '这是提示文本' + @State caretStyle: CaretStyle | undefined = undefined; + + build() { + Column() { + TextArea({ placeholder: this.text }) + .width('55%') + .copyOption(CopyOptions.InApp) + .onCopy((value: string) => { + promptAction.showToast({ + message: 'onCopy: '+value, + duration: 2000, + }) + }) + .onPaste((value: string, event: PasteEvent) => { + promptAction.showToast({ + message: 'onPaste: '+value, + duration: 2000, + }) + }) + .margin({ top: 20 }) + .borderWidth(3) + .key('textSelectionInterface_001') + + Search({ placeholder: this.text }) + .caretStyle(this.caretStyle) + .width(336) + .height(56) + .copyOption(CopyOptions.LocalDevice) + .onCopy((value: string) => { + promptAction.showToast({ + message: 'onCopy: '+value, + duration: 2000, + }) + }) + .onPaste((value: string, event: PasteEvent) => { + promptAction.showToast({ + message: 'onPaste: '+value, + duration: 2000, + }) + }) + .margin({ top: 20 }) + .key('textSelectionInterface_002') + + Button('设置caretStyle的width=0') + .id('textSelectionInterface_009') + .onClick(() => { + this.caretStyle = { width: 0 } + }) + .margin(10) + + Button('设置caretStyle的width过大') + .id('textSelectionInterface_003') + .onClick(() => { + this.caretStyle = { width: 1000 } + }) + .margin(10) + Button('设置caretStyle的width为10') + .id('textSelectionInterface_004') + .onClick(() => { + this.caretStyle = { width: 10 } + }) + .margin(2) + Button('设置caretStyle的width为字符串') + .id('textSelectionInterface_005') + .onClick(() => { + this.caretStyle = { width: '10fp' } + }) + .margin(2) + Button('设置caretStyle的width为string的json文件') + .id('textSelectionInterface_006') + .onClick(() => { + this.caretStyle = { width: getContext().resourceManager.getStringSync($r("app.string.search_width")) } + }) + .margin(2) + Button('设置caretStyle的color为$rawfile(color.json)') + .id('textSelectionInterface_007') + .onClick(() => { + this.caretStyle = { color: getContext().resourceManager.getColorSync($r("app.color.purple")) } + }) + .margin(2) + Button('设置caretStyle的color为#ff0000') + .id('textSelectionInterface_008') + .onClick(() => { + this.caretStyle = { color: '#ff0000' } + }) + .margin(2) + + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface020.ets new file mode 100755 index 00000000..0864f017 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface020.ets @@ -0,0 +1,57 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import promptAction from '@ohos.promptAction' + +@Entry +@Component +struct UIComponentTextSelectionInterface020 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + @State text: string = '这是提示文本' + @State caretStyle: CaretStyle | undefined = undefined; + + build() { + Column() { + Search({ placeholder: this.text }) + .caretStyle(this.caretStyle) + .width(336) + .height(56) + .copyOption(CopyOptions.LocalDevice) + .onCut((value: string) => { + promptAction.showToast({ + message: 'onCopy: '+value, + duration: 2000, + }) + }) + .margin({ top: 20 }) + .key('textSelectionInterface020_001') + TextArea({ placeholder: this.text }) + .caretStyle(this.caretStyle) + .width(336) + .height(56) + .copyOption(CopyOptions.LocalDevice) + .onCut((value: string) => { + promptAction.showToast({ + message: 'onCopy: '+value, + duration: 2000, + }) + }) + .margin({ top: 20 }) + .key('textSelectionInterface020_002') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface040.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface040.ets new file mode 100755 index 00000000..9a135067 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface040.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UIComponentTextSelectionInterface040 { + @State placeholder: string = 'This is test text.'; + @State callback: string = 'onSubmit log: '; + + build() { + Column() { + Text(this.callback).margin({ bottom: 10 }) + Search({ value: this.placeholder }) + .onSubmit((value: string) => { + this.callback = 'onSubmit log: ' + value; + }).searchButton('Search') + .key('textSelectionInterface040_001') + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonApplicationLevelFonts/UiComponentTextCommonApplicationLevelFonts0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonApplicationLevelFonts/UiComponentTextCommonApplicationLevelFonts0010.ets new file mode 100644 index 00000000..61237256 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonApplicationLevelFonts/UiComponentTextCommonApplicationLevelFonts0010.ets @@ -0,0 +1,117 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@CustomDialog +struct CustomDialogExample { + @State fontStyle: FontStyle = FontStyle.Normal + controller?: CustomDialogController + cancel: () => void = () => { + } + confirm: () => void = () => { + } + + build() { + Column() { + Text('这是自定义弹窗') + .fontSize(30) + .height(100) + .fontStyle(this.fontStyle) + Button('点我关闭弹窗') + .onClick(() => { + if (this.controller != undefined) { + this.controller.close() + } + }) + Button('改变字体样式') + .id('changeFontApplicationLevelFonts0010') + .fontStyle(this.fontStyle) + .margin(20) + .onClick(() => { + this.fontStyle = FontStyle.Italic + }) + } + } +} + +@Entry +@Component +struct UiComponentTextCommonApplicationLevelFonts0010 { + dialogController: CustomDialogController | null = new CustomDialogController({ + builder: CustomDialogExample({ + cancel: () => { + this.onCancel() + }, + confirm: () => { + this.onAccept() + } + }), + cancel: this.existApp, + autoCancel: true, + onWillDismiss: (dismissDialogAction: DismissDialogAction) => { + console.info("reason=" + JSON.stringify(dismissDialogAction.reason)) + console.log("dialog onWillDismiss") + if (dismissDialogAction.reason == DismissReason.PRESS_BACK) { + dismissDialogAction.dismiss() + } + if (dismissDialogAction.reason == DismissReason.TOUCH_OUTSIDE) { + dismissDialogAction.dismiss() + } + }, + alignment: DialogAlignment.Center, + offset: { dx: 0, dy: -20 }, + customStyle: false, + cornerRadius: 20, + width: 300, + height: 200, + borderWidth: 1, + borderStyle: BorderStyle.Dashed, //使用borderStyle属性,需要和borderWidth属性一起使用 + borderColor: Color.Blue, //使用borderColor属性,需要和borderWidth属性一起使用 + backgroundColor: Color.White, + shadow: ({ + radius: 20, + color: Color.Grey, + offsetX: 50, + offsetY: 0 + }), + }) + + // 在自定义组件即将析构销毁时将dialogController置空 + aboutToDisappear() { + this.dialogController = null // 将dialogController置空 + } + + onCancel() { + console.info('Callback when the first button is clicked') + } + + onAccept() { + console.info('Callback when the second button is clicked') + } + + existApp() { + console.info('Click the callback in the blank area') + } + + build() { + Column() { + Button('click me') + .id('openDialogApplicationLevelFonts0010') + .onClick(() => { + if (this.dialogController != null) { + this.dialogController.open() + } + }).backgroundColor(0x317aff) + }.width('100%').margin({ top: 5 }) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0010.ets new file mode 100644 index 00000000..04ffd9a8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0010.ets @@ -0,0 +1,56 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0010 { + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0010_1') + .width('80%') + .border({ width: 1 }) + .defaultFocus(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + TextInput({ controller: this.controller, text: this.inputValue }) + // 绑定自定义键盘 + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + .id('TextInputCustomKeyBoardIsSupportAvoidance0010_2') + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0020.ets new file mode 100644 index 00000000..ea1fea54 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0020.ets @@ -0,0 +1,56 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0020 { + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0020_1') + .width('80%') + .border({ width: 1 }) + .defaultFocus(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + TextInput({ controller: this.controller, text: this.inputValue }) + // 绑定自定义键盘 + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + .id('TextInputCustomKeyBoardIsSupportAvoidance0020_2') + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0030.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0030.ets new file mode 100644 index 00000000..5587cd2c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0030.ets @@ -0,0 +1,102 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0030 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State height1: string | number = '80%' + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = "20%" + }) + Button("80%") + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = "80%" + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0030') + .onClick(() => { + this.changeOrientation(true); + }) + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0030_1') + .width('80%') + .border({ width: 1 }) + .defaultFocus(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + TextInput({ controller: this.controller, text: this.inputValue })// 绑定自定义键盘 + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + .id('TextInputCustomKeyBoardIsSupportAvoidance0030_2') + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0040.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0040.ets new file mode 100644 index 00000000..be541a71 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0040.ets @@ -0,0 +1,102 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0040 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State height1: string | number = '80%' + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0040') + .onClick(() => { + this.changeOrientation(true); + }) + Row() { + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = "20%" + }) + Button("80%") + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = "80%" + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0040_1') + .width('80%') + .border({ width: 1 }) + .defaultFocus(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + TextInput({ controller: this.controller, text: this.inputValue })// 绑定自定义键盘 + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + .id('TextInputCustomKeyBoardIsSupportAvoidance0040_2') + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0050.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0050.ets new file mode 100644 index 00000000..d9f7aa32 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0050.ets @@ -0,0 +1,105 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0050 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State height1: string | number = 300 + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0050') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 600 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0050') + .width('80%') + .border({ width: 1 }) + .defaultFocus(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button("80%") + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 600 + }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0060.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0060.ets new file mode 100644 index 00000000..d6c43b1c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0060.ets @@ -0,0 +1,105 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0060 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State height1: string | number = 700 + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0060') + .onClick(() => { + this.changeOrientation(true); + }) + Row() { + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 600 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0060') + .width('80%') + .border({ width: 1 }) + .defaultFocus(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button("80%") + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 600 + }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0070.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0070.ets new file mode 100644 index 00000000..77f07dfe --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0070.ets @@ -0,0 +1,106 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0070 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State height1: string | number = '50%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0070') + .onClick(() => { + this.changeOrientation(true); + }) + Row() { + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0070') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 600 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0070') + .width('80%') + .border({ width: 1 }) + .defaultFocus(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0080.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0080.ets new file mode 100644 index 00000000..6ba669bf --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0080.ets @@ -0,0 +1,106 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0080 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State height1: string | number = '50%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0080') + .onClick(() => { + this.changeOrientation(true); + }) + Row() { + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0080') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 600 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0080') + .width('80%') + .border({ width: 1 }) + .defaultFocus(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0090.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0090.ets new file mode 100644 index 00000000..93a5d2cc --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0090.ets @@ -0,0 +1,106 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0090 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State height1: string | number = '70%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0090') + .onClick(() => { + this.changeOrientation(true); + }) + Row() { + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0090') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 600 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0090') + .width('80%') + .border({ width: 1 }) + .defaultFocus(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0100.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0100.ets new file mode 100644 index 00000000..015fc3b5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0100.ets @@ -0,0 +1,106 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0100 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State height1: string | number = '70%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0100') + .onClick(() => { + this.changeOrientation(true); + }) + Row() { + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0100') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 600 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0100') + .width('80%') + .border({ width: 1 }) + .defaultFocus(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0110.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0110.ets new file mode 100644 index 00000000..9d3af652 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0110.ets @@ -0,0 +1,107 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0110 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State height1: string | number = '60%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0110') + .onClick(() => { + this.changeOrientation(true); + }) + Row() { + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0110') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 600 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + Scroll(){ + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0110') + .width('80%') + .border({ width: 1 }) + .defaultFocus(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0120.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0120.ets new file mode 100644 index 00000000..e20ae91e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0120.ets @@ -0,0 +1,107 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0120 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State height1: string | number = '60%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0120') + .onClick(() => { + this.changeOrientation(true); + }) + Row() { + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0120') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 600 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + Scroll(){ + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0120') + .width('80%') + .border({ width: 1 }) + .defaultFocus(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0130.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0130.ets new file mode 100644 index 00000000..306f592b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0130.ets @@ -0,0 +1,111 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0130 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State height1: string | number = '60%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0130') + .onClick(() => { + this.changeOrientation(true); + }) + Row() { + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0130') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 600 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0130_1') + .width('80%') + .border({ width: 1 }) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0130') + .width('80%') + .border({ width: 1 }) + .defaultFocus(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0150.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0150.ets new file mode 100644 index 00000000..5c14c83f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0150.ets @@ -0,0 +1,52 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0150 { + controller: TextInputController = new TextInputController() + @State focus: boolean = true + + build() { + Column() { + Row() { + Button("focusable") + .fontSize(15) + .onClick(() => { + this.focus = false; + }).id('TextInputCustomKeyBoardIsSupportAvoidance0150_btn_01') + Button("stopEditing") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0130') + .fontSize(15) + .margin({ left: 20 }) + .onClick(() => { + this.controller.stopEditing(); + }) + .id('TextInputCustomKeyBoardIsSupportAvoidance0150_btn_02') + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .width("100%") + .padding({ top: 50, bottom: 50 }) + + TextInput({ controller: this.controller, placeholder: '请输入内容' }) + .id('TextInputCustomKeyBoardIsSupportAvoidance0150_1') + .width('80%') + .focusable(this.focus) + .border({ width: 1 }) + + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0160.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0160.ets new file mode 100644 index 00000000..8862b85c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0160.ets @@ -0,0 +1,154 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@CustomDialog +struct CustomDialogExample { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State height1: string | number = '60%' + inputController: TextInputController = new TextInputController() + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.inputController.stopEditing() + }) + .id('closeKeyBoardIsSupportAvoidance0160') + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + controller?: CustomDialogController + cancel: () => void = () => { + } + confirm: () => void = () => { + } + build() { + Column() { + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0160') + .width('80%') + .border({ width: 1 }) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0160') + .onClick(() => { + this.changeOrientation(true); + }) + Button('点我关闭弹窗') + .onClick(() => { + if (this.controller != undefined) { + this.controller.close() + } + }) + .margin(20) + } + } +} +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0160 { + dialogController: CustomDialogController | null = new CustomDialogController({ + builder: CustomDialogExample({ + cancel: ()=> { this.onCancel() }, + confirm: ()=> { this.onAccept() } + }), + cancel: this.existApp, + autoCancel: true, + onWillDismiss:(dismissDialogAction: DismissDialogAction)=> { + console.info("reason=" + JSON.stringify(dismissDialogAction.reason)) + console.log("dialog onWillDismiss") + if (dismissDialogAction.reason == DismissReason.PRESS_BACK) { + dismissDialogAction.dismiss() + } + if (dismissDialogAction.reason == DismissReason.TOUCH_OUTSIDE) { + dismissDialogAction.dismiss() + } + }, + alignment: DialogAlignment.Bottom, + offset: { dx: 0, dy: -20 }, + customStyle: false, + cornerRadius: 20, + width: 300, + height: 200, + borderWidth: 1, + borderStyle: BorderStyle.Dashed,//使用borderStyle属性,需要和borderWidth属性一起使用 + borderColor: Color.Blue,//使用borderColor属性,需要和borderWidth属性一起使用 + backgroundColor: Color.White, + shadow: ({ radius: 20, color: Color.Grey, offsetX: 50, offsetY: 0}), + }) + // 在自定义组件即将析构销毁时将dialogController置空 + aboutToDisappear() { + this.dialogController = null // 将dialogController置空 + } + + onCancel() { + console.info('Callback when the first button is clicked') + } + + onAccept() { + console.info('Callback when the second button is clicked') + } + + existApp() { + console.info('Click the callback in the blank area') + } + + build() { + Column() { + Button('click me') + .id('openDialogCustomKeyBoardIsSupportAvoidance0160') + .onClick(() => { + if (this.dialogController != null) { + this.dialogController.open() + } + }).backgroundColor(0x317aff) + }.width('100%').margin({ top: 5 }) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0170.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0170.ets new file mode 100644 index 00000000..a68bd577 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0170.ets @@ -0,0 +1,154 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@CustomDialog +struct CustomDialogExample { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State height1: string | number = '60%' + inputController: TextInputController = new TextInputController() + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.inputController.stopEditing() + }) + .id('closeKeyBoardIsSupportAvoidance0170') + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + controller?: CustomDialogController + cancel: () => void = () => { + } + confirm: () => void = () => { + } + build() { + Column() { + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0170') + .width('80%') + .border({ width: 1 }) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0170') + .onClick(() => { + this.changeOrientation(true); + }) + Button('点我关闭弹窗') + .onClick(() => { + if (this.controller != undefined) { + this.controller.close() + } + }) + .margin(20) + } + } +} +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0170 { + dialogController: CustomDialogController | null = new CustomDialogController({ + builder: CustomDialogExample({ + cancel: ()=> { this.onCancel() }, + confirm: ()=> { this.onAccept() } + }), + cancel: this.existApp, + autoCancel: true, + onWillDismiss:(dismissDialogAction: DismissDialogAction)=> { + console.info("reason=" + JSON.stringify(dismissDialogAction.reason)) + console.log("dialog onWillDismiss") + if (dismissDialogAction.reason == DismissReason.PRESS_BACK) { + dismissDialogAction.dismiss() + } + if (dismissDialogAction.reason == DismissReason.TOUCH_OUTSIDE) { + dismissDialogAction.dismiss() + } + }, + alignment: DialogAlignment.Bottom, + offset: { dx: 0, dy: -20 }, + customStyle: false, + cornerRadius: 20, + width: 300, + height: 200, + borderWidth: 1, + borderStyle: BorderStyle.Dashed,//使用borderStyle属性,需要和borderWidth属性一起使用 + borderColor: Color.Blue,//使用borderColor属性,需要和borderWidth属性一起使用 + backgroundColor: Color.White, + shadow: ({ radius: 20, color: Color.Grey, offsetX: 50, offsetY: 0}), + }) + // 在自定义组件即将析构销毁时将dialogController置空 + aboutToDisappear() { + this.dialogController = null // 将dialogController置空 + } + + onCancel() { + console.info('Callback when the first button is clicked') + } + + onAccept() { + console.info('Callback when the second button is clicked') + } + + existApp() { + console.info('Click the callback in the blank area') + } + + build() { + Column() { + Button('click me') + .id('openDialogCustomKeyBoardIsSupportAvoidance0170') + .onClick(() => { + if (this.dialogController != null) { + this.dialogController.open() + } + }).backgroundColor(0x317aff) + }.width('100%').margin({ top: 5 }) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0200.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0200.ets new file mode 100644 index 00000000..e3537a8e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0200.ets @@ -0,0 +1,86 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0200 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = '60%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0200') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + .expandSafeArea([SafeAreaType.SYSTEM], [SafeAreaEdge.TOP, SafeAreaEdge.BOTTOM]) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0200') + .onClick(() => { + this.changeOrientation(true); + }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0210.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0210.ets new file mode 100644 index 00000000..5e980d16 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0210.ets @@ -0,0 +1,85 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0210 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = '60%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + TextInput() + .id('TextInputCustomKeyBoardIsSupportAvoidance0210') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0210') + .onClick(() => { + this.changeOrientation(true); + }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0220.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0220.ets new file mode 100644 index 00000000..4eb73e40 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0220.ets @@ -0,0 +1,85 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0220 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = '60%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0220') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0220') + .onClick(() => { + this.changeOrientation(true); + }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0230.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0230.ets new file mode 100644 index 00000000..36b89a4d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0230.ets @@ -0,0 +1,85 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0230 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State isFocusable: boolean = true + @State height1: string | number = '60%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0230') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0230') + .onClick(() => { + this.changeOrientation(true); + }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0240.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0240.ets new file mode 100644 index 00000000..02d8e135 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0240.ets @@ -0,0 +1,85 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0240 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = '60%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0240') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0240') + .onClick(() => { + this.changeOrientation(true); + }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0250.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0250.ets new file mode 100644 index 00000000..1ffec7d5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0250.ets @@ -0,0 +1,103 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0250 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State isFocusable: boolean = true + @State height1: string | number = '70%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0250') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = "20%" + }) + Button("80%") + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = "80%" + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0250') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0260.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0260.ets new file mode 100644 index 00000000..e69ed0b2 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0260.ets @@ -0,0 +1,103 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0260 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = 700 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0260') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = "20%" + }) + Button("80%") + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = "80%" + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0260') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0270.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0270.ets new file mode 100644 index 00000000..90bba84d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0270.ets @@ -0,0 +1,103 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0270 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State isFocusable: boolean = true + @State height1: string | number = 600 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0270') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = "20%" + }) + Button("80%") + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = "80%" + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0270') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0280.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0280.ets new file mode 100644 index 00000000..bd529c8d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0280.ets @@ -0,0 +1,104 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0280 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = 700 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0280') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0280') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 600 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0280') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0290.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0290.ets new file mode 100644 index 00000000..b9c0400a --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0290.ets @@ -0,0 +1,104 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0290 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State isFocusable: boolean = true + @State height1: string | number = 600 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0290') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0290') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 500 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0290') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0300.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0300.ets new file mode 100644 index 00000000..545f4a9d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0300.ets @@ -0,0 +1,104 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0300 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = 600 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0300') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0300') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 500 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0300') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0310.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0310.ets new file mode 100644 index 00000000..ea861e23 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0310.ets @@ -0,0 +1,104 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0310 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State isFocusable: boolean = true + @State height1: string | number = 600 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0310') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0310') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 500 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0310') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0320.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0320.ets new file mode 100644 index 00000000..53fedad9 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0320.ets @@ -0,0 +1,104 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0320 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = 600 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0320') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0320') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 500 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0320') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0330.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0330.ets new file mode 100644 index 00000000..6fe259ac --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0330.ets @@ -0,0 +1,104 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0330 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State isFocusable: boolean = true + @State height1: string | number = 600 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0330') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0330') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 500 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0330') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0340.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0340.ets new file mode 100644 index 00000000..a656309a --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0340.ets @@ -0,0 +1,110 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0340 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = 600 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0340') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0340') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 500 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0340') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0340_1') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0360.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0360.ets new file mode 100644 index 00000000..cd85b29d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0360.ets @@ -0,0 +1,52 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0360 { + controller: SearchController = new SearchController() + @State focus: boolean = true + + build() { + Column() { + Row() { + Button("focusable") + .fontSize(15) + .onClick(() => { + this.focus = false; + }).id('TextInputCustomKeyBoardIsSupportAvoidance0360_btn_01') + Button("stopEditing") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0130') + .fontSize(15) + .margin({ left: 20 }) + .onClick(() => { + this.controller.stopEditing(); + }) + .id('TextInputCustomKeyBoardIsSupportAvoidance0360_btn_02') + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .width("100%") + .padding({ top: 50, bottom: 50 }) + + Search({ controller: this.controller, placeholder: '请输入内容' }) + .id('TextInputCustomKeyBoardIsSupportAvoidance0360_1') + .width('80%') + .focusable(this.focus) + .border({ width: 1 }) + + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0370.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0370.ets new file mode 100644 index 00000000..ad3b0800 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0370.ets @@ -0,0 +1,171 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@CustomDialog +struct CustomDialogExample { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State height1: string | number = '60%' + inputController: TextInputController = new TextInputController() + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.inputController.stopEditing() + }) + .id('closeKeyBoardIsSupportAvoidance0370') + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + controller?: CustomDialogController + cancel: () => void = () => { + } + confirm: () => void = () => { + } + + build() { + Column() { + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0370') + .width('80%') + .border({ width: 1 }) + .focusable(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0370') + .onClick(() => { + this.changeOrientation(true); + }) + Button('点我关闭弹窗') + .onClick(() => { + if (this.controller != undefined) { + this.controller.close() + } + }) + .margin(20) + } + } +} + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0370 { + dialogController: CustomDialogController | null = new CustomDialogController({ + builder: CustomDialogExample({ + cancel: () => { + this.onCancel() + }, + confirm: () => { + this.onAccept() + } + }), + cancel: this.existApp, + autoCancel: true, + onWillDismiss: (dismissDialogAction: DismissDialogAction) => { + console.info("reason=" + JSON.stringify(dismissDialogAction.reason)) + console.log("dialog onWillDismiss") + if (dismissDialogAction.reason == DismissReason.PRESS_BACK) { + dismissDialogAction.dismiss() + } + if (dismissDialogAction.reason == DismissReason.TOUCH_OUTSIDE) { + dismissDialogAction.dismiss() + } + }, + alignment: DialogAlignment.Bottom, + offset: { dx: 0, dy: -20 }, + customStyle: false, + cornerRadius: 20, + width: 300, + height: 200, + borderWidth: 1, + borderStyle: BorderStyle.Dashed, //使用borderStyle属性,需要和borderWidth属性一起使用 + borderColor: Color.Blue, //使用borderColor属性,需要和borderWidth属性一起使用 + backgroundColor: Color.White, + shadow: ({ + radius: 20, + color: Color.Grey, + offsetX: 50, + offsetY: 0 + }), + }) + + // 在自定义组件即将析构销毁时将dialogController置空 + aboutToDisappear() { + this.dialogController = null // 将dialogController置空 + } + + onCancel() { + console.info('Callback when the first button is clicked') + } + + onAccept() { + console.info('Callback when the second button is clicked') + } + + existApp() { + console.info('Click the callback in the blank area') + } + + build() { + Column() { + Button('click me') + .id('openDialogCustomKeyBoardIsSupportAvoidance0370') + .onClick(() => { + if (this.dialogController != null) { + this.dialogController.open() + } + }).backgroundColor(0x317aff) + }.width('100%').margin({ top: 5 }) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0380.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0380.ets new file mode 100644 index 00000000..1e194960 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0380.ets @@ -0,0 +1,154 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@CustomDialog +struct CustomDialogExample { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State height1: string | number = '60%' + inputController: TextInputController = new TextInputController() + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.inputController.stopEditing() + }) + .id('closeKeyBoardIsSupportAvoidance0380') + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + controller?: CustomDialogController + cancel: () => void = () => { + } + confirm: () => void = () => { + } + build() { + Column() { + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0380') + .width('80%') + .border({ width: 1 }) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0380') + .onClick(() => { + this.changeOrientation(true); + }) + Button('点我关闭弹窗') + .onClick(() => { + if (this.controller != undefined) { + this.controller.close() + } + }) + .margin(20) + } + } +} +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0380 { + dialogController: CustomDialogController | null = new CustomDialogController({ + builder: CustomDialogExample({ + cancel: ()=> { this.onCancel() }, + confirm: ()=> { this.onAccept() } + }), + cancel: this.existApp, + autoCancel: true, + onWillDismiss:(dismissDialogAction: DismissDialogAction)=> { + console.info("reason=" + JSON.stringify(dismissDialogAction.reason)) + console.log("dialog onWillDismiss") + if (dismissDialogAction.reason == DismissReason.PRESS_BACK) { + dismissDialogAction.dismiss() + } + if (dismissDialogAction.reason == DismissReason.TOUCH_OUTSIDE) { + dismissDialogAction.dismiss() + } + }, + alignment: DialogAlignment.Bottom, + offset: { dx: 0, dy: -20 }, + customStyle: false, + cornerRadius: 20, + width: 300, + height: 200, + borderWidth: 1, + borderStyle: BorderStyle.Dashed,//使用borderStyle属性,需要和borderWidth属性一起使用 + borderColor: Color.Blue,//使用borderColor属性,需要和borderWidth属性一起使用 + backgroundColor: Color.White, + shadow: ({ radius: 20, color: Color.Grey, offsetX: 50, offsetY: 0}), + }) + // 在自定义组件即将析构销毁时将dialogController置空 + aboutToDisappear() { + this.dialogController = null // 将dialogController置空 + } + + onCancel() { + console.info('Callback when the first button is clicked') + } + + onAccept() { + console.info('Callback when the second button is clicked') + } + + existApp() { + console.info('Click the callback in the blank area') + } + + build() { + Column() { + Button('click me') + .id('openDialogCustomKeyBoardIsSupportAvoidance0380') + .onClick(() => { + if (this.dialogController != null) { + this.dialogController.open() + } + }).backgroundColor(0x317aff) + }.width('100%').margin({ top: 5 }) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0410.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0410.ets new file mode 100644 index 00000000..28dc2f26 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0410.ets @@ -0,0 +1,86 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0410 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: SearchController = new SearchController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = '60%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0410') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + .expandSafeArea([SafeAreaType.SYSTEM], [SafeAreaEdge.TOP, SafeAreaEdge.BOTTOM]) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0410') + .onClick(() => { + this.changeOrientation(true); + }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0420.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0420.ets new file mode 100644 index 00000000..6ff90d00 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0420.ets @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0420 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + controller: SearchController = new SearchController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State isFocusable: boolean = true + @State height1: string | number = '60%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Search() + .id('SearchCustomKeyBoardIsSupportAvoidance0420') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0420') + .onClick(() => { + this.changeOrientation(true); + }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0430.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0430.ets new file mode 100644 index 00000000..1b6ec3b5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0430.ets @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0430 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + controller: TextAreaController = new TextAreaController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = '60%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0430') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0430') + .onClick(() => { + this.changeOrientation(true); + }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0440.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0440.ets new file mode 100644 index 00000000..7f797420 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0440.ets @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0440 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + controller: TextAreaController = new TextAreaController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State isFocusable: boolean = true + @State height1: string | number = '60%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0440') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0440') + .onClick(() => { + this.changeOrientation(true); + }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0450.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0450.ets new file mode 100644 index 00000000..1c567a30 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0450.ets @@ -0,0 +1,103 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0450 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextAreaController = new TextAreaController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = '70%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0450') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = "20%" + }) + Button("80%") + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = "80%" + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0450') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0460.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0460.ets new file mode 100644 index 00000000..38336645 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0460.ets @@ -0,0 +1,103 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0460 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextAreaController = new TextAreaController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State isFocusable: boolean = true + @State height1: string | number = '70%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0460') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = "20%" + }) + Button("80%") + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = "80%" + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0460') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0470.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0470.ets new file mode 100644 index 00000000..a6137e62 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0470.ets @@ -0,0 +1,105 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0470 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextAreaController = new TextAreaController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = 600 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0470') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = "20%" + }) + Button("80%") + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = "80%" + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0470') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button() + .height(20) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0480.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0480.ets new file mode 100644 index 00000000..2bb5d883 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0480.ets @@ -0,0 +1,105 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0480 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextAreaController = new TextAreaController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State isFocusable: boolean = true + @State height1: string | number = 600 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0480') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = "20%" + }) + Button("80%") + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = "80%" + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0480') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button() + .height(20) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0490.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0490.ets new file mode 100644 index 00000000..f1b88d9f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0490.ets @@ -0,0 +1,104 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0490 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextAreaController = new TextAreaController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = 700 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0490') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0490') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 600 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0490') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0500.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0500.ets new file mode 100644 index 00000000..27ad72f9 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0500.ets @@ -0,0 +1,104 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0500 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextAreaController = new TextAreaController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State isFocusable: boolean = true + @State height1: string | number = 700 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0500') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0500') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 600 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0500') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0510.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0510.ets new file mode 100644 index 00000000..3b2fc9c0 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0510.ets @@ -0,0 +1,104 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0510 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextAreaController = new TextAreaController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = 600 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0510') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0510') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 500 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0510') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0520.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0520.ets new file mode 100644 index 00000000..ee04f83d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0520.ets @@ -0,0 +1,104 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0520 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextAreaController = new TextAreaController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State isFocusable: boolean = true + @State height1: string | number = 600 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0520') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0520') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 500 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0520') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0530.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0530.ets new file mode 100644 index 00000000..03a04dc8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0530.ets @@ -0,0 +1,106 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0530 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextAreaController = new TextAreaController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = 600 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0530') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0530') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 500 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + Scroll(){ + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0530') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0540.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0540.ets new file mode 100644 index 00000000..ec91f2e6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0540.ets @@ -0,0 +1,106 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0540 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextAreaController = new TextAreaController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State isFocusable: boolean = true + @State height1: string | number = 600 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0540') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0540') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 500 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + Scroll(){ + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0540') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0550.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0550.ets new file mode 100644 index 00000000..e59de5c8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0550.ets @@ -0,0 +1,110 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0550 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextAreaController = new TextAreaController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = 600 + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Row() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0550') + .onClick(() => { + this.changeOrientation(true); + }) + Button("20%") + .fontSize(24) + .onClick(() => { + this.height1 = 20 + }) + Button("80%") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0550') + .fontSize(24) + .margin({ left: 20 }) + .onClick(() => { + this.height1 = 500 + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0550') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0550_1') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0570.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0570.ets new file mode 100644 index 00000000..9d31159c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0570.ets @@ -0,0 +1,52 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0570 { + controller: TextAreaController = new TextAreaController() + @State focus: boolean = true + + build() { + Column() { + Row() { + Button("focusable") + .fontSize(15) + .onClick(() => { + this.focus = false; + }).id('TextInputCustomKeyBoardIsSupportAvoidance0570_btn_01') + Button("stopEditing") + .id('btnChangeCustomKeyBoardIsSupportAvoidance0130') + .fontSize(15) + .margin({ left: 20 }) + .onClick(() => { + this.controller.stopEditing(); + }) + .id('TextInputCustomKeyBoardIsSupportAvoidance0570_btn_02') + } + .justifyContent(FlexAlign.Center) + .alignItems(VerticalAlign.Bottom) + .width("100%") + .padding({ top: 50, bottom: 50 }) + + TextArea({ controller: this.controller, placeholder: '请输入内容' }) + .id('TextInputCustomKeyBoardIsSupportAvoidance0570_1') + .width('80%') + .focusable(this.focus) + .border({ width: 1 }) + + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0580.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0580.ets new file mode 100644 index 00000000..6be51a60 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0580.ets @@ -0,0 +1,99 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0580 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + controller: TextAreaController = new TextAreaController() + @State inputValue: string = 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'+ + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = '100%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0580') + .onClick(() => { + this.changeOrientation(true); + }) + TextArea({ + text: this.inputValue, + controller: this.controller + }) + .id('TextAreaCustomKeyBoardIsSupportAvoidance0580') + .width('50%') + .height('100%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .fontSize(30) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + } + .justifyContent(FlexAlign.Center) + .alignItems(HorizontalAlign.Start) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0590.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0590.ets new file mode 100644 index 00000000..09f7f7e7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0590.ets @@ -0,0 +1,73 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { KeyboardAvoidMode } from '@kit.ArkUI'; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0590 { + controller: TextAreaController = new TextAreaController() + @State inputValue: string = 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = '100%' + aboutToAppear() { + this.getUIContext().setKeyboardAvoidMode(KeyboardAvoidMode.RESIZE); + } + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + TextArea({ + text: this.inputValue, + controller: this.controller + }) + .id('TextAreaCustomKeyBoardIsSupportAvoidance0590') + .width('50%') + .height('100%') + .border({ width: 1 }) + .fontSize(30) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('改变光标位置') + .id('btnCustomKeyBoardIsSupportAvoidance0590') + .onClick(() => { + this.controller.caretPosition(80); + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(HorizontalAlign.Start) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0600.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0600.ets new file mode 100644 index 00000000..16a5279c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0600.ets @@ -0,0 +1,71 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0600 { + controller: TextAreaController = new TextAreaController() + @State inputValue: string = 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + + 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = '100%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + TextArea({ + text: this.inputValue, + controller: this.controller + }) + .id('TextAreaCustomKeyBoardIsSupportAvoidance0600') + .width('50%') + .height('100%') + .border({ width: 1 }) + .fontSize(30) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('改变光标位置') + .id('btnCustomKeyBoardIsSupportAvoidance0600') + .onClick(() => { + this.controller.setTextSelection(0, 100); + }) + } + .justifyContent(FlexAlign.Center) + .alignItems(HorizontalAlign.Start) + .height(this.height1) + .width("100%") + .padding({ bottom: 50 }) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0610.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0610.ets new file mode 100644 index 00000000..59205ec0 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0610.ets @@ -0,0 +1,155 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@CustomDialog +struct CustomDialogExample { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + @State TextAreaValue: string = "" + @State supportAvoidance: boolean = false + @State height1: string | number = '60%' + TextAreaController: TextAreaController = new TextAreaController() + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.TextAreaController.stopEditing() + }) + .id('closeKeyBoardIsSupportAvoidance0610') + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.TextAreaValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + controller?: CustomDialogController + cancel: () => void = () => { + } + confirm: () => void = () => { + } + build() { + Column() { + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0610') + .width('80%') + .border({ width: 1 }) + .focusable(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0610') + .onClick(() => { + this.changeOrientation(true); + }) + Button('点我关闭弹窗') + .onClick(() => { + if (this.controller != undefined) { + this.controller.close() + } + }) + .margin(20) + } + } +} +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0610 { + dialogController: CustomDialogController | null = new CustomDialogController({ + builder: CustomDialogExample({ + cancel: ()=> { this.onCancel() }, + confirm: ()=> { this.onAccept() } + }), + cancel: this.existApp, + autoCancel: true, + onWillDismiss:(dismissDialogAction: DismissDialogAction)=> { + console.info("reason=" + JSON.stringify(dismissDialogAction.reason)) + console.log("dialog onWillDismiss") + if (dismissDialogAction.reason == DismissReason.PRESS_BACK) { + dismissDialogAction.dismiss() + } + if (dismissDialogAction.reason == DismissReason.TOUCH_OUTSIDE) { + dismissDialogAction.dismiss() + } + }, + alignment: DialogAlignment.Bottom, + offset: { dx: 0, dy: -20 }, + customStyle: false, + cornerRadius: 20, + width: 300, + height: 200, + borderWidth: 1, + borderStyle: BorderStyle.Dashed,//使用borderStyle属性,需要和borderWidth属性一起使用 + borderColor: Color.Blue,//使用borderColor属性,需要和borderWidth属性一起使用 + backgroundColor: Color.White, + shadow: ({ radius: 20, color: Color.Grey, offsetX: 50, offsetY: 0}), + }) + // 在自定义组件即将析构销毁时将dialogController置空 + aboutToDisappear() { + this.dialogController = null // 将dialogController置空 + } + + onCancel() { + console.info('Callback when the first button is clicked') + } + + onAccept() { + console.info('Callback when the second button is clicked') + } + + existApp() { + console.info('Click the callback in the blank area') + } + + build() { + Column() { + Button('click me') + .id('openDialogCustomKeyBoardIsSupportAvoidance0610') + .onClick(() => { + if (this.dialogController != null) { + this.dialogController.open() + } + }).backgroundColor(0x317aff) + }.width('100%').margin({ top: 5 }) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0620.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0620.ets new file mode 100644 index 00000000..17afdd3d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0620.ets @@ -0,0 +1,155 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@CustomDialog +struct CustomDialogExample { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + @State TextAreaValue: string = "" + @State supportAvoidance: boolean = true + @State height1: string | number = '60%' + TextAreaController: TextAreaController = new TextAreaController() + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.TextAreaController.stopEditing() + }) + .id('closeKeyBoardIsSupportAvoidance0620') + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.TextAreaValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + controller?: CustomDialogController + cancel: () => void = () => { + } + confirm: () => void = () => { + } + build() { + Column() { + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0620') + .width('80%') + .border({ width: 1 }) + .focusable(true) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0620') + .onClick(() => { + this.changeOrientation(true); + }) + Button('点我关闭弹窗') + .onClick(() => { + if (this.controller != undefined) { + this.controller.close() + } + }) + .margin(20) + } + } +} +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0620 { + dialogController: CustomDialogController | null = new CustomDialogController({ + builder: CustomDialogExample({ + cancel: ()=> { this.onCancel() }, + confirm: ()=> { this.onAccept() } + }), + cancel: this.existApp, + autoCancel: true, + onWillDismiss:(dismissDialogAction: DismissDialogAction)=> { + console.info("reason=" + JSON.stringify(dismissDialogAction.reason)) + console.log("dialog onWillDismiss") + if (dismissDialogAction.reason == DismissReason.PRESS_BACK) { + dismissDialogAction.dismiss() + } + if (dismissDialogAction.reason == DismissReason.TOUCH_OUTSIDE) { + dismissDialogAction.dismiss() + } + }, + alignment: DialogAlignment.Bottom, + offset: { dx: 0, dy: -20 }, + customStyle: false, + cornerRadius: 20, + width: 300, + height: 200, + borderWidth: 1, + borderStyle: BorderStyle.Dashed,//使用borderStyle属性,需要和borderWidth属性一起使用 + borderColor: Color.Blue,//使用borderColor属性,需要和borderWidth属性一起使用 + backgroundColor: Color.White, + shadow: ({ radius: 20, color: Color.Grey, offsetX: 50, offsetY: 0}), + }) + // 在自定义组件即将析构销毁时将dialogController置空 + aboutToDisappear() { + this.dialogController = null // 将dialogController置空 + } + + onCancel() { + console.info('Callback when the first button is clicked') + } + + onAccept() { + console.info('Callback when the second button is clicked') + } + + existApp() { + console.info('Click the callback in the blank area') + } + + build() { + Column() { + Button('click me') + .id('openDialogCustomKeyBoardIsSupportAvoidance0620') + .onClick(() => { + if (this.dialogController != null) { + this.dialogController.open() + } + }).backgroundColor(0x317aff) + }.width('100%').margin({ top: 5 }) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0650.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0650.ets new file mode 100644 index 00000000..deadabc7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0650.ets @@ -0,0 +1,86 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0650 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextAreaController = new TextAreaController() + @State inputValue: string = "" + @State supportAvoidance: boolean = false + @State isFocusable: boolean = true + @State height1: string | number = '60%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0650') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + .expandSafeArea([SafeAreaType.SYSTEM], [SafeAreaEdge.TOP, SafeAreaEdge.BOTTOM]) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0650') + .onClick(() => { + this.changeOrientation(true); + }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0660.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0660.ets new file mode 100644 index 00000000..111300c0 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0660.ets @@ -0,0 +1,85 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0660 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + controller: TextAreaController = new TextAreaController() + @State inputValue: string = "" + @State supportAvoidance: boolean = true + @State isFocusable: boolean = true + @State height1: string | number = '60%' + + @Builder + CustomKeyboardBuilder() { + Column() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }) + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray) + } + + build() { + Column() { + TextArea() + .id('TextAreaCustomKeyBoardIsSupportAvoidance0660') + .width('80%') + .border({ width: 1 }) + .focusable(this.isFocusable) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + Button('切换横竖屏') + .id('btnCustomKeyBoardIsSupportAvoidance0660') + .onClick(() => { + this.changeOrientation(true); + }) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0010.ets new file mode 100644 index 00000000..dd3c47d7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0010.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0010 { + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0010') + .margin(2) + TextArea() + .id('TextAreaTextCommonEmoji0010') + .margin(2) + Search({ + value: '\uD83D\uDE00' + }) + .id('SearchTextCommonEmoji0010') + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0020.ets new file mode 100644 index 00000000..ab2fce3b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0020.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0020 { + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0020') + .margin(2) + TextArea() + .id('TextAreaTextCommonEmoji0020') + .margin(2) + Search({ + value: '\uD83D\uDE00\uD83D\uDE00' + }) + .id('SearchTextCommonEmoji0020') + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0030.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0030.ets new file mode 100644 index 00000000..9eaa4e11 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0030.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0030 { + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0030') + .margin(2) + TextArea() + .id('TextAreaTextCommonEmoji0030') + .margin(2) + Search() + .id('SearchTextCommonEmoji0030') + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0040.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0040.ets new file mode 100644 index 00000000..98aff711 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0040.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0040 { + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0040') + .margin(2) + TextArea() + .id('TextAreaTextCommonEmoji0040') + .margin(2) + Search() + .id('SearchTextCommonEmoji0040') + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0050.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0050.ets new file mode 100644 index 00000000..6151f482 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0050.ets @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0050 { + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0050') + .margin(2) + .width('50%') + .style(TextContentStyle.INLINE) + TextArea() + .id('TextAreaTextCommonEmoji0050') + .margin(2) + .width('50%') + .style(TextContentStyle.INLINE) + Search() + .id('SearchTextCommonEmoji0050') + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0060.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0060.ets new file mode 100644 index 00000000..65160b8b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0060.ets @@ -0,0 +1,48 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0060 { + build() { + Column() { + Text('光标在后,del键删除') + TextInput() + .id('TextInputTextCommonEmoji0060') + .margin(2) + .width('50%') + TextArea() + .id('TextAreaTextCommonEmoji0060') + .margin(2) + .width('50%') + Search() + .id('SearchTextCommonEmoji0060') + .margin(2) + .width('50%') + Text('光标在前,del键删除') + TextInput() + .id('TextInputTextCommonEmoji0060') + .margin(2) + .width('50%') + TextArea() + .id('TextAreaTextCommonEmoji0060') + .margin(2) + .width('50%') + Search() + .id('SearchTextCommonEmoji0060') + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0070.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0070.ets new file mode 100644 index 00000000..e7283811 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0070.ets @@ -0,0 +1,48 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0070 { + build() { + Column() { + Text('光标在后,del键删除') + TextInput() + .id('TextInputTextCommonEmoji0070') + .margin(2) + .width('50%') + TextArea() + .id('TextAreaTextCommonEmoji0070') + .margin(2) + .width('50%') + Search() + .id('SearchTextCommonEmoji0070') + .margin(2) + .width('50%') + Text('光标在前,del键删除') + TextInput() + .id('TextInputTextCommonEmoji0070') + .margin(2) + .width('50%') + TextArea() + .id('TextAreaTextCommonEmoji0070') + .margin(2) + .width('50%') + Search() + .id('SearchTextCommonEmoji0070') + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0080.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0080.ets new file mode 100644 index 00000000..93e1b797 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0080.ets @@ -0,0 +1,50 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0080 { + inputController: TextInputController = new TextInputController(); + textAreaController: TextAreaController = new TextAreaController(); + searchController: SearchController = new SearchController(); + + build() { + Column() { + TextInput({ + controller: this.inputController + }) + .id('TextInputTextCommonEmoji0080') + .margin(2) + .onClick(() => { + this.inputController.setTextSelection(1, 6) + }) + TextArea({ + controller: this.textAreaController + }) + .id('TextAreaTextCommonEmoji0080') + .margin(2) + .onClick(() => { + this.textAreaController.setTextSelection(1, 6) + }) + Search({ + controller: this.searchController + }) + .id('SearchTextCommonEmoji0080') + .margin(2) + .onClick(() => { + this.searchController.setTextSelection(1, 6) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0090.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0090.ets new file mode 100644 index 00000000..0fb05652 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0090.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0090 { + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0090') + .margin(2) + TextArea() + .id('TextAreaTextCommonEmoji0090') + .margin(2) + Search() + .id('SearchTextCommonEmoji0090') + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0100.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0100.ets new file mode 100644 index 00000000..4c9e76cd --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0100.ets @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0100 { + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0100') + .margin(2) + .width('50%') + .style(TextContentStyle.INLINE) + TextArea() + .id('TextAreaTextCommonEmoji0100') + .margin(2) + .width('50%') + .style(TextContentStyle.INLINE) + Search() + .id('SearchTextCommonEmoji0100') + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0110.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0110.ets new file mode 100644 index 00000000..763b95b4 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0110.ets @@ -0,0 +1,38 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0110 { + inputController: TextInputController = new TextInputController(); + textAreaController: TextAreaController = new TextAreaController(); + searchController: SearchController = new SearchController(); + + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0110') + .margin(2) + .width('50%') + TextArea() + .id('TextAreaTextCommonEmoji0110') + .margin(2) + .width('50%') + Search() + .id('SearchTextCommonEmoji0110') + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0120.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0120.ets new file mode 100644 index 00000000..9db05997 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0120.ets @@ -0,0 +1,38 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0120 { + inputController: TextInputController = new TextInputController(); + textAreaController: TextAreaController = new TextAreaController(); + searchController: SearchController = new SearchController(); + + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0120') + .margin(2) + .width('50%') + TextArea() + .id('TextAreaTextCommonEmoji0120') + .margin(2) + .width('50%') + Search() + .id('SearchTextCommonEmoji0120') + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0140.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0140.ets new file mode 100644 index 00000000..d52de7ef --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0140.ets @@ -0,0 +1,50 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0140 { + inputController: TextInputController = new TextInputController(); + textAreaController: TextAreaController = new TextAreaController(); + searchController: SearchController = new SearchController(); + + build() { + Column() { + TextInput({ + controller: this.inputController + }) + .id('TextInputTextCommonEmoji0140') + .margin(2) + .onClick(() => { + this.inputController.setTextSelection(1, 6) + }) + TextArea({ + controller: this.textAreaController + }) + .id('TextAreaTextCommonEmoji0140') + .margin(2) + .onClick(() => { + this.textAreaController.setTextSelection(1, 6) + }) + Search({ + controller: this.searchController + }) + .id('SearchTextCommonEmoji0140') + .margin(2) + .onClick(() => { + this.searchController.setTextSelection(1, 6) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0150.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0150.ets new file mode 100644 index 00000000..45e8d833 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0150.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0150 { + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0150') + .margin(2) + TextArea() + .id('TextAreaTextCommonEmoji0150') + .margin(2) + Search() + .id('SearchTextCommonEmoji0150') + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0160.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0160.ets new file mode 100644 index 00000000..3cddf53e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0160.ets @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0160 { + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0160') + .margin(2) + .width('50%') + .style(TextContentStyle.INLINE) + TextArea() + .id('TextAreaTextCommonEmoji0160') + .margin(2) + .width('50%') + .style(TextContentStyle.INLINE) + Search() + .id('SearchTextCommonEmoji0160') + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0180.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0180.ets new file mode 100644 index 00000000..07db8c59 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0180.ets @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0180 { + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0180') + .margin(2) + .width('50%') + TextArea() + .id('TextAreaTextCommonEmoji0180') + .margin(2) + .width('50%') + Search() + .id('SearchTextCommonEmoji0180') + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0200.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0200.ets new file mode 100644 index 00000000..6c077dc3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0200.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0200 { + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0200') + .margin(2) + TextArea() + .id('TextAreaTextCommonEmoji0200') + .margin(2) + Search() + .id('SearchTextCommonEmoji0200') + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0210.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0210.ets new file mode 100644 index 00000000..9bece501 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0210.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0210 { + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0210') + .margin(2) + TextArea() + .id('TextAreaTextCommonEmoji0210') + .margin(2) + Search() + .id('SearchTextCommonEmoji0210') + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0220.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0220.ets new file mode 100644 index 00000000..3d14f154 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0220.ets @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0220 { + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0220') + .margin(2) + .width('50%') + TextArea() + .id('TextAreaTextCommonEmoji0220') + .margin(2) + .width('50%') + Search() + .id('SearchTextCommonEmoji0220') + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0230.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0230.ets new file mode 100644 index 00000000..eb423ddd --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0230.ets @@ -0,0 +1,26 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0230 { + build() { + Column() { + TextArea() + .id('TextAreaTextCommonEmoji0230') + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0240.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0240.ets new file mode 100644 index 00000000..2afa722d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0240.ets @@ -0,0 +1,26 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0240 { + build() { + Column() { + TextArea() + .id('TextAreaTextCommonEmoji0240') + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0250.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0250.ets new file mode 100644 index 00000000..6d397f4a --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0250.ets @@ -0,0 +1,60 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonEmoji0250 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + build() { + Column() { + TextInput() + .id('TextInputTextCommonEmoji0250') + .margin(2) + TextArea() + .id('TextAreaTextCommonEmoji0250') + .margin(2) + Search() + .id('SearchTextCommonEmoji0250') + .margin(2) + Button('切换横竖屏') + .id('ButtonTextCommonEmoji0250') + .onClick(() => { + this.changeOrientation(true); + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0270.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0270.ets new file mode 100644 index 00000000..fe1d81b2 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0270.ets @@ -0,0 +1,50 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonEmoji0270 { + @State textInputOnChange: string = ''; + @State textAreaOnChange: string = ''; + @State searchOnChange: string = ''; + + build() { + Column() { + Text(`${this.textInputOnChange}`) + TextInput() + .id('TextInputTextCommonEmoji0270') + .margin(2) + .width('50%') + .onChange(() => { + this.textInputOnChange = '已删除' + }) + Text(`${this.textAreaOnChange}`) + TextArea() + .id('TextAreaTextCommonEmoji0270') + .margin(2) + .width('50%') + .onChange(() => { + this.textAreaOnChange = '已删除' + }) + Text(`${this.searchOnChange}`) + Search() + .id('SearchTextCommonEmoji0270') + .margin(2) + .width('50%') + .onChange(() => { + this.searchOnChange = '已删除' + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0010.ets new file mode 100644 index 00000000..ee8075fd --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0010.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0010 { + build() { + Column() { + TextInput() + .id('textInputTextCommonMenuAvoid0010') + .width('60%') + .height(40) + .fontSize(25) + .margin({ + top: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0020.ets new file mode 100644 index 00000000..be5bea1a --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0020.ets @@ -0,0 +1,27 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0020 { + build() { + Column() { + TextInput() + .id('textInputTextCommonMenuAvoid0020') + .width('60%') + .height(40) + .fontSize(25) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0030.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0030.ets new file mode 100644 index 00000000..5b969efc --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0030.ets @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0030 { + build() { + Column() { + TextInput() + .id('textInputTextCommonMenuAvoid0030') + .width('60%') + .height(40) + .fontSize(25) + .margin({ + bottom:200 + }) + } + .alignItems(HorizontalAlign.Center) + .width('100%') + .height('100%') + .justifyContent(FlexAlign.End) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0040.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0040.ets new file mode 100644 index 00000000..d496a78a --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0040.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0040 { + build() { + Column() { + TextInput() + .id('textInputTextCommonMenuAvoid0040') + .width('60%') + .height(40) + .fontSize(25) + .margin({ + top:200 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0050.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0050.ets new file mode 100644 index 00000000..5b3699a2 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0050.ets @@ -0,0 +1,27 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0050 { + build() { + Column() { + TextInput() + .id('textInputTextCommonMenuAvoid0050') + .width('60%') + .height(40) + .fontSize(25) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0060.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0060.ets new file mode 100644 index 00000000..d22e5ccb --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0060.ets @@ -0,0 +1,27 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0060 { + build() { + Column() { + TextInput() + .id('textInputTextCommonMenuAvoid0060') + .width('60%') + .height(40) + .fontSize(25) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0070.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0070.ets new file mode 100644 index 00000000..02791567 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0070.ets @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0070 { + build() { + Column() { + TextInput() + .id('textInputTextCommonMenuAvoid0070') + .width('60%') + .height(40) + .fontSize(25) + .margin({ + bottom:100 + }) + } + .alignItems(HorizontalAlign.Center) + .width('100%') + .height('100%') + .justifyContent(FlexAlign.Center) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0080.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0080.ets new file mode 100644 index 00000000..88b234bb --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0080.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0080 { + build() { + Column() { + TextInput() + .id('textInputTextCommonMenuAvoid0080') + .width('70%') + .height(100) + .fontSize(25) + .margin({ + top:200, + left:20 + }) + } + .alignItems(HorizontalAlign.Start) + .width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0090.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0090.ets new file mode 100644 index 00000000..eb65d39a --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0090.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0090 { + build() { + Column() { + TextInput() + .id('textInputTextCommonMenuAvoid0090') + .width('70%') + .height(100) + .fontSize(25) + .margin({ + top:200, + right:20 + }) + } + .alignItems(HorizontalAlign.End) + .width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0100.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0100.ets new file mode 100644 index 00000000..d219d695 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0100.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0100 { + build() { + Column() { + TextInput() + .id('textInputTextCommonMenuAvoid0100') + .width('70%') + .height(100) + .fontSize(25) + .margin({ + left:20 + }) + } + .alignItems(HorizontalAlign.Start) + .width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0110.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0110.ets new file mode 100644 index 00000000..14a3be46 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0110.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0110 { + build() { + Column() { + TextInput() + .id('textInputTextCommonMenuAvoid0110') + .width('70%') + .height(100) + .fontSize(25) + .margin({ + right:20 + }) + } + .alignItems(HorizontalAlign.End) + .width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0120.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0120.ets new file mode 100644 index 00000000..ebd69183 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0120.ets @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0120 { + build() { + Column() { + TextInput() + .id('textInputTextCommonMenuAvoid0120') + .width('70%') + .height(100) + .fontSize(25) + .margin({ + bottom:300 + }) + } + .alignItems(HorizontalAlign.Center) + .justifyContent(FlexAlign.End) + .width('100%') + .height('90%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0130.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0130.ets new file mode 100644 index 00000000..1ccca05e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0130.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0130 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonMenuAvoid0130') + .width('60%') + .height(40) + .fontSize(25) + .margin({ + top: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0140.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0140.ets new file mode 100644 index 00000000..84f52146 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0140.ets @@ -0,0 +1,27 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0140 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonMenuAvoid0140') + .width('60%') + .height(40) + .fontSize(25) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0150.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0150.ets new file mode 100644 index 00000000..0097f2f3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0150.ets @@ -0,0 +1,40 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { KeyboardAvoidMode } from '@kit.ArkUI'; + +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0150 { + aboutToAppear() { + this.getUIContext().setKeyboardAvoidMode(KeyboardAvoidMode.OFFSET); + } + + build() { + Column() { + TextArea() + .id('textAreaTextCommonMenuAvoid0150') + .width('60%') + .fontSize(25) + .margin({ + bottom: 150 + }) + .maxLines(1) + } + .alignItems(HorizontalAlign.Center) + .width('100%') + .height('100%') + .justifyContent(FlexAlign.End) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0160.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0160.ets new file mode 100644 index 00000000..effb464c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0160.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0160 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonMenuAvoid0160') + .width('60%') + .height(40) + .fontSize(25) + .margin({ + top:200 + }) + .maxLines(4) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0170.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0170.ets new file mode 100644 index 00000000..903e5f4b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0170.ets @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0170 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonMenuAvoid0170') + .width('60%') + .height(40) + .fontSize(25) + .maxLines(4) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0180.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0180.ets new file mode 100644 index 00000000..6d7adcc9 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0180.ets @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0180 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonMenuAvoid0180') + .width('60%') + .height(60) + .fontSize(25) + .maxLines(4) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0190.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0190.ets new file mode 100644 index 00000000..0462fc8e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0190.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0190 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonMenuAvoid0190') + .width('60%') + .height(60) + .fontSize(25) + .maxLines(4) + .margin({ + top:350 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0200.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0200.ets new file mode 100644 index 00000000..450e31b2 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0200.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0200 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonMenuAvoid0200') + .width('60%') + .height(60) + .fontSize(25) + .maxLines(4) + .margin({ + top: 350, + left: 35 + }) + }.alignItems(HorizontalAlign.Start).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0210.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0210.ets new file mode 100644 index 00000000..e5264b60 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0210.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0210 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonMenuAvoid0210') + .width('60%') + .height(60) + .fontSize(25) + .maxLines(4) + .margin({ + top: 350, + right: 35 + }) + }.alignItems(HorizontalAlign.End).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0220.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0220.ets new file mode 100644 index 00000000..1b87b9de --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0220.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0220 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonMenuAvoid0220') + .width('60%') + .height(60) + .fontSize(25) + .maxLines(4) + .margin({ + left: 35 + }) + }.alignItems(HorizontalAlign.Start).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0230.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0230.ets new file mode 100644 index 00000000..9b342ce2 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0230.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0230 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonMenuAvoid0230') + .width('60%') + .height(60) + .fontSize(25) + .maxLines(4) + .margin({ + right: 35 + }) + }.alignItems(HorizontalAlign.End).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0250.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0250.ets new file mode 100644 index 00000000..cc70470e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0250.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0250 { + build() { + Column() { + TextInput() + .id('textInputTextCommonMenuAvoid0250') + .width('60%') + .height(40) + .fontSize(25) + .style(TextContentStyle.INLINE) + .margin({ + top: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0260.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0260.ets new file mode 100644 index 00000000..ed6fc0dc --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0260.ets @@ -0,0 +1,49 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0260 { + controller: TextInputController = new TextInputController(); + + build() { + Column() { + TextInput({ + controller: this.controller + }) + .id('textInputTextCommonMenuAvoid0260') + .width('80%') + .height(40) + .fontSize(25) + .margin({ + top: 100 + }) + Button('start,end选中') + .id('btnTextCommonMenuAvoid0260') + .margin(1) + .onClick(() => { + this.controller.setTextSelection(0, 2, { + menuPolicy: MenuPolicy.SHOW + }) + }) + Button('start,end改变') + .id('btnChangeTextInputTextCommonMenuAvoid0260') + .onClick(() => { + this.controller.setTextSelection(5, 8, { + menuPolicy: MenuPolicy.SHOW + }) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0270.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0270.ets new file mode 100644 index 00000000..2aed0f7e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0270.ets @@ -0,0 +1,68 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0270 { + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State height1: string | number = 200 + @State supportAvoidance: boolean = true + + // 自定义键盘组件 + @Builder + CustomKeyboardBuilder() { + Column() { + Row() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }).margin(10) + } + + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray).height(this.height1) + } + + build() { + Column() { + TextInput({ + controller: this.controller + }) + .id('textInputTextCommonMenuAvoid0270') + .width('80%') + .height(40) + .fontSize(25) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + .margin(10) + .border({ width: 1 }) + Button('改变自定义键盘高度') + .id('btnTextCommonMenuAvoid0270') + .onClick(() => { + this.height1 = 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + .justifyContent(FlexAlign.End) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0280.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0280.ets new file mode 100644 index 00000000..25f2601f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0280.ets @@ -0,0 +1,43 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0280 { + controller: TextInputController = new TextInputController(); + @State textIndent: number | undefined = undefined; + + build() { + Column() { + TextInput({ + controller: this.controller + }) + .id('textInputTextCommonMenuAvoid0280') + .width('80%') + .height(40) + .fontSize(25) + .margin({ + top: 200 + }) + .border({ width: 1 }) + .textIndent(this.textIndent) + Button('改变缩进值') + .id('btnTextCommonMenuAvoid0280') + .onClick(() => { + this.textIndent = 5 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0290.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0290.ets new file mode 100644 index 00000000..b56c27ab --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0290.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0290 { + controller: TextInputController = new TextInputController(); + @State fontSize: number | undefined = 14; + + build() { + Column() { + TextInput({ + controller: this.controller + }) + .id('textInputTextCommonMenuAvoid0290') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .border({ width: 1 }) + .fontSize(this.fontSize) + Button('改变字体大小') + .id('btnTextCommonMenuAvoid0290') + .onClick(() => { + this.fontSize = 25 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0300.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0300.ets new file mode 100644 index 00000000..2b96ea45 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0300.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0300 { + controller: TextInputController = new TextInputController(); + @State letterSpacing: number | undefined = 1; + + build() { + Column() { + TextInput({ + controller: this.controller + }) + .id('textInputTextCommonMenuAvoid0300') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .border({ width: 1 }) + .letterSpacing(this.letterSpacing) + Button('改变letterSpacing') + .id('btnTextCommonMenuAvoid0300') + .onClick(() => { + this.letterSpacing = 3 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0310.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0310.ets new file mode 100644 index 00000000..2e5b65fe --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0310.ets @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0310 { + build() { + Column() { + TextInput() + .id('textInputTextCommonMenuAvoid0310') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .border({ width: 1 }) + .cancelButton({ + style:CancelButtonStyle.INPUT + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0320.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0320.ets new file mode 100644 index 00000000..04177af0 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0320.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0320 { + build() { + Column() { + TextInput() + .id('textInputTextCommonMenuAvoid0320') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .border({ width: 1 }) + .type(InputType.Password) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0330.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0330.ets new file mode 100644 index 00000000..134d232e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0330.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0330 { + controller: TextInputController = new TextInputController(); + @State textAlign: number | undefined = TextAlign.Start; + + build() { + Column() { + TextInput({ + controller: this.controller + }) + .id('textInputTextCommonMenuAvoid0330') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .border({ width: 1 }) + .textAlign(this.textAlign) + Button('改变TextAlign') + .id('btnTextCommonMenuAvoid0330') + .onClick(() => { + this.textAlign = TextAlign.End + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0340.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0340.ets new file mode 100644 index 00000000..119d14c1 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0340.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0340 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonMenuAvoid0340') + .width('60%') + .height(40) + .fontSize(25) + .style(TextContentStyle.INLINE) + .margin({ + top: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0350.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0350.ets new file mode 100644 index 00000000..59980cd7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0350.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0350 { + controller: TextAreaController = new TextAreaController(); + + build() { + Column() { + TextArea({ + controller: this.controller + }) + .id('textAreaTextCommonMenuAvoid0350') + .width('50%') + .fontSize(50) + .margin({ + top: 100 + }) + .maxLines(1) + .textOverflow(TextOverflow.Ellipsis) + Button('选中省略号') + .id('btnTextCommonMenuAvoid0350') + .onClick(() => { + this.controller.setTextSelection(5, 9, { + menuPolicy: MenuPolicy.SHOW + }) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0360.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0360.ets new file mode 100644 index 00000000..edc502d9 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0360.ets @@ -0,0 +1,49 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0360 { + controller: TextInputController = new TextInputController(); + + build() { + Column() { + TextArea({ + controller: this.controller + }) + .id('textAreaTextCommonMenuAvoid0360') + .width('80%') + .height(40) + .fontSize(25) + .margin({ + top: 100 + }) + Button('start,end选中') + .id('btnTextCommonMenuAvoid0360') + .margin(1) + .onClick(() => { + this.controller.setTextSelection(0, 2, { + menuPolicy: MenuPolicy.SHOW + }) + }) + Button('start,end改变') + .id('btnChangeTextInputTextCommonMenuAvoid0360') + .onClick(() => { + this.controller.setTextSelection(5, 8, { + menuPolicy: MenuPolicy.SHOW + }) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0370.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0370.ets new file mode 100644 index 00000000..7b730ea5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0370.ets @@ -0,0 +1,68 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0370 { + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State height1: string | number = 200 + @State supportAvoidance: boolean = true + + // 自定义键盘组件 + @Builder + CustomKeyboardBuilder() { + Column() { + Row() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }).margin(10) + } + + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray).height(this.height1) + } + + build() { + Column() { + TextArea({ + controller: this.controller + }) + .id('textAreaTextCommonMenuAvoid0370') + .width('80%') + .height(40) + .fontSize(25) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + .margin(10) + .border({ width: 1 }) + Button('改变自定义键盘高度') + .id('btnTextCommonMenuAvoid0370') + .onClick(() => { + this.height1 = 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + .justifyContent(FlexAlign.End) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0380.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0380.ets new file mode 100644 index 00000000..329a3500 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0380.ets @@ -0,0 +1,43 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0380 { + controller: TextInputController = new TextInputController(); + @State textIndent: number | undefined = undefined; + + build() { + Column() { + TextArea({ + controller: this.controller + }) + .id('textAreaTextCommonMenuAvoid0380') + .width('80%') + .height(40) + .fontSize(25) + .margin({ + top: 200 + }) + .border({ width: 1 }) + .textIndent(this.textIndent) + Button('改变缩进值') + .id('btnTextCommonMenuAvoid0380') + .onClick(() => { + this.textIndent = 5 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0390.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0390.ets new file mode 100644 index 00000000..f364de2f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0390.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0390 { + controller: TextInputController = new TextInputController(); + @State fontSize: number | undefined = 14; + + build() { + Column() { + TextArea({ + controller: this.controller + }) + .id('textAreaTextCommonMenuAvoid0390') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .border({ width: 1 }) + .fontSize(this.fontSize) + Button('改变字体大小') + .id('btnTextCommonMenuAvoid0390') + .onClick(() => { + this.fontSize = 20 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0400.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0400.ets new file mode 100644 index 00000000..812c8ea5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0400.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0400 { + controller: TextInputController = new TextInputController(); + @State letterSpacing: number | undefined = 1; + + build() { + Column() { + TextArea({ + controller: this.controller + }) + .id('textAreaTextCommonMenuAvoid0400') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .border({ width: 1 }) + .letterSpacing(this.letterSpacing) + Button('改变letterSpacing') + .id('btnTextCommonMenuAvoid0400') + .onClick(() => { + this.letterSpacing = 3 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0410.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0410.ets new file mode 100644 index 00000000..926687c5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0410.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0410 { + controller: TextInputController = new TextInputController(); + @State textAlign: number | undefined = TextAlign.Start; + + build() { + Column() { + TextArea({ + controller: this.controller + }) + .id('textAreaTextCommonMenuAvoid0410') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .border({ width: 1 }) + .textAlign(this.textAlign) + Button('改变TextAlign') + .id('btnTextCommonMenuAvoid0410') + .onClick(() => { + this.textAlign = TextAlign.End + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0420.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0420.ets new file mode 100644 index 00000000..563dc5ec --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0420.ets @@ -0,0 +1,48 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0420 { + controller: SearchController = new SearchController(); + + build() { + Column() { + Search({ + controller: this.controller + }) + .id('SearchTextCommonMenuAvoid0420') + .width('80%') + .height(40) + .margin({ + top: 100 + }) + Button('start,end选中') + .id('btnTextCommonMenuAvoid0420') + .margin(1) + .onClick(() => { + this.controller.setTextSelection(0, 2, { + menuPolicy: MenuPolicy.SHOW + }) + }) + Button('start,end改变') + .id('btnChangeTextInputTextCommonMenuAvoid0420') + .onClick(() => { + this.controller.setTextSelection(5, 8, { + menuPolicy: MenuPolicy.SHOW + }) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0430.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0430.ets new file mode 100644 index 00000000..ad6f82f3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0430.ets @@ -0,0 +1,67 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0430 { + controller: TextInputController = new TextInputController() + @State inputValue: string = "" + @State height1: string | number = 200 + @State supportAvoidance: boolean = true + + // 自定义键盘组件 + @Builder + CustomKeyboardBuilder() { + Column() { + Row() { + Button('x').onClick(() => { + // 关闭自定义键盘 + this.controller.stopEditing() + }).margin(10) + } + + Grid() { + ForEach([1, 2, 3, 4, 5, 6, 7, 8, 9, '*', 0, '#'], (item: number | string) => { + GridItem() { + Button(item + "") + .width(110).onClick(() => { + this.inputValue += item + }) + } + }) + }.maxCount(3).columnsGap(10).rowsGap(10).padding(5) + }.backgroundColor(Color.Gray).height(this.height1) + } + + build() { + Column() { + Search({ + controller: this.controller + }) + .id('SearchTextCommonMenuAvoid0430') + .width('80%') + .height(40) + .customKeyboard(this.CustomKeyboardBuilder(), { supportAvoidance: this.supportAvoidance }) + .margin(10) + .border({ width: 1 }) + Button('改变自定义键盘高度') + .id('btnTextCommonMenuAvoid0430') + .onClick(() => { + this.height1 = 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + .justifyContent(FlexAlign.End) + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0440.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0440.ets new file mode 100644 index 00000000..70c8237e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0440.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0440 { + controller: SearchController = new SearchController(); + @State textIndent: number | undefined = undefined; + + build() { + Column() { + Search({ + controller: this.controller + }) + .id('SearchTextCommonMenuAvoid0440') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .border({ width: 1 }) + .textIndent(this.textIndent) + Button('改变缩进值') + .id('btnTextCommonMenuAvoid0440') + .onClick(() => { + this.textIndent = 5 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0450.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0450.ets new file mode 100644 index 00000000..9b8a7cc8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0450.ets @@ -0,0 +1,44 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0450 { + controller: SearchController = new SearchController(); + @State fontSize: number | undefined = 14; + + build() { + Column() { + Search({ + controller: this.controller + }) + .id('SearchTextCommonMenuAvoid0450') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .border({ width: 1 }) + .textFont({ + size: this.fontSize + }) + Button('改变字体大小') + .id('btnTextCommonMenuAvoid0450') + .onClick(() => { + this.fontSize = 20 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0460.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0460.ets new file mode 100644 index 00000000..68776b48 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0460.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0460 { + controller: SearchController = new SearchController(); + @State letterSpacing: number | undefined = 1; + + build() { + Column() { + Search({ + controller: this.controller + }) + .id('SearchTextCommonMenuAvoid0460') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .border({ width: 1 }) + .letterSpacing(this.letterSpacing) + Button('改变letterSpacing') + .id('btnTextCommonMenuAvoid0460') + .onClick(() => { + this.letterSpacing = 3 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0470.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0470.ets new file mode 100644 index 00000000..d0753eb7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0470.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0470 { + controller: SearchController = new SearchController(); + @State textAlign: number | undefined = TextAlign.Start; + + build() { + Column() { + Search({ + controller: this.controller + }) + .id('SearchTextCommonMenuAvoid0470') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .border({ width: 1 }) + .textAlign(this.textAlign) + Button('改变TextAlign') + .id('btnTextCommonMenuAvoid0470') + .onClick(() => { + this.textAlign = TextAlign.End + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0480.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0480.ets new file mode 100644 index 00000000..ae9c974b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0480.ets @@ -0,0 +1,38 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0480 { + build() { + Column() { + Search() + .id('SearchTextCommonMenuAvoid0480') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .searchButton('SEARCH') + .border({ width: 1 }) + .cancelButton({ + style: CancelButtonStyle.CONSTANT, + icon: { + src: $r('app.media.icon') + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0490.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0490.ets new file mode 100644 index 00000000..b8fcd395 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0490.ets @@ -0,0 +1,50 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0490 { + build() { + Column() { + Search() + .id('SearchTextCommonMenuAvoid0490') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .padding(5) + .border({ width: 1 }) + TextArea() + .id('TextAreaTextCommonMenuAvoid0490') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .padding(5) + .border({ width: 1 }) + TextInput() + .id('TextInputTextCommonMenuAvoid0490') + .width('80%') + .height(40) + .margin({ + top: 200 + }) + .padding(5) + .border({ width: 1 }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0500.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0500.ets new file mode 100644 index 00000000..b193fdf7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0500.ets @@ -0,0 +1,41 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { SystemRouter } from '@kit.ArkUI' + +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0500 { + build() { + Column() { + Search() + .id('SearchTextCommonMenuAvoid0500') + .width('80%') + .height(40) + .border({ width: 1 }) + .expandSafeArea([SafeAreaType.SYSTEM], [SafeAreaEdge.TOP]) + TextArea() + .id('TextAreaTextCommonMenuAvoid0500') + .width('80%') + .height(40) + .border({ width: 1 }) + TextInput() + .id('TextInputTextCommonMenuAvoid0500') + .width('80%') + .height(40) + .border({ width: 1 }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0510.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0510.ets new file mode 100644 index 00000000..5332c7b9 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0510.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0510 { + build() { + Column() { + Scroll(){ + Search() + .id('SearchTextCommonMenuAvoid0510') + .width('80%') + .height(400) + .border({ width: 1 }) + } + .height(300) + TextArea() + .id('TextAreaTextCommonMenuAvoid0510') + .width('80%') + .height(40) + .border({ width: 1 }) + TextInput() + .id('TextInputTextCommonMenuAvoid0510') + .width('80%') + .height(40) + .border({ width: 1 }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0520.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0520.ets new file mode 100644 index 00000000..560282a7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0520.ets @@ -0,0 +1,62 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; +let portraitFunc = null; +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0520 { + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + build() { + Column() { + Search() + .id('SearchTextCommonMenuAvoid0520') + .width('80%') + .height(40) + .border({ width: 1 }) + TextArea() + .id('TextAreaTextCommonMenuAvoid0520') + .width('80%') + .height(40) + .border({ width: 1 }) + TextInput() + .id('TextInputTextCommonMenuAvoid0520') + .width('80%') + .height(40) + .border({ width: 1 }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0530.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0530.ets new file mode 100644 index 00000000..617c52d6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0530.ets @@ -0,0 +1,48 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0530 { + controller: SearchController = new SearchController(); + + build() { + Column() { + Search({ + controller: this.controller + }) + .id('SearchTextCommonMenuAvoid0530') + .width('80%') + .height(40) + .border({ width: 1 }) + TextArea() + .id('TextAreaTextCommonMenuAvoid0530') + .width('80%') + .height(40) + .border({ width: 1 }) + TextInput() + .id('TextInputTextCommonMenuAvoid0530') + .width('80%') + .height(40) + .border({ width: 1 }) + Button('选中文本') + .id('btnTextCommonMenuAvoid0530') + .onClick(() => { + this.controller.setTextSelection(0, 20); + }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0540.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0540.ets new file mode 100644 index 00000000..76441f97 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0540.ets @@ -0,0 +1,39 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonMenuAvoid0540 { + @State text: string = '0' + + build() { + Column() { + Text(this.text) + TextArea() + .id('textAreaTextCommonMenuAvoid0540') + .width('80%') + .height(40) + .border({ width: 1 }) + .onContentScroll(() => { + this.text += 1; + }) + TextInput() + .id('TextInputTextCommonMenuAvoid0540') + .width('80%') + .height(40) + .border({ width: 1 }) + }.alignItems(HorizontalAlign.Center).width('100%') + .height('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0010.ets new file mode 100644 index 00000000..7116e183 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0010.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0010 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0010') + .maxLines(10) + .style(TextInputStyle.Inline) + .width('50%') + .height(40) + .fontSize(25) + .margin({ + top: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0020.ets new file mode 100644 index 00000000..facd8aa1 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0020.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0020 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0020') + .maxLines(11) + .style(TextInputStyle.Inline) + .width('50%') + .height(40) + .fontSize(30) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0030.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0030.ets new file mode 100644 index 00000000..a056ab42 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0030.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0030 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0030') + .maxLines(3) + .style(TextInputStyle.Inline) + .width('50%') + .height(40) + .margin({ + top: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0040.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0040.ets new file mode 100644 index 00000000..0a600250 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0040.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0040 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0040') + .maxLines(3) + .style(TextInputStyle.Inline) + .width('50%') + .padding({ + bottom: 100, + }) + .height(40) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0050.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0050.ets new file mode 100644 index 00000000..8af70aba --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0050.ets @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0050 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0050') + .maxLines(3) + .style(TextInputStyle.Inline) + .width('50%') + .padding({ + top: 100, + bottom: 100, + }) + .height(40) + .margin({ + top: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0060.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0060.ets new file mode 100644 index 00000000..b0fecdb6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0060.ets @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0060 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0060') + .maxLines(10) + .style(TextInputStyle.Inline) + .width('50%') + .padding({ + top: 100, + }) + .fontSize(25) + .height(40) + .margin({ + top: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0070.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0070.ets new file mode 100644 index 00000000..9dff813e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0070.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0070 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0070') + .maxLines(5) + .style(TextInputStyle.Inline) + .width('50%') + .padding({ + bottom: 100, + }) + .fontSize(20) + .height(40) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0080.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0080.ets new file mode 100644 index 00000000..086890e2 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0080.ets @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0080 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0080') + .maxLines(11) + .style(TextInputStyle.Inline) + .width('50%') + .padding({ + top: 0, + bottom: 0, + }) + .height(40) + .fontSize(30) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0090.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0090.ets new file mode 100644 index 00000000..7ebcc723 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0090.ets @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0090 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0090') + .maxLines(6) + .style(TextInputStyle.Inline) + .width('50%') + .padding({ + top: 100, + bottom: 100, + }) + .height(50) + .margin({ + top:100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0100.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0100.ets new file mode 100644 index 00000000..de2c5ce2 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0100.ets @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0100 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0100') + .maxLines(6) + .style(TextInputStyle.Inline) + .width('50%') + .padding({ + top: 100, + }) + .height(50) + .margin({ + top:100 + }) + .fontSize(25) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0110.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0110.ets new file mode 100644 index 00000000..ac2cf2ef --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0110.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0110 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0110') + .maxLines(6) + .style(TextInputStyle.Inline) + .width('50%') + .padding({ + bottom: 100, + }) + .height(50) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0120.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0120.ets new file mode 100644 index 00000000..a1429461 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0120.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0120 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0120') + .maxLines(10) + .style(TextInputStyle.Inline) + .width('50%') + .height(50) + .fontSize(30) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0130.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0130.ets new file mode 100644 index 00000000..857603c6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0130.ets @@ -0,0 +1,37 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0130 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0130') + .maxLines(6) + .style(TextInputStyle.Inline) + .width('50%') + .height(50) + .margin({ + top: 100 + }) + .padding({ + top: 100, + bottom: 0 + }) + .fontSize(25) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0140.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0140.ets new file mode 100644 index 00000000..50bd7b01 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0140.ets @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0140 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0140') + .maxLines(6) + .style(TextInputStyle.Inline) + .width('50%') + .height(50) + .margin({ + top: 100 + }) + .padding({ + top: 100, + bottom: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0150.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0150.ets new file mode 100644 index 00000000..618c2e8b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0150.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0150 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0150') + .maxLines(6) + .style(TextInputStyle.Inline) + .width('50%') + .height(50) + .padding({ + top: 0, + bottom: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0160.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0160.ets new file mode 100644 index 00000000..6e494a94 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0160.ets @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0160 { + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0160') + .maxLines(11) + .style(TextInputStyle.Inline) + .width('50%') + .height(50) + .padding({ + top: 0, + bottom: 0 + }) + .fontSize(30) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0170.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0170.ets new file mode 100644 index 00000000..d804abac --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0170.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0170 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0170') + .style(TextContentStyle.INLINE) + .width('50%') + .height(100) + .margin({ + top: 100 + }) + .fontSize(20) + .maxLines(11) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0180.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0180.ets new file mode 100644 index 00000000..71cbcd8e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0180.ets @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0180 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0180') + .style(TextContentStyle.INLINE) + .width('50%') + .height(100) + .padding({ + top: 0, + bottom: 0 + }) + .fontSize(30) + .maxLines(11) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0190.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0190.ets new file mode 100644 index 00000000..6fb0374f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0190.ets @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0190 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0190') + .style(TextContentStyle.INLINE) + .width('50%') + .height(100) + .margin({ + top: 100 + }) + .padding({ + top: 40, + bottom: 40 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0200.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0200.ets new file mode 100644 index 00000000..2009ca1e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0200.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0200 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0200') + .style(TextContentStyle.INLINE) + .width('50%') + .height(200) + .padding({ + bottom: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0210.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0210.ets new file mode 100644 index 00000000..cc75047f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0210.ets @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0210 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0210') + .style(TextContentStyle.INLINE) + .width('50%') + .maxLines(5) + .height(210) + .padding({ + bottom: 100 + }) + .margin({ + top: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0220.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0220.ets new file mode 100644 index 00000000..caa04851 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0220.ets @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0220 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0220') + .style(TextContentStyle.INLINE) + .width('50%') + .maxLines(5) + .height(200) + .padding({ + bottom: 100 + }) + .margin({ + top: 200 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0230.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0230.ets new file mode 100644 index 00000000..5bb50d18 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0230.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0230 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0230') + .style(TextContentStyle.INLINE) + .width('50%') + .maxLines(5) + .height(200) + .padding({ + bottom: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0240.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0240.ets new file mode 100644 index 00000000..d75daacf --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0240.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0240 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0240') + .style(TextContentStyle.INLINE) + .fontSize(40) + .width('50%') + .maxLines(10) + .height(200) + .padding({ + bottom: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0250.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0250.ets new file mode 100644 index 00000000..b7c94767 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0250.ets @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0250 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0250') + .style(TextContentStyle.INLINE) + .fontSize(25) + .width('50%') + .maxLines(4) + .height(200) + .padding({ + bottom: 100 + }) + .margin({ + top:100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0260.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0260.ets new file mode 100644 index 00000000..38b1ec45 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0260.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0260 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0260') + .style(TextContentStyle.INLINE) + .fontSize(25) + .width('50%') + .maxLines(9) + .height(200) + .margin({ + top:100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0270.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0270.ets new file mode 100644 index 00000000..558e0652 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0270.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0270 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0270') + .style(TextContentStyle.INLINE) + .fontSize(25) + .width('50%') + .maxLines(9) + .height(200) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0280.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0280.ets new file mode 100644 index 00000000..e5f4e6aa --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0280.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0280 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0280') + .style(TextContentStyle.INLINE) + .fontSize(30) + .width('50%') + .maxLines(10) + .height(200) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0290.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0290.ets new file mode 100644 index 00000000..52037a16 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0290.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0290 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0290') + .style(TextContentStyle.INLINE) + .fontSize(25) + .width('50%') + .maxLines(10) + .height(200) + .margin({ + top: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0300.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0300.ets new file mode 100644 index 00000000..f56b3f39 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0300.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0300 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0300') + .style(TextContentStyle.INLINE) + .fontSize(25) + .width('50%') + .maxLines(10) + .height(200) + .margin({ + top: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0310.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0310.ets new file mode 100644 index 00000000..daa3e0d1 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0310.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0310 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0310') + .style(TextContentStyle.INLINE) + .fontSize(25) + .width('50%') + .maxLines(10) + .height(200) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0320.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0320.ets new file mode 100644 index 00000000..39aac134 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0320.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0320 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0320') + .style(TextContentStyle.INLINE) + .fontSize(25) + .width('50%') + .height(200) + .maxLines(14) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0330.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0330.ets new file mode 100644 index 00000000..d1931f25 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0330.ets @@ -0,0 +1,64 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0330 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + @State fontSize: number = 25; + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0330') + .style(TextContentStyle.INLINE) + .fontSize(this.fontSize) + .width('50%') + .maxLines(14) + .onClick(() => { + this.fontSize = 18; + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0340.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0340.ets new file mode 100644 index 00000000..54d5ba00 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0340.ets @@ -0,0 +1,64 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0340 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + @State fontSize: number = 25; + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0340') + .style(TextContentStyle.INLINE) + .fontSize(this.fontSize) + .width('50%') + .maxLines(8) + .onClick(() => { + this.fontSize = 18; + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0350.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0350.ets new file mode 100644 index 00000000..e0444431 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0350.ets @@ -0,0 +1,64 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0350 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + @State fontSize: number = 25; + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0350') + .style(TextContentStyle.INLINE) + .fontSize(this.fontSize) + .width('50%') + .maxLines(8) + .onClick(() => { + this.fontSize = 18; + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0360.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0360.ets new file mode 100644 index 00000000..42f2d08b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0360.ets @@ -0,0 +1,64 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0360 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + @State fontSize: number = 25; + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0360') + .style(TextContentStyle.INLINE) + .fontSize(this.fontSize) + .width('50%') + .maxLines(8) + .onClick(() => { + this.fontSize = 18; + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0370.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0370.ets new file mode 100644 index 00000000..2ce74f44 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0370.ets @@ -0,0 +1,40 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0370 { + controller: TextInputController = new TextInputController(); + build() { + Scroll() { + Column() { + TextInput({ + text: 'adawdawdawdwa', + controller: this.controller + }) + .id('textInputTextCommonQuanXuanCaiDan0370') + .maxLines(10) + .width('100%') + .height(600) + .fontSize(25) + .margin({ + top: 100 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } + .width('50%') + .height(500) + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0380.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0380.ets new file mode 100644 index 00000000..259537e3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0380.ets @@ -0,0 +1,39 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0380 { + @State textIndent: number | undefined = undefined; + + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0380') + .fontSize(25) + .width('50%') + .maxLines(9) + .textIndent(this.textIndent) + .margin({ + top: 100 + }) + Button('改变缩进值') + .id('btnTextCommonQuanXuanCaiDan0380') + .onClick(() => { + this.textIndent = 10; + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0390.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0390.ets new file mode 100644 index 00000000..7e06b00a --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0390.ets @@ -0,0 +1,46 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { KeyboardAvoidMode } from '@kit.ArkUI'; +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0390 { + build() { + Column() { + TextArea() + .id('textAreaTextCommonQuanXuanCaiDan0390') + .fontSize(25) + .width('50%') + .maxLines(9) + Button('切换键盘避让模式为抬起') + .id('btnTextCommonQuanXuanCaiDan0390UP') + .onClick(() => { + this.getUIContext().setKeyboardAvoidMode(KeyboardAvoidMode.OFFSET); + }) + Button('切换键盘避让模式为压缩') + .id('btnTextCommonQuanXuanCaiDan0390') + .onClick(() => { + this.getUIContext().setKeyboardAvoidMode(KeyboardAvoidMode.RESIZE); + }) + .margin({ + bottom:200 + }) + } + .width('100%') + .height('100%') + .alignItems(HorizontalAlign.Center) + .justifyContent(FlexAlign.End) + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0400.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0400.ets new file mode 100644 index 00000000..cc7e5576 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0400.ets @@ -0,0 +1,48 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0400 { + build() { + Column() { + TextInput() + .id('TextInputTextCommonQuanXuanCaiDan0400') + .fontSize(25) + .width('50%') + .maxLines(9) + .margin({ + top: 100 + }) + .cancelButton({ + style: CancelButtonStyle.CONSTANT, + icon: { + size: 50, + src: 'cat.jpg', + color: Color.Blue + } + }) + Search() + .id('SearchTextCommonQuanXuanCaiDan0400') + .width('50%') + .searchIcon({ + size: 60, + src: 'cat.jpg', + }) + } + .width('100%') + .height('100%') + .alignItems(HorizontalAlign.Center) + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0410.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0410.ets new file mode 100644 index 00000000..d9c96083 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0410.ets @@ -0,0 +1,64 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; + +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextCommonQuanXuanCaiDan0410 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + @State fontSize: number = 25; + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + + build() { + Column() { + TextInput() + .id('textInputTextCommonQuanXuanCaiDan0410') + .style(TextContentStyle.INLINE) + .fontSize(this.fontSize) + .width('50%') + .maxLines(8) + .onClick(() => { + this.fontSize = 18; + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0010.ets new file mode 100644 index 00000000..be177d70 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0010.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0010 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0010') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .type(InputType.Normal) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0020.ets new file mode 100644 index 00000000..1f2c2853 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0020.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0020 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0020') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .type(InputType.Password) + .showPassword(true) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0030.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0030.ets new file mode 100644 index 00000000..ef2e7b71 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0030.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0030 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0030') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .type(InputType.Password) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0040.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0040.ets new file mode 100644 index 00000000..28cf5975 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0040.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0040 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0040') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .type(InputType.NEW_PASSWORD) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0050.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0050.ets new file mode 100644 index 00000000..e87cd4b6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0050.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0050 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0050') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .type(InputType.NEW_PASSWORD) + .showPassword(true) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0060.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0060.ets new file mode 100644 index 00000000..0f8dc25f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0060.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0060 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0060') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .type(InputType.SCREEN_LOCK_PASSWORD) + .showPassword(true) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0070.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0070.ets new file mode 100644 index 00000000..8ba8b721 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0070.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0070 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0070') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .type(InputType.SCREEN_LOCK_PASSWORD) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0080.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0080.ets new file mode 100644 index 00000000..0a09e358 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0080.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0080 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0080') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .type(InputType.NUMBER_PASSWORD) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0090.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0090.ets new file mode 100644 index 00000000..645f4db0 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0090.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0090 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0090') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .type(InputType.NUMBER_PASSWORD) + .showPassword(true) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0100.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0100.ets new file mode 100644 index 00000000..be3b8cd1 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0100.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0100 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0100') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .style(TextContentStyle.INLINE) + .maxLines(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0110.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0110.ets new file mode 100644 index 00000000..4d8df3de --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0110.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0110 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0110') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .style(TextContentStyle.INLINE) + .maxLines(5) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0120.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0120.ets new file mode 100644 index 00000000..e2fe2a38 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0120.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0120 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0120') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .selectionMenuHidden(false) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0130.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0130.ets new file mode 100644 index 00000000..6e0f2a98 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0130.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0130 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0130') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .selectionMenuHidden(true) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0140.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0140.ets new file mode 100644 index 00000000..d0fc17cd --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0140.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0140 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0140') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .cancelButton({ + style:CancelButtonStyle.INPUT + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0150.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0150.ets new file mode 100644 index 00000000..48ec54ce --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0150.ets @@ -0,0 +1,51 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0150 { + @Builder itemEnd() { + Select([{ value: 'KB' }, + { value: 'MB' }, + { value: 'GB' }, + { value: 'TB', }]) + .height("48vp") + .borderRadius(0) + .selected(2) + .align(Alignment.Center) + .value('MB') + .font({ size: 20, weight: 500 }) + .fontColor('#182431') + .selectedOptionFont({ size: 20, weight: 400 }) + .optionFont({ size: 20, weight: 400 }) + .backgroundColor(Color.Transparent) + .responseRegion({ height: "40vp", width: "80%", x: '10%', y: '6vp' }) + .onSelect((index: number) => { + console.info('Select:' + index) + }) + } + build() { + Column() { + TextInput() + .id('textInputTextImprove0150') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .showUnderline(true) + .showUnit(this.itemEnd) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0160.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0160.ets new file mode 100644 index 00000000..fe77d6ee --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0160.ets @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0160 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0160') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0170.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0170.ets new file mode 100644 index 00000000..6004a966 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0170.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0170 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0170') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .caretPosition(5) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0180.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0180.ets new file mode 100644 index 00000000..339fcdff --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0180.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextImprove0180 { + build() { + Column() { + TextInput() + .id('textInputTextImprove0180') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .caretPosition(5) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize008.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize008.ets new file mode 100644 index 00000000..c4c981df --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize008.ets @@ -0,0 +1,33 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize008 { + build() { + Column() { + Search() + .id('searchFontSize008') + .width('80%').height(90).borderWidth(1) + .minFontSize(10) + .maxFontSize(30) + Search() + .id('searchFontSize008') + .width('80%').height(90).borderWidth(1) + .minFontSize(10) + .maxFontSize(30) + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize009.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize009.ets new file mode 100644 index 00000000..2a2b05cc --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize009.ets @@ -0,0 +1,33 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize009 { + build() { + Column() { + Search() + .id('searchFontSize009') + .width('80%').height(90).borderWidth(1) + .minFontSize(10) + .maxFontSize(30) + Search() + .id('searchFontSize009') + .width('80%').height(90).borderWidth(1) + .minFontSize(10) + .maxFontSize(30) + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize010.ets new file mode 100644 index 00000000..d05f7032 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize010.ets @@ -0,0 +1,33 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize010 { + build() { + Column() { + Search() + .id('searchFontSize010') + .width('80%').height(90).borderWidth(1) + .minFontSize(30) + .maxFontSize(12) + Search() + .id('searchFontSizeLong010') + .width('80%').height(90).borderWidth(1) + .minFontSize(30) + .maxFontSize(12) + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize011.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize011.ets new file mode 100644 index 00000000..3b23af77 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize011.ets @@ -0,0 +1,46 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize011 { + build() { + Column() { + TextArea({ + text:'ABC priorities.' + }) + .id('searchFontSize011TextArea1') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .height(40).margin(10).border({ width: 1 }) + .width('50%') + .minFontSize(10) + .maxFontSize(30) + TextArea() + .id('searchFontSize011TextArea2') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .height(40).margin(10).border({ width: 1 }) + .width('50%') + .minFontSize(10) + .maxFontSize(30) + TextArea() + .id('searchFontSize011TextArea3') + .width('50%') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .height(40).margin(10).border({ width: 1 }) + .minFontSize(10) + .maxFontSize(30) + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize012.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize012.ets new file mode 100644 index 00000000..35734828 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize012.ets @@ -0,0 +1,69 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize012 { + @State minFontSize: number | undefined = 10; + @State maxFontSize: number | undefined = 30; + @State text: string = 'ABC priorities.Sometimes,asignificant change Change' + + build() { + Column() { + TextArea({ + text: this.text + }) + .id('searchFontSize012TextArea1') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MIN_FONT_SIZE_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .minFontSize(this.minFontSize) + .maxFontSize(this.maxFontSize) + .fontSize(16) + Button('改变maxfontsize { + this.minFontSize = 30; + this.maxFontSize = 10; + }) + Button('改变maxfontsize=minFontSize').margin(1) + .id('ButtonChange2') + .onClick(() => { + this.minFontSize = 10; + this.maxFontSize = 10; + }) + Button('改变maxfontsize=minFontSize=undefined').margin(1) + .id('ButtonChange3') + .onClick(() => { + this.minFontSize = undefined; + this.maxFontSize = undefined; + }) + Button('maxFontSize=undefined,minFontSize=10').margin(1) + .id('ButtonChange4') + .onClick(() => { + this.minFontSize = 10; + this.maxFontSize = undefined; + }) + Button('删除部分文本').margin(1) + .id('ButtonChange5') + .onClick(() => { + this.text = 'ABC pr'; + this.minFontSize = 10; + this.maxFontSize = 30; + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize013.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize013.ets new file mode 100644 index 00000000..49511898 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize013.ets @@ -0,0 +1,56 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize013 { + @State minFontSize: number | undefined = 10; + @State maxFontSize: number | undefined = 30; + @State text: string = 'ABC priorities.' + @State changeText: string = '' + + build() { + Column() { + TextArea({ + text: this.text + }) + .id('searchFontSize013TextArea1') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(40) + .minFontSize(this.minFontSize) + .maxFontSize(this.maxFontSize) + TextArea({ + text:this.changeText + }) + .id('searchFontSize013TextArea2') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(40) + .minFontSize(this.minFontSize) + .maxFontSize(this.maxFontSize) + Button('更换文本内容').margin(1) + .id('ButtonChangeText013') + .onClick(() => { + this.changeText = 'ABC priorities Sometimes,a significant changeChange,' + + 'a constant and inevitable,everychange'; + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize014.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize014.ets new file mode 100644 index 00000000..f9f36f30 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize014.ets @@ -0,0 +1,65 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize014 { + @State minFontSize: number | undefined = 10; + @State maxFontSize: number | undefined = 30; + @State text: string = 'ABC priorities.' + @State changeText: string = '' + controller: TextAreaController = new TextAreaController() + build() { + Column() { + TextArea({ + text: this.text + }) + .id('searchFontSize014TextArea1') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MIN_FONT_SIZE_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(40) + .minFontSize(this.minFontSize) + .maxFontSize(this.maxFontSize) + TextArea({ + text:this.changeText, + controller: this.controller + }) + .id('searchFontSize014TextArea2') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MIN_FONT_SIZE_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(40) + .minFontSize(this.minFontSize) + .maxFontSize(this.maxFontSize) + Button('更换文本内容').margin(1) + .id('ButtonChangeText014') + .onClick(() => { + this.changeText = 'ABC priorities Sometimes,a significant changeChange,' + + 'a constant and inevitable,everychange'; + }) + Button('Select Text Button') + .margin(15) + .onClick(() => { + let options: SelectionOptions = { + menuPolicy: MenuPolicy.SHOW + } + this.controller.setTextSelection(10, 100, options) + }).id('ButtonSelectText014') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize015.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize015.ets new file mode 100644 index 00000000..399fd53e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize015.ets @@ -0,0 +1,49 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize015 { + @State minFontSize: number | undefined = 10; + @State maxFontSize: number | undefined = 30; + controller: TextAreaController = new TextAreaController() + @State editState: number = TextHeightAdaptivePolicy.MAX_LINES_FIRST; + + build() { + Column() { + TextArea({ + controller: this.controller + }) + .id('searchFontSize015TextArea1') + .heightAdaptivePolicy(this.editState) + .margin(10) + .border({ width: 1 }) + .width('50%') + .minFontSize(this.minFontSize) + .maxFontSize(this.maxFontSize) + .maxLines(4) + .style(TextContentStyle.INLINE) + .onClick(()=>{ + this.editState = TextHeightAdaptivePolicy.MAX_LINES_FIRST + }) + Button('stopEditing').margin(1) + .id('ButtonStopEditingText015') + .onClick(() => { + this.controller.stopEditing() + this.editState = TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize016.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize016.ets new file mode 100644 index 00000000..e92b5560 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize016.ets @@ -0,0 +1,60 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize016 { + @State changeText: string = '' + build() { + Column() { + TextInput() + .margin(10) + .border({ width: 1 }) + .width('50%') + TextArea({ + text: this.changeText + }) + .id('searchFontSize016TextArea1') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MIN_FONT_SIZE_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(50) + .minFontSize(10) + .maxFontSize(30) + Button('更换文本内容').margin(1) + .id('ButtonChangeText016_1') + .onClick(() => { + this.changeText = 'ABC priorities'; + }) + Button('更换文本内容').margin(1) + .id('ButtonChangeText016_2') + .onClick(() => { + this.changeText = 'ABC priorities Sometimes,a significant changeChange,' + + 'a constant and inevitable,everychange'; + }) + Button('更换文本内容1').margin(1) + .id('ButtonChangeText016_3') + .onClick(() => { + this.changeText = 'ABC priorities Sometimes,a significant changeChange,a constan' + + 't and inevitable,every change brings the potential for growth andnew beginn' + + 'ings,But remember,everychange brings the potential for,ABC ' + + 'priorities Sometimes,a significant changeChange,a constant and inevi' + + 'table,every change brings the potential for growth andnew beginnings,Bu' + + 't remember,everychange brings the potential for'; + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize017.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize017.ets new file mode 100644 index 00000000..91e560dd --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize017.ets @@ -0,0 +1,34 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize017 { + @State changeText: string = '' + build() { + Column() { + Search({ + value: this.changeText, + }) + .id('searchFontSize017') + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(50) + .minFontSize(10) + .maxFontSize(30) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize018.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize018.ets new file mode 100644 index 00000000..f56af884 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize018.ets @@ -0,0 +1,50 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize018 { + build() { + Column() { + TextInput() + .id('searchFontSize018TextInput') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(50) + .minFontSize(30) + .maxFontSize(30) + TextInput() + .id('searchFontSize018TextInput_1') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(50) + .minFontSize(30) + .maxFontSize(30) + TextInput() + .id('searchFontSize018TextInput_2') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(50) + .minFontSize(30) + .maxFontSize(30) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize019.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize019.ets new file mode 100644 index 00000000..a3bb390f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize019.ets @@ -0,0 +1,50 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize019 { + build() { + Column() { + TextArea() + .id('searchFontSize019TextArea') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(90) + .minFontSize(30) + .maxFontSize(30) + TextArea() + .id('searchFontSize019TextArea_1') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(90) + .minFontSize(30) + .maxFontSize(30) + TextArea() + .id('searchFontSize019TextArea_2') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(90) + .minFontSize(30) + .maxFontSize(30) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize020.ets new file mode 100644 index 00000000..2182f3fa --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize020.ets @@ -0,0 +1,75 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize020 { + @State componentHeight: number | string = '' + @State text: string = '哈哈哈哈哈哈哈哈哈哈哈哈或' + + build() { + Column() { + TextInput({ + text:this.text + }) + .id('searchFontSize020TextInput') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(this.componentHeight) + .minFontSize(10) + .maxFontSize(30) + .padding(0) + TextArea({ + text:this.text + }) + .id('searchFontSize020TextArea') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(this.componentHeight) + .minFontSize(10) + .maxFontSize(30) + .padding(0) + Button('changeHeight=80').margin(1) + .id('ButtonChangeHeight020_1') + .onClick(() => { + this.componentHeight = 80 + }) + Button('changeHeight=50').margin(1) + .id('ButtonChangeHeight020_2') + .onClick(() => { + this.componentHeight = 50 + }) + Button('changeHeight=20').margin(1) + .id('ButtonChangeHeight020_3') + .onClick(() => { + this.componentHeight = 20 + }) + Button('changeHeight=5').margin(1) + .id('ButtonChangeHeight020_4') + .onClick(() => { + this.componentHeight = 5 + }) + Button('changeHeight=20%').margin(1) + .id('ButtonChangeHeight020_5') + .onClick(() => { + this.componentHeight = '20%' + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize021.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize021.ets new file mode 100644 index 00000000..bf13c6a5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize021.ets @@ -0,0 +1,47 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize021 { + @State text: string = '哈哈哈哈哈哈哈哈哈哈哈哈或' + + build() { + Column() { + TextInput({ + text:this.text + }) + .id('searchFontSize021TextInput') + .margin(10) + .border({ width: 1 }) + .width('50%') + .minFontSize(10) + .fontSize(16) + .maxFontSize(30) + .padding(0) + TextArea({ + text:this.text + }) + .id('searchFontSize021TextArea') + .margin(10) + .border({ width: 1 }) + .width('50%') + .minFontSize(10) + .maxFontSize(30) + .padding(0) + .fontSize(40) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize022.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize022.ets new file mode 100644 index 00000000..edd170b1 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize022.ets @@ -0,0 +1,41 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize022 { + + build() { + Column() { + TextInput() + .id('searchFontSize022TextInput') + .margin(10) + .border({ width: 1 }) + .width('50%') + .minFontSize(10) + .maxFontSize(30) + .padding(0) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST) + TextArea() + .id('searchFontSize022TextArea') + .margin(10) + .border({ width: 1 }) + .width('50%') + .minFontSize(10) + .maxFontSize(30) + .padding(0) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize023.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize023.ets new file mode 100644 index 00000000..62964fca --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize023.ets @@ -0,0 +1,43 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize023 { + + build() { + Column() { + TextInput() + .id('searchFontSize023TextInput') + .margin(10) + .border({ width: 1 }) + .width('50%') + .minFontSize(10) + .maxFontSize(30) + .padding(0) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST) + TextArea() + .id('searchFontSize023TextArea') + .margin(10) + .border({ width: 1 }) + .width('50%') + .minFontSize(10) + .maxFontSize(30) + .maxLines(1) + .padding(0) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize024.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize024.ets new file mode 100644 index 00000000..a241994a --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize024.ets @@ -0,0 +1,42 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize024 { + build() { + Column() { + TextInput() + .id('searchFontSize024TextInput') + .margin(10) + .border({ width: 1 }) + .width('50%') + .minFontSize(10) + .maxFontSize(30) + .padding(0) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MIN_FONT_SIZE_FIRST) + TextArea() + .id('searchFontSize024TextArea') + .margin(10) + .border({ width: 1 }) + .width('50%') + .minFontSize(10) + .maxFontSize(30) + .maxLines(1) + .padding(0) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MIN_FONT_SIZE_FIRST) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize025.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize025.ets new file mode 100644 index 00000000..1759e8fd --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize025.ets @@ -0,0 +1,42 @@ +/** + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize025 { + build() { + Column() { + TextInput() + .id('searchFontSize025TextInput') + .margin(10) + .border({ width: 1 }) + .width('50%') + .minFontSize(10) + .maxFontSize(30) + .padding(0) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MIN_FONT_SIZE_FIRST) + TextArea() + .id('searchFontSize025TextArea') + .margin(10) + .border({ width: 1 }) + .width('50%') + .minFontSize(10) + .maxFontSize(30) + .maxLines(1) + .padding(0) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MIN_FONT_SIZE_FIRST) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize026.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize026.ets new file mode 100644 index 00000000..d9def780 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize026.ets @@ -0,0 +1,46 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize026 { + build() { + Column() { + TextInput({ + text:'ABC priorities.' + }) + .id('searchFontSize026TextInput1') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .margin(10).border({ width: 1 }) + .width('50%') + .minFontSize(10) + .maxFontSize(30) + TextInput() + .id('searchFontSize026TextInput2') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .margin(10).border({ width: 1 }) + .width('50%') + .minFontSize(10) + .maxFontSize(30) + TextInput() + .id('searchFontSize026TextInput3') + .width('50%') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .margin(10).border({ width: 1 }) + .minFontSize(10) + .maxFontSize(30) + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize027.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize027.ets new file mode 100644 index 00000000..cc86312d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize027.ets @@ -0,0 +1,68 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize027 { + @State minFontSize: number | undefined = 10; + @State maxFontSize: number | undefined = 30; + @State text: string = 'ABC priorities.Sometimes,asignificant change Change' + + build() { + Column() { + TextInput({ + text: this.text + }) + .id('searchFontSize027TextInput') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MIN_FONT_SIZE_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .minFontSize(this.minFontSize) + .maxFontSize(this.maxFontSize) + Button('改变maxfontsize { + this.minFontSize = 30; + this.maxFontSize = 10; + }) + Button('改变maxfontsize=minFontSize').margin(1) + .id('ButtonChange2') + .onClick(() => { + this.minFontSize = 10; + this.maxFontSize = 10; + }) + Button('改变maxfontsize=minFontSize=undefined').margin(1) + .id('ButtonChange3') + .onClick(() => { + this.minFontSize = undefined; + this.maxFontSize = undefined; + }) + Button('maxFontSize=undefined,minFontSize=10').margin(1) + .id('ButtonChange4') + .onClick(() => { + this.minFontSize = 10; + this.maxFontSize = undefined; + }) + Button('删除部分文本').margin(1) + .id('ButtonChange5') + .onClick(() => { + this.minFontSize = 10; + this.maxFontSize = 40; + this.text = 'ABC pr'; + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize028.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize028.ets new file mode 100644 index 00000000..87efc067 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize028.ets @@ -0,0 +1,56 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize028 { + @State minFontSize: number | undefined = 10; + @State maxFontSize: number | undefined = 30; + @State text: string = 'ABC priorities.' + @State changeText: string = '' + + build() { + Column() { + TextArea({ + text: this.text + }) + .id('searchFontSize028TextArea1') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(40) + .minFontSize(this.minFontSize) + .maxFontSize(this.maxFontSize) + TextArea({ + text:this.changeText + }) + .id('searchFontSize028TextArea2') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(40) + .minFontSize(this.minFontSize) + .maxFontSize(this.maxFontSize) + Button('更换文本内容').margin(1) + .id('ButtonChangeText028') + .onClick(() => { + this.changeText = 'ABC priorities Sometimes,a significant changeChange,' + + 'a constant and inevitable,everychange'; + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize029.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize029.ets new file mode 100644 index 00000000..dfb36402 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize029.ets @@ -0,0 +1,65 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize029 { + @State minFontSize: number | undefined = 10; + @State maxFontSize: number | undefined = 30; + @State text: string = 'ABC priorities.' + @State changeText: string = '' + controller: TextInputController = new TextInputController() + build() { + Column() { + TextInput({ + text: this.text + }) + .id('searchFontSize029TextInput1') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MIN_FONT_SIZE_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(40) + .minFontSize(this.minFontSize) + .maxFontSize(this.maxFontSize) + TextInput({ + text:this.changeText, + controller: this.controller + }) + .id('searchFontSize029TextInput2') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MIN_FONT_SIZE_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(40) + .minFontSize(this.minFontSize) + .maxFontSize(this.maxFontSize) + Button('更换文本内容').margin(1) + .id('ButtonChangeText029') + .onClick(() => { + this.changeText = 'ABC priorities Sometimes,a significant changeChange,' + + 'a constant and inevitable,everychange'; + }) + Button('Select Text Button') + .margin(15) + .onClick(() => { + let options: SelectionOptions = { + menuPolicy: MenuPolicy.SHOW + } + this.controller.setTextSelection(10, 100, options) + }).id('ButtonSelectText029') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize030.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize030.ets new file mode 100644 index 00000000..2ff96ede --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize030.ets @@ -0,0 +1,47 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize030 { + @State minFontSize: number | undefined = 30; + @State maxFontSize: number | undefined = 10; + @State inputType: number = InputType.Password; + + build() { + Column() { + TextInput() + .id('searchFontSize030TextInput') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MIN_FONT_SIZE_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(40) + .minFontSize(this.minFontSize) + .maxFontSize(this.maxFontSize) + .type(this.inputType) + Button('更换输入框类型为normal').margin(1) + .id('ButtonChangeTypeNormalText030') + .onClick(() => { + this.inputType = InputType.Normal; + }) + Button('更换输入框类型为Password').margin(1) + .id('ButtonChangeTypePassword030') + .onClick(() => { + this.inputType = InputType.Password; + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize031.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize031.ets new file mode 100644 index 00000000..06edf0c8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize031.ets @@ -0,0 +1,49 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize031 { + @State minFontSize: number | undefined = 10; + @State maxFontSize: number | undefined = 30; + controller: TextInputController = new TextInputController() + @State editState: number = TextHeightAdaptivePolicy.MAX_LINES_FIRST; + + build() { + Column() { + TextInput({ + controller: this.controller + }) + .id('searchFontSize031TextInput') + .heightAdaptivePolicy(this.editState) + .margin(10) + .border({ width: 1 }) + .width('50%') + .minFontSize(this.minFontSize) + .maxFontSize(this.maxFontSize) + .maxLines(4) + .style(TextContentStyle.INLINE) + .onClick(()=>{ + this.editState = TextHeightAdaptivePolicy.MAX_LINES_FIRST + }) + Button('stopEditing').margin(1) + .id('ButtonStopEditingText031') + .onClick(() => { + this.controller.stopEditing() + this.editState = TextHeightAdaptivePolicy.LAYOUT_CONSTRAINT_FIRST + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize032.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize032.ets new file mode 100644 index 00000000..594653db --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize032.ets @@ -0,0 +1,60 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize032 { + @State changeText: string = '' + build() { + Column() { + TextArea() + .margin(10) + .border({ width: 1 }) + .width('50%') + TextInput({ + text: this.changeText + }) + .id('searchFontSize032TextInput1') + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MIN_FONT_SIZE_FIRST) + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(50) + .minFontSize(10) + .maxFontSize(30) + Button('更换文本内容').margin(1) + .id('ButtonChangeText032_1') + .onClick(() => { + this.changeText = 'ABC priorities'; + }) + Button('更换文本内容').margin(1) + .id('ButtonChangeText032_2') + .onClick(() => { + this.changeText = 'ABC priorities Sometimes,a significant changeChange,' + + 'a constant and inevitable,everychange'; + }) + Button('更换文本内容1').margin(1) + .id('ButtonChangeText032_3') + .onClick(() => { + this.changeText = 'ABC priorities Sometimes,a significant changeChange,a constan' + + 't and inevitable,every change brings the potential for growth andnew beginn' + + 'ings,But remember,everychange brings the potential for,ABC ' + + 'priorities Sometimes,a significant changeChange,a constant and inevi' + + 'table,every change brings the potential for growth andnew beginnings,Bu' + + 't remember,everychange brings the potential for'; + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize033.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize033.ets new file mode 100644 index 00000000..21a8648e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize033.ets @@ -0,0 +1,38 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize033 { + + build() { + Column() { + TextInput() + .id('searchFontSize033TextInput') + .margin(10) + .border({ width: 1 }) + .width('50%') + .padding(0) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + TextArea() + .id('searchFontSize033TextArea') + .margin(10) + .border({ width: 1 }) + .width('50%') + .padding(0) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize034.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize034.ets new file mode 100644 index 00000000..dae479d4 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize034.ets @@ -0,0 +1,48 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize034 { + + build() { + Column() { + TextInput() + .id('searchFontSize034TextInput') + .margin(10) + .border({ width: 1 }) + .width('50%') + .padding(0) + .fontSize(12) + .maxFontSize(30) + TextArea() + .id('searchFontSize034TextArea') + .margin(10) + .border({ width: 1 }) + .width('50%') + .padding(0) + .fontSize(12) + .maxFontSize(30) + Search() + .id('searchFontSize034') + .margin(10) + .border({ width: 1 }) + .width('50%') + .padding(0) + .textFont({ size: 14 }) + .maxFontSize(30) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize035.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize035.ets new file mode 100644 index 00000000..a5ded14f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize035.ets @@ -0,0 +1,48 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize035 { + + build() { + Column() { + TextInput() + .id('searchFontSize035TextInput') + .margin(10) + .border({ width: 1 }) + .width('50%') + .padding(0) + .fontSize(20) + .minFontSize(10) + TextArea() + .id('searchFontSize035TextArea') + .margin(10) + .border({ width: 1 }) + .width('50%') + .padding(0) + .fontSize(20) + .minFontSize(10) + Search() + .id('searchFontSize035') + .margin(10) + .border({ width: 1 }) + .width('50%') + .padding(0) + .textFont({ size: 20 }) + .minFontSize(10) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize036.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize036.ets new file mode 100644 index 00000000..64fd4d56 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize036.ets @@ -0,0 +1,57 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize036 { + + build() { + Column() { + TextInput() + .id('searchFontSize036TextInput') + .margin(10) + .border({ width: 1 }) + .width('50%') + .padding(0) + .fontSize(20) + .minFontSize(10) + .maxFontSize(30) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .letterSpacing(1) + TextArea() + .id('searchFontSize036TextArea') + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(40) + .padding(0) + .fontSize(20) + .minFontSize(10) + .maxFontSize(30) + .letterSpacing(1) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + Search() + .id('searchFontSize036') + .margin(10) + .border({ width: 1 }) + .width('50%') + .padding(0) + .textFont({ size: 20 }) + .minFontSize(10) + .maxFontSize(30) + .letterSpacing(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize037.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize037.ets new file mode 100644 index 00000000..13833ccb --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize037.ets @@ -0,0 +1,71 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize037 { + + build() { + Column() { + TextInput() + .id('searchFontSize037TextInput') + .margin(10) + .border({ width: 1 }) + .width('50%') + .padding(0) + .fontSize(20) + .minFontSize(10) + .maxFontSize(30) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .decoration({ + type:TextDecorationType.Underline, + color:Color.Red, + style:TextDecorationStyle.SOLID + }) + TextArea() + .id('searchFontSize037TextArea') + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(40) + .padding(0) + .fontSize(20) + .minFontSize(10) + .maxFontSize(30) + .letterSpacing(1) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .decoration({ + type:TextDecorationType.Underline, + color:Color.Red, + style:TextDecorationStyle.SOLID + }) + Search() + .id('searchFontSize037') + .margin(10) + .border({ width: 1 }) + .width('50%') + .padding(0) + .textFont({ size: 20 }) + .minFontSize(10) + .maxFontSize(30) + .letterSpacing(1) + .decoration({ + type:TextDecorationType.Underline, + color:Color.Red, + style:TextDecorationStyle.SOLID + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize038.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize038.ets new file mode 100644 index 00000000..b4f2a3ef --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize038.ets @@ -0,0 +1,64 @@ +/** + * Copyright (c) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextCommonTextMinFontSize038 { + + build() { + Column() { + TextInput() + .id('searchFontSize038TextInput') + .margin(10) + .border({ width: 1 }) + .width('50%') + .padding(0) + .fontSize(20) + .minFontSize(10) + .maxFontSize(30) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .textAlign(TextAlign.Center) + TextArea() + .id('searchFontSize038TextArea') + .margin(10) + .border({ width: 1 }) + .width('50%') + .height(40) + .padding(0) + .fontSize(20) + .minFontSize(10) + .maxFontSize(30) + .letterSpacing(1) + .heightAdaptivePolicy(TextHeightAdaptivePolicy.MAX_LINES_FIRST) + .textAlign(TextAlign.Center) + Search() + .id('searchFontSize038') + .margin(10) + .border({ width: 1 }) + .width('50%') + .padding(0) + .textFont({ size: 20 }) + .minFontSize(10) + .maxFontSize(30) + .letterSpacing(1) + .decoration({ + type:TextDecorationType.Underline, + color:Color.Red, + style:TextDecorationStyle.SOLID + }) + .textAlign(TextAlign.Center) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0210.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0210.ets new file mode 100644 index 00000000..0d5e5010 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0210.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0210 { + build() { + Column() { + TextInput() + .id('textInputTextStyle0210') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .enableKeyboardOnFocus(true) + .defaultFocus(true) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0220.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0220.ets new file mode 100644 index 00000000..d53c3b3e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0220.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0220 { + build() { + Column() { + TextInput() + .id('textInputTextStyle0220') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .enableKeyboardOnFocus(false) + .defaultFocus(true) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0320.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0320.ets new file mode 100644 index 00000000..308bb669 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0320.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0320 { + build() { + Column() { + TextInput() + .id('textInputTextStyle0320') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .enterKeyType(EnterKeyType.Go) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0330.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0330.ets new file mode 100644 index 00000000..490abd16 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0330.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0330 { + build() { + Column() { + TextInput() + .id('textInputTextStyle0330') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .enterKeyType(EnterKeyType.Search) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0340.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0340.ets new file mode 100644 index 00000000..ae9c0af7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0340.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0340 { + build() { + Column() { + TextInput() + .id('textInputTextStyle0340') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .enterKeyType(EnterKeyType.Send) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0350.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0350.ets new file mode 100644 index 00000000..c7930cdd --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0350.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0350 { + build() { + Column() { + TextInput() + .id('textInputTextStyle0350') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .enterKeyType(EnterKeyType.Next) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0360.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0360.ets new file mode 100644 index 00000000..50ca3452 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0360.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0360 { + build() { + Column() { + TextInput() + .id('textInputTextStyle0360') + .margin(10) + .border({ width: 1 }) + .width('30%') + .height(40) + .enterKeyType(EnterKeyType.Done) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0730.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0730.ets new file mode 100644 index 00000000..4005b01b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0730.ets @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0730 { + build() { + Column() { + TextArea() + .id('textAreaTextStyle0730') + .margin(10) + .border({ width: 1 }) + .width('40%') + .barState(BarState.Off) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0740.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0740.ets new file mode 100644 index 00000000..e7c96b28 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0740.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0740 { + build() { + Column() { + TextArea() + .id('textAreaTextStyle0740') + .margin(10) + .border({ width: 1 }) + .width('40%') + .height(90) + .barState(BarState.On) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0750.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0750.ets new file mode 100644 index 00000000..2934a6cf --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0750.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0750 { + build() { + Column() { + TextArea() + .id('textAreaTextStyle0750') + .margin(10) + .border({ width: 1 }) + .width('40%') + .height(60) + .barState(BarState.Auto) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0760.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0760.ets new file mode 100644 index 00000000..e04c5334 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0760.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0760 { + build() { + Column() { + TextArea() + .id('textAreaTextStyle0760') + .margin(10) + .border({ width: 1 }) + .width('40%') + .maxLines(5) + .style(TextContentStyle.INLINE) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0770.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0770.ets new file mode 100644 index 00000000..03ef0307 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0770.ets @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0770 { + build() { + Column() { + TextArea() + .id('textAreaTextStyle0770') + .margin(10) + .border({ width: 1 }) + .width('40%') + .selectionMenuHidden(false) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0780.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0780.ets new file mode 100644 index 00000000..face6170 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0780.ets @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0780 { + build() { + Column() { + TextArea() + .id('textAreaTextStyle0780') + .margin(10) + .border({ width: 1 }) + .width('40%') + .selectionMenuHidden(true) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0790.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0790.ets new file mode 100644 index 00000000..d6cbcd1f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0790.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0790 { + build() { + Column() { + TextArea() + .id('textAreaTextStyle0790') + .margin(10) + .border({ width: 1 }) + .width('40%') + .enableKeyboardOnFocus(true) + .defaultFocus(true) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0800.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0800.ets new file mode 100644 index 00000000..7ce7c7fb --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0800.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0800 { + build() { + Column() { + TextArea() + .id('textAreaTextStyle0800') + .margin(10) + .border({ width: 1 }) + .width('40%') + .enableKeyboardOnFocus(false) + .defaultFocus(true) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0810.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0810.ets new file mode 100644 index 00000000..180f2cef --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0810.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0810 { + build() { + Column() { + TextArea() + .id('textAreaTextStyle0810') + .margin(10) + .border({ width: 1 }) + .width('40%') + .fontSize(10) + .style(TextContentStyle.DEFAULT) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0820.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0820.ets new file mode 100644 index 00000000..f56fb7af --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0820.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0820 { + build() { + Column() { + TextArea() + .id('textAreaTextStyle0820') + .margin(10) + .border({ width: 1 }) + .width('40%') + .fontSize(10) + .height(60) + .style(TextContentStyle.INLINE) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0830.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0830.ets new file mode 100644 index 00000000..ec344f56 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0830.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0830 { + build() { + Column() { + TextArea() + .id('textAreaTextStyle0830') + .margin(10) + .border({ width: 1 }) + .width('40%') + .maxLength(20) + .showCounter(true) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0840.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0840.ets new file mode 100644 index 00000000..921a7394 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0840.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle0840 { + build() { + Column() { + TextArea() + .id('textAreaTextStyle0840') + .margin(10) + .border({ width: 1 }) + .width('40%') + .maxLength(20) + .showCounter(false) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1150.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1150.ets new file mode 100644 index 00000000..6114d64d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1150.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle1150 { + build() { + Column() { + TextArea() + .id('textAreaTextStyle1150') + .margin(10) + .border({ width: 1 }) + .width('40%') + .maxLength(20) + .copyOption(CopyOptions.None) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1160.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1160.ets new file mode 100644 index 00000000..7d1e0ee1 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1160.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle1160 { + build() { + Column() { + TextArea() + .id('textAreaTextStyle1160') + .margin(10) + .border({ width: 1 }) + .width('40%') + .maxLength(20) + .copyOption(CopyOptions.InApp) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1170.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1170.ets new file mode 100644 index 00000000..d0c12ff0 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1170.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle1170 { + build() { + Column() { + TextArea() + .id('textAreaTextStyle1170') + .margin(10) + .border({ width: 1 }) + .width('40%') + .maxLength(20) + .copyOption(CopyOptions.LocalDevice) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1450.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1450.ets new file mode 100644 index 00000000..14a0f21d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1450.ets @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle1450 { + build() { + Column() { + Text('HELLO') + .id('text1450') + .margin(10) + .border({ width: 1 }) + .width('40%') + .copyOption(CopyOptions.None) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1460.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1460.ets new file mode 100644 index 00000000..bebe5fab --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1460.ets @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle1460 { + build() { + Column() { + Text('HELLO') + .id('text1460') + .margin(10) + .border({ width: 1 }) + .width('40%') + .copyOption(CopyOptions.InApp) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1470.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1470.ets new file mode 100644 index 00000000..f2588d72 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1470.ets @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle1470 { + build() { + Column() { + Text('HELLO') + .id('text1470') + .margin(10) + .border({ width: 1 }) + .width('40%') + .copyOption(CopyOptions.LocalDevice) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1850.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1850.ets new file mode 100644 index 00000000..f86b1a7b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1850.ets @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle1850 { + build() { + Column() { + Search() + .id('search1850') + .margin(10) + .border({ width: 1 }) + .width('60%') + .searchButton('SEARCH') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1860.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1860.ets new file mode 100644 index 00000000..d2e39e00 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1860.ets @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle1860 { + build() { + Column() { + Search() + .id('search1860') + .margin(10) + .border({ width: 1 }) + .width('60%') + .selectionMenuHidden(true) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1870.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1870.ets new file mode 100644 index 00000000..e1aeaef3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1870.ets @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle1870 { + build() { + Column() { + Search() + .id('search1870') + .margin(10) + .border({ width: 1 }) + .width('60%') + .selectionMenuHidden(false) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1880.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1880.ets new file mode 100644 index 00000000..d9e3d7bf --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1880.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle1880 { + build() { + Column() { + Search() + .id('search1880') + .margin(10) + .border({ width: 1 }) + .width('60%') + .enableKeyboardOnFocus(true) + .defaultFocus(true) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1890.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1890.ets new file mode 100644 index 00000000..60e963b6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1890.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle1890 { + build() { + Column() { + Search() + .id('search1890') + .margin(10) + .border({ width: 1 }) + .width('60%') + .enableKeyboardOnFocus(false) + .defaultFocus(true) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1910.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1910.ets new file mode 100644 index 00000000..4a139c9f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1910.ets @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle1910 { + build() { + Column() { + Search() + .id('search1910') + .margin(10) + .border({ width: 1 }) + .width('60%') + .height(60) + .cancelButton({ + style:CancelButtonStyle.CONSTANT, + icon:{ + src:$r('app.media.icon') + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1920.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1920.ets new file mode 100644 index 00000000..58b7704b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1920.ets @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle1920 { + build() { + Column() { + Search() + .id('search1920') + .margin(10) + .border({ width: 1 }) + .width('60%') + .height(60) + .cancelButton({ + style:CancelButtonStyle.INVISIBLE, + icon:{ + src:$r('app.media.icon') + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1930.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1930.ets new file mode 100644 index 00000000..9cfad9d3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1930.ets @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle1930 { + build() { + Column() { + Search() + .id('search1930') + .margin(10) + .border({ width: 1 }) + .width('60%') + .height(60) + .cancelButton({ + style:CancelButtonStyle.INPUT, + icon:{ + src:$r('app.media.icon') + } + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1940.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1940.ets new file mode 100644 index 00000000..a702d3cc --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1940.ets @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle1940 { + build() { + Column() { + Search() + .id('search1940') + .margin(10) + .border({ width: 1 }) + .width('60%') + .height(60) + .searchIcon({ + size:10, + color:Color.Red, + src: $r('app.media.cat') + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2040.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2040.ets new file mode 100644 index 00000000..27567437 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2040.ets @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle2040 { + build() { + Column() { + Search() + .id('search2040') + .margin(10) + .border({ width: 1 }) + .width('60%') + .height(60) + .textFont({ + size:20, + weight:FontWeight.Bolder, + family:'Arial,HarmonyOS Sans', + style:FontStyle.Italic + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2050.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2050.ets new file mode 100644 index 00000000..add197db --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2050.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle2050 { + build() { + Column() { + Search() + .id('search2050') + .margin(10) + .border({ width: 1 }) + .width('60%') + .height(60) + .copyOption(CopyOptions.None) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2060.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2060.ets new file mode 100644 index 00000000..e6f04c7c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2060.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle2060 { + build() { + Column() { + Search() + .id('search2060') + .margin(10) + .border({ width: 1 }) + .width('60%') + .height(60) + .copyOption(CopyOptions.InApp) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2070.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2070.ets new file mode 100644 index 00000000..5b491b4b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2070.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle2070 { + build() { + Column() { + Search() + .id('search2070') + .margin(10) + .border({ width: 1 }) + .width('60%') + .height(60) + .copyOption(CopyOptions.LocalDevice) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2120.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2120.ets new file mode 100644 index 00000000..0123cc92 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2120.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle2120 { + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + build() { + Column() { + RichEditor(this.options) + .id('richEditor2120') + .margin(10) + .border({ width: 1 }) + .width('60%') + .height(60) + .copyOptions(CopyOptions.None) + .onReady(() => { + this.controller.addTextSpan("012345", + { + style: + { + fontColor: Color.Orange, + fontSize: 30 + } + }) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2130.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2130.ets new file mode 100644 index 00000000..9a2586da --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2130.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle2130 { + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + build() { + Column() { + RichEditor(this.options) + .id('richEditor2130') + .margin(10) + .border({ width: 1 }) + .width('60%') + .height(60) + .copyOptions(CopyOptions.InApp) + .onReady(() => { + this.controller.addTextSpan("012345", + { + style: + { + fontColor: Color.Orange, + fontSize: 30 + } + }) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2140.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2140.ets new file mode 100644 index 00000000..42e24e9d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2140.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextCommonTextStyle2140 { + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + build() { + Column() { + RichEditor(this.options) + .id('richEditor2140') + .margin(10) + .border({ width: 1 }) + .width('60%') + .height(60) + .copyOptions(CopyOptions.LocalDevice) + .onReady(() => { + this.controller.addTextSpan("012345", + { + style: + { + fontColor: Color.Orange, + fontSize: 30 + } + }) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0010.ets new file mode 100644 index 00000000..2263dc49 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0010.ets @@ -0,0 +1,75 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0010 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + Text('装饰线Underline') + .decoration({ + type:this.underline, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0010') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + Text('装饰线LineThrough') + .decoration({ + type:this.lineThrough, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0010') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + Text('装饰线Overline') + .decoration({ + type:this.overline, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0010') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + Text('装饰线None') + .decoration({ + type:this.none, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0010') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0020.ets new file mode 100644 index 00000000..59a98657 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0020.ets @@ -0,0 +1,79 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0020 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + Text('装饰线Underline') + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0020') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + Text('装饰线LineThrough') + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0020') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + Text('装饰线Overline') + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0020') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + Text('装饰线None') + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0020') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0030.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0030.ets new file mode 100644 index 00000000..7afda4b2 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0030.ets @@ -0,0 +1,79 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0030 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + Text('装饰线Underline') + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0030') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + Text('装饰线LineThrough') + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0030') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + Text('装饰线Overline') + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0030') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + Text('装饰线None') + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0030') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0040.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0040.ets new file mode 100644 index 00000000..0d676bd6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0040.ets @@ -0,0 +1,79 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0040 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + Text('装饰线Underline') + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0040') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + Text('装饰线LineThrough') + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0040') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + Text('装饰线Overline') + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0040') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + Text('装饰线None') + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0040') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0050.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0050.ets new file mode 100644 index 00000000..78984663 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0050.ets @@ -0,0 +1,79 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0050 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + Text('装饰线Underline') + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0050') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(2) + Text('装饰线LineThrough') + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0050') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(2) + Text('装饰线Overline') + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0050') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(2) + Text('装饰线None') + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0050') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0060.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0060.ets new file mode 100644 index 00000000..218596c2 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0060.ets @@ -0,0 +1,79 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0060 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + Text('装饰线Underline') + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0060') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(2) + Text('装饰线LineThrough') + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0060') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(2) + Text('装饰线Overline') + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0060') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(2) + Text('装饰线None') + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0060') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0070.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0070.ets new file mode 100644 index 00000000..ae07af49 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0070.ets @@ -0,0 +1,81 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0070 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: undefined = undefined; + + build() { + Column() { + Text('装饰线Underline') + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0070') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(2) + Text('装饰线LineThrough') + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0070') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(2) + Text('装饰线Overline') + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0070') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(2) + Text('装饰线None') + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0070') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0080.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0080.ets new file mode 100644 index 00000000..9cfb5bcc --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0080.ets @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0080 { + @State lineType: TextDecorationType | undefined = TextDecorationType.Underline; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color = Color.Blue + + build() { + Column() { + Text('装饰线Underline') + .decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线') + .id('changeLineBt0080') + .onClick(() => { + this.lineType = TextDecorationType.LineThrough; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0090.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0090.ets new file mode 100644 index 00000000..c060a782 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0090.ets @@ -0,0 +1,80 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0090 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: undefined = undefined; + + build() { + Column() { + Text(){ + Span('装饰线Underline') + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线LineThrough') + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线Overline') + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线None') + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + } + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0090') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0090') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0090') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0090') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0100.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0100.ets new file mode 100644 index 00000000..96c99bad --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0100.ets @@ -0,0 +1,84 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0100 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: TextDecorationStyle | undefined = undefined; + + build() { + Column() { + Text(){ + Span('装饰线Underline') + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线LineThrough') + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线Overline') + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线None') + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + } + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0100') + .onClick(() => { + this.underline = TextDecorationType.Underline + this.lineStyle = TextDecorationStyle.SOLID + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0100') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + this.lineStyle = TextDecorationStyle.SOLID + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0100') + .onClick(() => { + this.overline = TextDecorationType.Overline + this.lineStyle = TextDecorationStyle.SOLID + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0100') + .onClick(() => { + this.none = TextDecorationType.None + this.lineStyle = TextDecorationStyle.SOLID + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0110.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0110.ets new file mode 100644 index 00000000..fbef4b09 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0110.ets @@ -0,0 +1,84 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0110 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: TextDecorationStyle | undefined = undefined; + + build() { + Column() { + Text(){ + Span('装饰线Underline') + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线LineThrough') + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线Overline') + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线None') + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + } + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0110') + .onClick(() => { + this.underline = TextDecorationType.Underline + this.lineStyle = TextDecorationStyle.DOUBLE + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0110') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + this.lineStyle = TextDecorationStyle.DOUBLE + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0110') + .onClick(() => { + this.overline = TextDecorationType.Overline + this.lineStyle = TextDecorationStyle.DOUBLE + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0110') + .onClick(() => { + this.none = TextDecorationType.None + this.lineStyle = TextDecorationStyle.DOUBLE + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0120.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0120.ets new file mode 100644 index 00000000..4219c305 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0120.ets @@ -0,0 +1,84 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0120 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: TextDecorationStyle | undefined = undefined; + + build() { + Column() { + Text(){ + Span('装饰线Underline') + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线LineThrough') + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线Overline') + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线None') + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + } + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0120') + .onClick(() => { + this.underline = TextDecorationType.Underline + this.lineStyle = TextDecorationStyle.DOTTED + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0120') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + this.lineStyle = TextDecorationStyle.DOTTED + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0120') + .onClick(() => { + this.overline = TextDecorationType.Overline + this.lineStyle = TextDecorationStyle.DOTTED + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0120') + .onClick(() => { + this.none = TextDecorationType.None + this.lineStyle = TextDecorationStyle.DOTTED + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0130.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0130.ets new file mode 100644 index 00000000..055902ae --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0130.ets @@ -0,0 +1,84 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0130 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: TextDecorationStyle | undefined = undefined; + + build() { + Column() { + Text(){ + Span('装饰线Underline') + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线LineThrough') + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线Overline') + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线None') + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + } + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0130') + .onClick(() => { + this.underline = TextDecorationType.Underline + this.lineStyle = TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0130') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + this.lineStyle = TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0130') + .onClick(() => { + this.overline = TextDecorationType.Overline + this.lineStyle = TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0130') + .onClick(() => { + this.none = TextDecorationType.None + this.lineStyle = TextDecorationStyle.DASHED + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0140.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0140.ets new file mode 100644 index 00000000..b64562f3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0140.ets @@ -0,0 +1,84 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0140 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: TextDecorationStyle | undefined = undefined; + + build() { + Column() { + Text(){ + Span('装饰线Underline') + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线LineThrough') + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线Overline') + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线None') + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + } + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0140') + .onClick(() => { + this.underline = TextDecorationType.Underline + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0140') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0140') + .onClick(() => { + this.overline = TextDecorationType.Overline + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0140') + .onClick(() => { + this.none = TextDecorationType.None + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0150.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0150.ets new file mode 100644 index 00000000..ff2bf20b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0150.ets @@ -0,0 +1,80 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0150 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: TextDecorationStyle | undefined = undefined; + + build() { + Column() { + Text(){ + Span('装饰线Underline') + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线LineThrough') + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线Overline') + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + Span('装饰线None') + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + } + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0150') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0150') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0150') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0150') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0160.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0160.ets new file mode 100644 index 00000000..da156e08 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0160.ets @@ -0,0 +1,44 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0160 { + @State lineType: TextDecorationType | undefined = TextDecorationType.Underline; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color = Color.Blue + + build() { + Column() { + Text(){ + Span('装饰线Underline') + .decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }) + } + .margin(2) + Button('切换装饰线') + .id('changeLineBt0160') + .onClick(() => { + this.lineType = TextDecorationType.LineThrough; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0170.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0170.ets new file mode 100644 index 00000000..04ebb666 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0170.ets @@ -0,0 +1,96 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0170 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + controller: TextController = new TextController(); + fontStyleAttr: TextStyle = new TextStyle({ fontColor: Color.Blue }); + styledString: StyledString = new StyledString("test hello world", [{ + start: 0, + length: 5, + styledKey: StyledStringKey.DECORATION, + styledValue: this.fontStyleAttr + }]); + + build() { + Column() { + Text('装饰线Underline', { + controller: this.controller + }) + .decoration({ + type: this.underline, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0170') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.underline = TextDecorationType.Underline + }) + .margin(1) + Text('装饰线LineThrough', { + controller: this.controller + }) + .decoration({ + type: this.lineThrough, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0170') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + Text('装饰线Overline', { + controller: this.controller + }) + .decoration({ + type: this.overline, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0170') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.overline = TextDecorationType.Overline + }) + .margin(1) + Text('装饰线None', { + controller: this.controller + }) + .decoration({ + type: this.none, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0170') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0180.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0180.ets new file mode 100644 index 00000000..737f829c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0180.ets @@ -0,0 +1,105 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0180 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: TextDecorationStyle | undefined = undefined; + controller: TextController = new TextController(); + fontStyleAttr: TextStyle = new TextStyle({ fontColor: Color.Blue }); + styledString: StyledString = new StyledString("test hello world", [{ + start: 0, + length: 5, + styledKey: StyledStringKey.DECORATION, + styledValue: this.fontStyleAttr + }]); + + build() { + Column() { + Text('装饰线Underline', { + controller: this.controller + }) + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0180') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.SOLID + this.underline = TextDecorationType.Underline + }) + .margin(1) + Text('装饰线LineThrough', { + controller: this.controller + }) + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0180') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.SOLID + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + Text('装饰线Overline', { + controller: this.controller + }) + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0180') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.SOLID + this.overline = TextDecorationType.Overline + }) + .margin(1) + Text('装饰线None', { + controller: this.controller + }) + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0180') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.SOLID + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0190.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0190.ets new file mode 100644 index 00000000..1c67877e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0190.ets @@ -0,0 +1,105 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0190 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: TextDecorationStyle | undefined = undefined; + controller: TextController = new TextController(); + fontStyleAttr: TextStyle = new TextStyle({ fontColor: Color.Blue }); + styledString: StyledString = new StyledString("test hello world", [{ + start: 0, + length: 5, + styledKey: StyledStringKey.DECORATION, + styledValue: this.fontStyleAttr + }]); + + build() { + Column() { + Text('装饰线Underline', { + controller: this.controller + }) + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0190') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.DOUBLE + this.underline = TextDecorationType.Underline + }) + .margin(1) + Text('装饰线LineThrough', { + controller: this.controller + }) + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0190') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.DOUBLE + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + Text('装饰线Overline', { + controller: this.controller + }) + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0190') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.DOUBLE + this.overline = TextDecorationType.Overline + }) + .margin(1) + Text('装饰线None', { + controller: this.controller + }) + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0190') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.DOUBLE + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0200.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0200.ets new file mode 100644 index 00000000..3e3883ab --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0200.ets @@ -0,0 +1,105 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0200 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: TextDecorationStyle | undefined = undefined; + controller: TextController = new TextController(); + fontStyleAttr: TextStyle = new TextStyle({ fontColor: Color.Blue }); + styledString: StyledString = new StyledString("test hello world", [{ + start: 0, + length: 5, + styledKey: StyledStringKey.DECORATION, + styledValue: this.fontStyleAttr + }]); + + build() { + Column() { + Text('装饰线Underline', { + controller: this.controller + }) + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0200') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.DOTTED + this.underline = TextDecorationType.Underline + }) + .margin(1) + Text('装饰线LineThrough', { + controller: this.controller + }) + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0200') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.DOTTED + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + Text('装饰线Overline', { + controller: this.controller + }) + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0200') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.DOTTED + this.overline = TextDecorationType.Overline + }) + .margin(1) + Text('装饰线None', { + controller: this.controller + }) + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0200') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.DOTTED + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0210.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0210.ets new file mode 100644 index 00000000..3578a78b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0210.ets @@ -0,0 +1,105 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0210 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: TextDecorationStyle | undefined = undefined; + controller: TextController = new TextController(); + fontStyleAttr: TextStyle = new TextStyle({ fontColor: Color.Blue }); + styledString: StyledString = new StyledString("test hello world", [{ + start: 0, + length: 5, + styledKey: StyledStringKey.DECORATION, + styledValue: this.fontStyleAttr + }]); + + build() { + Column() { + Text('装饰线Underline', { + controller: this.controller + }) + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0210') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.DASHED + this.underline = TextDecorationType.Underline + }) + .margin(1) + Text('装饰线LineThrough', { + controller: this.controller + }) + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0210') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.DASHED + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + Text('装饰线Overline', { + controller: this.controller + }) + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0210') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.DASHED + this.overline = TextDecorationType.Overline + }) + .margin(1) + Text('装饰线None', { + controller: this.controller + }) + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0210') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.DASHED + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0220.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0220.ets new file mode 100644 index 00000000..efa74d70 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0220.ets @@ -0,0 +1,105 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0220 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: TextDecorationStyle | undefined = undefined; + controller: TextController = new TextController(); + fontStyleAttr: TextStyle = new TextStyle({ fontColor: Color.Blue }); + styledString: StyledString = new StyledString("test hello world", [{ + start: 0, + length: 5, + styledKey: StyledStringKey.DECORATION, + styledValue: this.fontStyleAttr + }]); + + build() { + Column() { + Text('装饰线Underline', { + controller: this.controller + }) + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0220') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.WAVY + this.underline = TextDecorationType.Underline + }) + .margin(1) + Text('装饰线LineThrough', { + controller: this.controller + }) + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0220') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.WAVY + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + Text('装饰线Overline', { + controller: this.controller + }) + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0220') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.WAVY + this.overline = TextDecorationType.Overline + }) + .margin(1) + Text('装饰线None', { + controller: this.controller + }) + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0220') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = TextDecorationStyle.WAVY + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0230.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0230.ets new file mode 100644 index 00000000..fb4221a8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0230.ets @@ -0,0 +1,105 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0230 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: TextDecorationStyle | undefined = undefined; + controller: TextController = new TextController(); + fontStyleAttr: TextStyle = new TextStyle({ fontColor: Color.Blue }); + styledString: StyledString = new StyledString("test hello world", [{ + start: 0, + length: 5, + styledKey: StyledStringKey.DECORATION, + styledValue: this.fontStyleAttr + }]); + + build() { + Column() { + Text('装饰线Underline', { + controller: this.controller + }) + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0230') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = undefined + this.underline = TextDecorationType.Underline + }) + .margin(1) + Text('装饰线LineThrough', { + controller: this.controller + }) + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0230') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = undefined + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + Text('装饰线Overline', { + controller: this.controller + }) + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0230') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = undefined + this.overline = TextDecorationType.Overline + }) + .margin(1) + Text('装饰线None', { + controller: this.controller + }) + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0230') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.lineStyle = undefined + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0240.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0240.ets new file mode 100644 index 00000000..b534dc60 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0240.ets @@ -0,0 +1,51 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0240 { + @State lineType: TextDecorationType | undefined = TextDecorationType.Underline; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color = Color.Blue + controller: TextController = new TextController(); + fontStyleAttr: TextStyle = new TextStyle({ fontColor: Color.Blue }); + styledString: StyledString = new StyledString("test hello world", [{ + start: 0, + length: 5, + styledKey: StyledStringKey.DECORATION, + styledValue: this.fontStyleAttr + }]); + build() { + Column() { + Text('装饰线Underline', { + controller: this.controller + }) + .decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线') + .id('changeLineBt0240') + .onClick(() => { + this.controller.setStyledString(this.styledString) + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0250.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0250.ets new file mode 100644 index 00000000..f32278f3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0250.ets @@ -0,0 +1,70 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0250 { + @State lineType: TextDecorationType | undefined = TextDecorationType.Underline; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color = Color.Blue + @State showType: string = ''; + @State showColor: string = ''; + controller: TextController = new TextController(); + styledString: StyledString = new StyledString("testHelloWorld", [{ + start: 0, + length: 5, + styledKey: StyledStringKey.DECORATION, + styledValue: new DecorationStyle({ type: TextDecorationType.LineThrough, color: Color.Blue }) + }]); + + build() { + Column() { + Text('装饰线Underline', { + controller: this.controller + }) + .decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线') + .id('changeLineBt0250') + .onClick(() => { + this.controller.setStyledString(this.styledString); + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY; + let styles = this.styledString.getStyles(0, this.styledString.length); + console.info('styledString style object start:' + styles.length) + if (styles.length !== 0) { + for (let i = 0; i < styles.length; i++) { + console.info('styledString style object start:' + styles[i].start) + console.info('styledString style object length:' + styles[i].length) + console.info('styledString style object key:' + styles[i].styledKey) + if (styles[i].styledKey === 1) { + let decoAttr = styles[i].styledValue as DecorationStyle; + console.info('styledString decoration type:' + decoAttr.type) + console.info('styledString decoration color:' + decoAttr.color) + } + } + } + }) + .margin(2) + Text() { + Span('') + } + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0260.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0260.ets new file mode 100644 index 00000000..d68b77d6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0260.ets @@ -0,0 +1,53 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0260 { + @State lineType: TextDecorationType | undefined = TextDecorationType.Underline; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color = Color.Blue + @State start: number = 0 + @State end: number = 0 + + build() { + Column() { + Text('装饰线Underline') + .id('text0260') + .decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }) + .selection(this.start, this.end) + .copyOption(CopyOptions.InApp) + .margin(2) + Button('切换装饰线') + .id('changeLineBt0260') + .onClick(() => { + this.lineType = TextDecorationType.LineThrough; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + Button('选中部分文本') + .id('selectButton0260') + .onClick(() => { + this.start = 2 + this.end = 5 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0270.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0270.ets new file mode 100644 index 00000000..d9326baa --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0270.ets @@ -0,0 +1,58 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0270 { + @State lineType: TextDecorationType | undefined = TextDecorationType.Underline; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color = Color.Blue + @State start: number = 0 + @State end: number = 0 + + build() { + Column() { + Text('装饰线Underline') + .id('text0270') + .decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }) + .selection(this.start, this.end) + .copyOption(CopyOptions.InApp) + .draggable(true) + .margin(2) + TextInput() + .id('textInput0270') + .width('50%') + .height(40) + Button('切换装饰线') + .id('changeLineBt0270') + .onClick(() => { + this.lineType = TextDecorationType.LineThrough; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + Button('选中部分文本') + .id('selectButton0270') + .onClick(() => { + this.start = 2 + this.end = 5 + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0280.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0280.ets new file mode 100644 index 00000000..ad5672a9 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0280.ets @@ -0,0 +1,52 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0280 { + @State underline: TextDecorationType | undefined = TextDecorationType.LineThrough; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + + build() { + Column() { + Text() + { + Span('装饰线Underline') + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + ContainerSpan() { + ImageSpan(('cat.jpg')) + .width('40vp') + .height('40vp') + .verticalAlign(ImageSpanAlignment.CENTER) + Span('hello') + }.textBackgroundStyle({color: "#7F007DFF", radius: "12vp"}) + SymbolSpan($r('sys.symbol.ohos_wifi')) + } + .margin(2) + .decoration({ + type: TextDecorationType.LineThrough, + color: Color.Green, + style: TextDecorationStyle.DOUBLE + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0290.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0290.ets new file mode 100644 index 00000000..1471640e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0290.ets @@ -0,0 +1,56 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0290 { + @State line: TextDecorationType | undefined = TextDecorationType.LineThrough; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color | undefined = undefined; + + build() { + Column() { + Text() { + Span('HelloWorld') + .decoration({ + type: this.line, + color: Color.Green, + style: this.lineStyle + }) + .width(100) + .height(100) + .padding(1) + .border({ width: 1 }) + } + .width(100) + .height(100) + .padding(1) + .border({ width: 1 }) + .decoration({ + type: TextDecorationType.LineThrough, + color: Color.Green, + style: TextDecorationStyle.DOUBLE + }) + Button('切换装饰线') + .id('changeLineBt0290') + .onClick(() => { + this.line = TextDecorationType.Underline; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0300.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0300.ets new file mode 100644 index 00000000..46220016 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0300.ets @@ -0,0 +1,63 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0300 { + @State line: TextDecorationType | undefined = TextDecorationType.LineThrough; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color | undefined = undefined; + @State text: string = + 'The text component is used to display a piece of textual information.Support univer' + + 'sal attributes and universal text attributes.' + @State ellipsisModeIndex: number = 2; + @State ellipsisMode: EllipsisMode[] = [EllipsisMode.START, EllipsisMode.CENTER, EllipsisMode.END] + + build() { + Column() { + Text(this.text) + .fontSize(16) + .border({ width: 1 }) + .lineHeight(20) + .maxLines(1) + .textOverflow({ overflow: TextOverflow.Ellipsis }) + .ellipsisMode(this.ellipsisMode[this.ellipsisModeIndex]) + .width(300) + .margin({ left: 20, top: 20 }) + .decoration({ + type: this.line, + color: this.color, + style: this.lineStyle + }) + Text('This is the text with the text overflow set marquee') + .width(300) + .borderWidth(1) + .textOverflow({ overflow: TextOverflow.MARQUEE }) + .decoration({ + type: this.line, + color: this.color, + style: this.lineStyle + }) + Button('切换装饰线') + .id('changeLineBt0300') + .onClick(() => { + this.line = TextDecorationType.Underline; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0310.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0310.ets new file mode 100644 index 00000000..103e66d1 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0310.ets @@ -0,0 +1,56 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0310 { + @State line: TextDecorationType | undefined = TextDecorationType.LineThrough; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color | undefined = undefined; + @State text: string = + 'The text component is used to display a piece of textual information.Support univer' + + 'sal attributes and universal text attributes.' + @State ellipsisModeIndex: number = 2; + @State ellipsisMode: EllipsisMode[] = [EllipsisMode.START, EllipsisMode.CENTER, EllipsisMode.END] + @State textOverflowType: TextOverflow = TextOverflow.Ellipsis + + build() { + Column() { + Text(this.text) + .fontSize(16) + .border({ width: 1 }) + .lineHeight(20) + .maxLines(1) + .textOverflow({ overflow: this.textOverflowType }) + .ellipsisMode(this.ellipsisMode[this.ellipsisModeIndex]) + .width(310) + .margin({ left: 20, top: 20 }) + .decoration({ + type: this.line, + color: this.color, + style: this.lineStyle + }) + Button('切换装饰线') + .id('changeLineBt0310') + .onClick(() => { + this.line = TextDecorationType.Underline; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + this.textOverflowType = TextOverflow.Clip + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0320.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0320.ets new file mode 100644 index 00000000..19f0410d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0320.ets @@ -0,0 +1,54 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0320 { + @State line: TextDecorationType | undefined = TextDecorationType.LineThrough; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color | undefined = undefined; + + build() { + Column() { + Text(){ + Span('哈哈哈hel世界') + .fontSize(10) + .margin(2) + Span('哈哈哈hel界') + .margin(2) + .fontSize(20) + .margin(2) + Span('哈哈哈he世界') + .fontSize(30) + } + .border({ width: 1 }) + .width(300) + .margin({ left: 20, top: 20 }) + .decoration({ + type: this.line, + color: this.color, + style: this.lineStyle + }) + Button('切换装饰线') + .id('changeLineBt0320') + .onClick(() => { + this.line = TextDecorationType.Overline; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0330.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0330.ets new file mode 100644 index 00000000..40266053 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0330.ets @@ -0,0 +1,66 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +class MyTextModifier implements AttributeModifier { + isChange: boolean = false; + applyNormalAttribute(instance: TextAttribute): void { + if (this.isChange) { + instance.decoration({ + type: TextDecorationType.Overline, + color: Color.Black, + style: TextDecorationStyle.WAVY + }) + }else { + instance.decoration({ + type: TextDecorationType.LineThrough, + color: Color.Red, + style: TextDecorationStyle.SOLID + }) + } + + } +} + +@Entry +@Component +struct UiComponentTextDecoration0330 { + @State modifier: MyTextModifier = new MyTextModifier() + + build() { + Column() { + Text(){ + Span('哈哈哈hel世界') + .fontSize(10) + .margin(2) + Span('哈哈哈hel界') + .margin(2) + .fontSize(20) + .margin(2) + Span('哈哈哈he世界') + .fontSize(30) + } + .border({ width: 1 }) + .width(300) + .margin({ left: 20, top: 20 }) + .attributeModifier(this.modifier) + Button('切换装饰线') + .id('changeLineBt0330') + .onClick(() => { + this.modifier.isChange = !this.modifier.isChange; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0360.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0360.ets new file mode 100644 index 00000000..dc0748ec --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0360.ets @@ -0,0 +1,84 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import Window from '@ohos.window' +import common from '@ohos.app.ability.common'; +@Entry +@Component +struct UiComponentTextDecoration0360 { + @State line: TextDecorationType | undefined = TextDecorationType.LineThrough; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color | undefined = undefined; + private portrait: boolean = true + private changeOrientation() { + //获取上下文 + //var context = getContext(this) as any + // 获取上下文,使用common模块 + let context = getContext(this) as common.UIAbilityContext; + let promise = Window.getLastWindow(context); + promise.then((data) => { + if (this.portrait) { + //切换成横屏 + let orientation = Window.Orientation.LANDSCAPE; + data.setPreferredOrientation(orientation, () => { + }); + this.portrait = !this.portrait + console.info('Succeeded in obtaining the top window. Data: ' + JSON.stringify(data)); + } + else { + //切换成竖屏 + let orientation = Window.Orientation.PORTRAIT; + data.setPreferredOrientation(orientation, () => { + }); + this.portrait = !this.portrait + console.info('Succeeded in obtaining the top window. Data: ' + JSON.stringify(data)); + } + }).catch((err:Error) => { + console.error('Failed to obtain the top window. Cause: ' + JSON.stringify(err)); + }); + } + build() { + Column() { + Text(){ + Span('哈哈哈hel世界') + .fontSize(10) + .margin(2) + Span('哈哈哈hel界') + .margin(2) + .fontSize(20) + .margin(2) + Span('哈哈哈he世界') + .fontSize(30) + } + .border({ width: 1 }) + .width(300) + .margin({ left: 20, top: 20 }) + .decoration({ + type: this.line, + color: this.color, + style: this.lineStyle + }) + Button('切换装饰线') + .id('changeLineBt0360') + .onClick(() => { + this.line = TextDecorationType.Overline; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY; + this.changeOrientation() + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0380.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0380.ets new file mode 100644 index 00000000..a8b26784 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0380.ets @@ -0,0 +1,85 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { text } from '@kit.ArkGraphics2D'; + +@Entry +@Component +struct UiComponentTextDecoration0380 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.underline, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0380') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.lineThrough, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0380') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.overline, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0380') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.none, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0380') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0390.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0390.ets new file mode 100644 index 00000000..743086b4 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0390.ets @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0390 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0390') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0390') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0390') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0390') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0400.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0400.ets new file mode 100644 index 00000000..99dd457f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0400.ets @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0400 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0400') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0400') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0400') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0400') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0410.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0410.ets new file mode 100644 index 00000000..6b8ef71e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0410.ets @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0410 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0410') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0410') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0410') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0410') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0420.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0420.ets new file mode 100644 index 00000000..dd6e909c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0420.ets @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0420 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0420') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(2) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0420') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(2) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0420') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(2) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0420') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0430.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0430.ets new file mode 100644 index 00000000..51a3696c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0430.ets @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0430 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0430') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(2) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0430') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(2) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0430') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(2) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0430') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0440.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0440.ets new file mode 100644 index 00000000..bcd978eb --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0440.ets @@ -0,0 +1,89 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0440 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: undefined = undefined; + + build() { + Column() { + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0440') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(2) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0440') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(2) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0440') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(2) + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0440') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0450.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0450.ets new file mode 100644 index 00000000..033a7f64 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0450.ets @@ -0,0 +1,44 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0450 { + @State lineType: TextDecorationType | undefined = TextDecorationType.Underline; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color = Color.Blue + + build() { + Column() { + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线') + .id('changeLineBt0450') + .onClick(() => { + this.lineType = TextDecorationType.LineThrough; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0460.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0460.ets new file mode 100644 index 00000000..461c706e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0460.ets @@ -0,0 +1,60 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { text } from '@kit.ArkGraphics2D'; + +@Entry +@Component +struct UiComponentTextDecoration0460 { + @State lineType: TextDecorationType | undefined = TextDecorationType.Underline; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color = Color.Blue + @State text: string = '装饰线Underline' + + build() { + Column() { + TextInput({ + text: this.text + }) + .id('textInput0460') + .decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线') + .id('changeLineBt0460') + .onClick(() => { + this.lineType = TextDecorationType.LineThrough; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + Button('增加文本内容') + .id('addTextBt0460') + .onClick(() => { + this.text = '装饰线UnderlineDada' + }) + .margin(2) + Button('删除文本长度') + .id('deleteTextBt0460') + .onClick(() => { + this.text = '装饰线Under' + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0470.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0470.ets new file mode 100644 index 00000000..3c372ae4 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0470.ets @@ -0,0 +1,48 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0470 { + @State lineType: TextDecorationType | undefined = TextDecorationType.Underline; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color = Color.Red; + + build() { + Column() { + TextInput({ + text: 'this is test text -- TextInput 测试装饰线' + }).draggable(true).decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }).margin(20).key('UiComponentTextDecoration0470_textInput') + Search({ + value: 'this is test text Search 测试装饰线' + }).draggable(true).decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }).margin(20).key('UiComponentTextDecoration0470_search') + TextArea({ + text: 'this is test text -- textArea 测试装饰线,this is test text -- textArea 测试装饰线' + }).maxLines(1).draggable(true).decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }).margin(20).key('UiComponentTextDecoration0470_textArea') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0480.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0480.ets new file mode 100644 index 00000000..103d4a73 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0480.ets @@ -0,0 +1,58 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +class MyTextInputModifier implements AttributeModifier { + isChange: boolean = false; + applyNormalAttribute(instance: TextInputAttribute): void { + if (this.isChange) { + instance.decoration({ + type: TextDecorationType.Overline, + color: Color.Black, + style: TextDecorationStyle.WAVY + }) + }else { + instance.decoration({ + type: TextDecorationType.LineThrough, + color: Color.Red, + style: TextDecorationStyle.SOLID + }) + } + + } +} + +@Entry +@Component +struct UiComponentTextDecoration0480 { + @State modifier: MyTextInputModifier = new MyTextInputModifier() + + build() { + Column() { + TextInput({ + text:'this is a test' + }) + .border({ width: 1 }) + .width(300) + .margin({ left: 20, top: 20 }) + .attributeModifier(this.modifier) + Button('切换装饰线') + .id('changeLineBt0480') + .onClick(() => { + this.modifier.isChange = !this.modifier.isChange; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0490.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0490.ets new file mode 100644 index 00000000..6c2be343 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0490.ets @@ -0,0 +1,45 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0490 { + @State lineType: TextDecorationType | undefined = TextDecorationType.Underline; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color = Color.Blue + + build() { + Column() { + TextInput({ + text:'装饰线Underline' + }) + .decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }) + .style(TextContentStyle.INLINE) + .margin(2) + Button('切换装饰线') + .id('changeLineBt0490') + .onClick(() => { + this.lineType = TextDecorationType.LineThrough; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0500.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0500.ets new file mode 100644 index 00000000..7ec5fb43 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0500.ets @@ -0,0 +1,85 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { text } from '@kit.ArkGraphics2D'; + +@Entry +@Component +struct UiComponentTextDecoration0500 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.underline, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0500') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.lineThrough, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0500') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.overline, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0500') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.none, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0500') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0510.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0510.ets new file mode 100644 index 00000000..b5db83ba --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0510.ets @@ -0,0 +1,88 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0510 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + + build() { + Column() { + Search({ + value: '装饰线Underline' + }) + .decoration({ + type: this.underline, + color: Color.Red, + style: TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0510') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + Search({ + value: '装饰线Underline' + }) + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0510') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + Search({ + value: '装饰线Underline' + }) + .decoration({ + type: this.overline, + color: Color.Red, + style: TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0510') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + Search({ + value: '装饰线Underline' + }) + .decoration({ + type: this.none, + color: Color.Red, + style: TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0510') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0520.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0520.ets new file mode 100644 index 00000000..0dacbc98 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0520.ets @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0520 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0520') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0520') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0520') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0520') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0530.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0530.ets new file mode 100644 index 00000000..2caf5167 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0530.ets @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0530 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0530') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0530') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0530') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0530') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0540.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0540.ets new file mode 100644 index 00000000..920b7c05 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0540.ets @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0540 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0540') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(2) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0540') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(2) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0540') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(2) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0540') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0550.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0550.ets new file mode 100644 index 00000000..8274bbd6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0550.ets @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0550 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0550') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(2) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0550') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(2) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0550') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(2) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0550') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0560.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0560.ets new file mode 100644 index 00000000..43241b57 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0560.ets @@ -0,0 +1,89 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0560 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: undefined = undefined; + + build() { + Column() { + Search({ + value:'装饰线Underline' + }) + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0560') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(2) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0560') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(2) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0560') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(2) + Search({ + value:'装饰线Underline' + }) + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0560') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0570.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0570.ets new file mode 100644 index 00000000..66462e60 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0570.ets @@ -0,0 +1,44 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0570 { + @State lineType: TextDecorationType | undefined = TextDecorationType.Underline; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color = Color.Blue + + build() { + Column() { + Search({ + value:'装饰线Underline' + }) + .decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线') + .id('changeLineBt0570') + .onClick(() => { + this.lineType = TextDecorationType.LineThrough; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0580.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0580.ets new file mode 100644 index 00000000..2c256247 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0580.ets @@ -0,0 +1,60 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { text } from '@kit.ArkGraphics2D'; + +@Entry +@Component +struct UiComponentTextDecoration0580 { + @State lineType: TextDecorationType | undefined = TextDecorationType.Underline; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color = Color.Blue + @State text: string = '装饰线Underline' + + build() { + Column() { + Search({ + value: this.text + }) + .id('search0580') + .decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线') + .id('changeLineBt0580') + .onClick(() => { + this.lineType = TextDecorationType.LineThrough; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + Button('增加文本内容') + .id('addTextBt0580') + .onClick(() => { + this.text = '装饰线UnderlineDada' + }) + .margin(2) + Button('删除文本长度') + .id('deleteTextBt0580') + .onClick(() => { + this.text = '装饰线Under' + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0600.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0600.ets new file mode 100644 index 00000000..ca119a9e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0600.ets @@ -0,0 +1,58 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +class MySearchModifier implements AttributeModifier { + isChange: boolean = false; + applyNormalAttribute(instance: SearchAttribute): void { + if (this.isChange) { + instance.decoration({ + type: TextDecorationType.Overline, + color: Color.Black, + style: TextDecorationStyle.WAVY + }) + }else { + instance.decoration({ + type: TextDecorationType.LineThrough, + color: Color.Red, + style: TextDecorationStyle.SOLID + }) + } + + } +} + +@Entry +@Component +struct UiComponentTextDecoration0600 { + @State modifier: MySearchModifier = new MySearchModifier() + + build() { + Column() { + Search({ + value:'装饰线Underline' + }) + .border({ width: 1 }) + .width(300) + .margin({ left: 20, top: 20 }) + .attributeModifier(this.modifier) + Button('切换装饰线') + .id('changeLineBt0600') + .onClick(() => { + this.modifier.isChange = !this.modifier.isChange; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0610.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0610.ets new file mode 100644 index 00000000..4d068cd3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0610.ets @@ -0,0 +1,83 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0610 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + TextArea({ + text:'装饰线Underline' + }) + .decoration({ + type:this.underline, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0610') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + TextArea({ + text:'装饰线Underline' + }) + .decoration({ + type:this.lineThrough, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0610') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + TextArea({ + text:'装饰线Underline' + }) + .decoration({ + type:this.overline, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0610') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + TextArea({ + text:'装饰线Underline' + }) + .decoration({ + type:this.none, + color: Color.Red, + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0610') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0620.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0620.ets new file mode 100644 index 00000000..bd637d80 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0620.ets @@ -0,0 +1,88 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0620 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + + build() { + Column() { + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.underline, + color: Color.Red, + style: TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0620') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0620') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.overline, + color: Color.Red, + style: TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0620') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.none, + color: Color.Red, + style: TextDecorationStyle.SOLID + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0620') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0630.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0630.ets new file mode 100644 index 00000000..616bc9d5 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0630.ets @@ -0,0 +1,88 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0630 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + + build() { + Column() { + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.underline, + color: Color.Red, + style: TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0630') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0630') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.overline, + color: Color.Red, + style: TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0630') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.none, + color: Color.Red, + style: TextDecorationStyle.DOUBLE + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0630') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0640.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0640.ets new file mode 100644 index 00000000..f760bc9e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0640.ets @@ -0,0 +1,88 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0640 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + + build() { + Column() { + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.underline, + color: Color.Red, + style: TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线Underline') + .id('underlineBt0640') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(1) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0640') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(1) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.overline, + color: Color.Red, + style: TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线Overline') + .id('overlineBt0640') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(1) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.none, + color: Color.Red, + style: TextDecorationStyle.DOTTED + }) + .margin(1) + Button('切换装饰线None') + .id('noneBt0640') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(1) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0650.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0650.ets new file mode 100644 index 00000000..7f6296f8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0650.ets @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0650 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0650') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(2) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0650') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(2) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0650') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(2) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.DASHED + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0650') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0660.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0660.ets new file mode 100644 index 00000000..a924ab8f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0660.ets @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0660 { + @State underline:TextDecorationType | undefined = undefined; + @State lineThrough:TextDecorationType | undefined = undefined; + @State overline:TextDecorationType | undefined = undefined; + @State none:TextDecorationType | undefined = undefined; + build() { + Column() { + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type:this.underline, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0660') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(2) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type:this.lineThrough, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0660') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(2) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type:this.overline, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0660') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(2) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type:this.none, + color: Color.Red, + style:TextDecorationStyle.WAVY + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0660') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0670.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0670.ets new file mode 100644 index 00000000..9f97a819 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0670.ets @@ -0,0 +1,89 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0670 { + @State underline: TextDecorationType | undefined = undefined; + @State lineThrough: TextDecorationType | undefined = undefined; + @State overline: TextDecorationType | undefined = undefined; + @State none: TextDecorationType | undefined = undefined; + @State lineStyle: undefined = undefined; + + build() { + Column() { + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.underline, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线Underline') + .id('underlineBt0670') + .onClick(() => { + this.underline = TextDecorationType.Underline + }) + .margin(2) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.lineThrough, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线LineThrough') + .id('underLineThroughBt0670') + .onClick(() => { + this.lineThrough = TextDecorationType.LineThrough + }) + .margin(2) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.overline, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线Overline') + .id('overlineBt0670') + .onClick(() => { + this.overline = TextDecorationType.Overline + }) + .margin(2) + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.none, + color: Color.Red, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线None') + .id('noneBt0670') + .onClick(() => { + this.none = TextDecorationType.None + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0680.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0680.ets new file mode 100644 index 00000000..46614fc4 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0680.ets @@ -0,0 +1,44 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0680 { + @State lineType: TextDecorationType | undefined = TextDecorationType.Underline; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color = Color.Blue + + build() { + Column() { + TextArea({ + text: '装饰线Underline' + }) + .decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线') + .id('changeLineBt0680') + .onClick(() => { + this.lineType = TextDecorationType.LineThrough; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0690.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0690.ets new file mode 100644 index 00000000..71c54ac3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0690.ets @@ -0,0 +1,60 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { text } from '@kit.ArkGraphics2D'; + +@Entry +@Component +struct UiComponentTextDecoration0690 { + @State lineType: TextDecorationType | undefined = TextDecorationType.Underline; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color = Color.Blue + @State text: string = '装饰线Underline' + + build() { + Column() { + TextArea({ + text: '装饰线Underline' + }) + .id('textArea0690') + .decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }) + .margin(2) + Button('切换装饰线') + .id('changeLineBt0690') + .onClick(() => { + this.lineType = TextDecorationType.LineThrough; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + Button('增加文本内容') + .id('addTextBt0690') + .onClick(() => { + this.text = '装饰线UnderlineDada' + }) + .margin(2) + Button('删除文本长度') + .id('deleteTextBt0690') + .onClick(() => { + this.text = '装饰线Under' + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0710.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0710.ets new file mode 100644 index 00000000..af61c4db --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0710.ets @@ -0,0 +1,58 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +class MyTextAreaModifier implements AttributeModifier { + isChange: boolean = false; + applyNormalAttribute(instance: TextAreaAttribute): void { + if (this.isChange) { + instance.decoration({ + type: TextDecorationType.Overline, + color: Color.Black, + style: TextDecorationStyle.WAVY + }) + }else { + instance.decoration({ + type: TextDecorationType.LineThrough, + color: Color.Red, + style: TextDecorationStyle.SOLID + }) + } + + } +} + +@Entry +@Component +struct UiComponentTextDecoration0710 { + @State modifier: MyTextAreaModifier = new MyTextAreaModifier() + + build() { + Column() { + TextArea({ + text: '装饰线Underline' + }) + .border({ width: 1 }) + .width(300) + .margin({ left: 20, top: 20 }) + .attributeModifier(this.modifier) + Button('切换装饰线') + .id('changeLineBt0710') + .onClick(() => { + this.modifier.isChange = !this.modifier.isChange; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0720.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0720.ets new file mode 100644 index 00000000..2ca4fd52 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0720.ets @@ -0,0 +1,45 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextDecoration0720 { + @State lineType: TextDecorationType | undefined = TextDecorationType.Underline; + @State lineStyle: TextDecorationStyle | undefined = TextDecorationStyle.SOLID; + @State color: Color = Color.Blue + + build() { + Column() { + TextArea({ + text:'装饰线Underline' + }) + .decoration({ + type: this.lineType, + color: this.color, + style: this.lineStyle + }) + .style(TextContentStyle.INLINE) + .margin(2) + Button('切换装饰线') + .id('changeLineBt0720') + .onClick(() => { + this.lineType = TextDecorationType.LineThrough; + this.color = Color.Red; + this.lineStyle = TextDecorationStyle.WAVY + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextEditMeauOptions/UiComponentTextEditMeauOptions0030.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextEditMeauOptions/UiComponentTextEditMeauOptions0030.ets new file mode 100644 index 00000000..1b265c29 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextEditMeauOptions/UiComponentTextEditMeauOptions0030.ets @@ -0,0 +1,73 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextEditMeauOptions0030 { + @State text: string = 'Text editMenuOptions' + + onCreateMenu(menuItems: Array) { + menuItems.forEach((value, index) => { + value.icon = $r('app.media.icon') + if (value.id.equals(TextMenuItemId.COPY)) { + value.content = "复制change" + } + if (value.id.equals(TextMenuItemId.SELECT_ALL)) { + value.content = "全选change" + } + }) + let item1: TextMenuItem = { + content: 'custom1', + icon: $r('app.media.icon'), + id: TextMenuItemId.of('custom1'), + } + let item2: TextMenuItem = { + content: 'custom22312313123123123123123123123131313', + id: TextMenuItemId.of('custom2'), + icon: $r('app.media.icon'), + } + menuItems.push(item1) + menuItems.unshift(item2) + return menuItems + } + + build() { + Column() { + Text(this.text) + .fontSize(20) + .copyOption(CopyOptions.LocalDevice) + .editMenuOptions({ + onCreateMenu: this.onCreateMenu, onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + if (menuItem.id.equals(TextMenuItemId.of("custom2"))) { + console.log("拦截 id: custom2 start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.COPY)) { + console.log("拦截 COPY start:" + textRange.start + "; end:" + textRange.end) + return true; + } + if (menuItem.id.equals(TextMenuItemId.SELECT_ALL)) { + console.log("不拦截 SELECT_ALL start:" + textRange.start + "; end:" + textRange.end) + return false; + } + return false; + } + }) + .margin({ top: 100 }) + .id('TextEditMeauOptions0030text') + } + .width("90%") + .margin("5%") + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0010.ets new file mode 100644 index 00000000..ec3991bf --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0010.ets @@ -0,0 +1,54 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextInputDeleteCallBack0010 { + @State insertValue: string = ""; + @State insertOffset: number = 0; + build() { + Column() { + TextInput() + .id('textInputDeleteCallBack0010') + .margin(2) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.insertOffset = info.insertOffset + return true; + }) + Text("TextInput insertValue:" + this.insertValue + " TextInput insertOffset:" + this.insertOffset) + .height(30) + Search() + .id('SearchDeleteCallBack0010') + .margin(2) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.insertOffset = info.insertOffset + return true; + }) + Text("Search insertValue:" + this.insertValue + " Search insertOffset:" + this.insertOffset) + .height(30) + TextArea() + .id('TextAreaDeleteCallBack0010') + .margin(2) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.insertOffset = info.insertOffset + return true; + }) + Text("TextArea insertValue:" + this.insertValue + " TextArea insertOffset:" + this.insertOffset) + .height(30) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0020.ets new file mode 100644 index 00000000..8334c8df --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0020.ets @@ -0,0 +1,54 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextInputDeleteCallBack0020 { + @State insertValue: string = ""; + @State insertOffset: number = 0; + build() { + Column() { + TextInput() + .id('textInputDeleteCallBack0020') + .margin(2) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.insertOffset = info.insertOffset + return false; + }) + Text("TextInput insertValue:" + this.insertValue + " TextInput insertOffset:" + this.insertOffset) + .height(30) + Search() + .id('SearchDeleteCallBack0020') + .margin(2) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.insertOffset = info.insertOffset + return false; + }) + Text("Search insertValue:" + this.insertValue + " Search insertOffset:" + this.insertOffset) + .height(30) + TextArea() + .id('TextAreaDeleteCallBack0020') + .margin(2) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.insertOffset = info.insertOffset + return false; + }) + Text("TextArea insertValue:" + this.insertValue + " TextArea insertOffset:" + this.insertOffset) + .height(30) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0030.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0030.ets new file mode 100644 index 00000000..bad7a30c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0030.ets @@ -0,0 +1,58 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextInputDeleteCallBack0030 { + @State insertValue: string = ""; + @State insertOffset: number = 0; + @State text: string = ''; + + build() { + Column() { + TextInput() + .id('textInputDeleteCallBack0030') + .margin(2) + .type(InputType.Normal) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.insertOffset = info.insertOffset + console.log('SUB_ACE_UI_COMPONENT_TEXT_INPUT_DELETE_CALLBACK_0030', this.insertValue, this.insertOffset) + return true; + }) + Text("TextInput insertValue:" + this.insertValue + " TextInput insertOffset:" + this.insertOffset) + .height(30) + Search() + .id('SearchDeleteCallBack0030') + .margin(2) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.insertOffset = info.insertOffset + return true; + }) + Text("Search insertValue:" + this.insertValue + " Search insertOffset:" + this.insertOffset) + .height(30) + TextArea() + .id('TextAreaDeleteCallBack0030') + .margin(2) + .onWillInsert((info: InsertValue) => { + this.insertValue = info.insertValue; + this.insertOffset = info.insertOffset + return true; + }) + Text("TextArea insertValue:" + this.insertValue + " TextArea insertOffset:" + this.insertOffset) + .height(30) + } + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0010.ets new file mode 100755 index 00000000..8602d784 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0010.ets @@ -0,0 +1,100 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; +@Entry +@Component +struct UiComponentTextInputReplacement0010 { + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + searchController: SearchController = new SearchController(); + textAreaController: TextAreaController = new TextAreaController() + textInputController: TextInputController = new TextInputController() + private editorMenuOptions: Array = + [{ icon: 'icon.png' }, { icon: 'cat.jpg' }, { icon: 'openeye.png' }, { icon: 'icon.png' }, { icon: 'openeye.png' }, + { icon: 'cat.jpg' }] + private expandedMenuOptions: Array = + [{ + startIcon: 'cat.jpg', content: '词典', action: () => { + console.log('click it>>'); + this.options.controller.closeSelectionMenu(); + } + }, { + startIcon: 'icon.png', content: '翻译', action: () => { + } + }, { + startIcon: 'openeye.png', content: '搜索', action: () => { + } + }] + private selectionMenuOptions: SelectionMenuOptions = { + editorMenuOptions: this.editorMenuOptions, + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + onCreateMenu(menuItems: Array) { + console.log('menuItems size=' + menuItems.length); + menuItems.forEach((value, index) => { + console.log('menuItem' + index + ', id=' + JSON.stringify(value)); + }) + let extensionMenuItems: Array = [ + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension1') + }, + ] + return menuItems.concat(extensionMenuItems) + } + onMenuItemClicked(menuItem: TextMenuItem, textRange: TextRange) { + if (menuItem.id.equals(TextMenuItemId.of('extension1'))) { + console.log('click' + menuItem.content + ', textRange=' + JSON.stringify(textRange)) + return true; + } + return false; + } + + build() { + Row() { + RichEditor(this.options) + .id('richEditor') + .onReady(() => { + this.controller.addTextSpan("RichEditor扩展") + }) + .editMenuOptions({ + onCreateMenu: (menuItems: Array) => { + return this.onCreateMenu(menuItems) + }, + onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return this.onMenuItemClicked(menuItem, textRange) + } + }) + .height(200) + .borderWidth(1) + .borderColor(Color.Red) + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0020.ets new file mode 100755 index 00000000..87c94dca --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0020.ets @@ -0,0 +1,82 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextInputReplacement0020 { + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + + onCreateMenu(menuItems: Array) { + console.log('menuItems size=' + menuItems.length); + menuItems.forEach((value, index) => { + console.log('menuItem' + index + ', id=' + JSON.stringify(value)); + }) + let extensionMenuItems: Array = [ + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension1') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension2') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension3') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension4') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension5') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension6') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension7') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension8') + }, + ] + return menuItems.concat(extensionMenuItems) + } + onMenuItemClicked(menuItem: TextMenuItem, textRange: TextRange) { + if (menuItem.id.equals(TextMenuItemId.of('extension1'))) { + console.log('click' + menuItem.content + ', textRange=' + JSON.stringify(textRange)) + return true; + } + return false; + } + + build() { + Row() { + RichEditor(this.options) + .id('richEditor') + .onReady(() => { + this.controller.addTextSpan("RichEditor扩展") + }) + .editMenuOptions({ + onCreateMenu: (menuItems: Array) => { + return this.onCreateMenu(menuItems) + }, + onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return this.onMenuItemClicked(menuItem, textRange) + } + }) + .height(200) + .borderWidth(1) + .borderColor(Color.Red) + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0030.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0030.ets new file mode 100755 index 00000000..f6ddecc6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0030.ets @@ -0,0 +1,73 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextInputReplacement0030 { + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + + onCreateMenu(menuItems: Array) { + console.log('menuItems size=' + menuItems.length); + menuItems.forEach((value, index) => { + console.log('menuItem' + index + ', id=' + JSON.stringify(value)); + }) + let extensionMenuItems: Array = [ + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension1') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension2') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension3') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension4') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension5') + }, + ] + return menuItems.concat(extensionMenuItems) + } + onMenuItemClicked(menuItem: TextMenuItem, textRange: TextRange) { + if (menuItem.id.equals(TextMenuItemId.of('extension1'))) { + console.log('click' + menuItem.content + ', textRange=' + JSON.stringify(textRange)) + return true; + } + return false; + } + + build() { + Row() { + RichEditor(this.options) + .id('richEditor') + .onReady(() => { + this.controller.addTextSpan("RichEditor扩展") + }) + .editMenuOptions({ + onCreateMenu: (menuItems: Array) => { + return this.onCreateMenu(menuItems) + }, + onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return this.onMenuItemClicked(menuItem, textRange) + } + }) + .height(200) + .borderWidth(1) + .borderColor(Color.Red) + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0040.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0040.ets new file mode 100755 index 00000000..25817335 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0040.ets @@ -0,0 +1,97 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; +@Entry +@Component +struct UiComponentTextInputReplacement0030 { + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + private expandedMenuOptions: Array = + [{ startIcon: $r("app.media.icon"), content: '词典', action: () => { + } }, { startIcon: $r("app.media.icon"), content: '翻译', action: () => { + } }, { startIcon: $r("app.media.icon"), content: '搜索', action: () => { + } }] + private selectionMenuOptions: SelectionMenuOptions = { + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + onCreateMenu(menuItems: Array) { + console.log('menuItems size=' + menuItems.length); + menuItems.forEach((value, index) => { + console.log('menuItem' + index + ', id=' + JSON.stringify(value)); + }) + let extensionMenuItems: Array = [ + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension1') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension2') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension3') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension4') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension5') + }, + ] + return menuItems.concat(extensionMenuItems) + } + onMenuItemClicked(menuItem: TextMenuItem, textRange: TextRange) { + if (menuItem.id.equals(TextMenuItemId.of('extension1'))) { + console.log('click' + menuItem.content + ', textRange=' + JSON.stringify(textRange)) + return true; + } + return false; + } + + build() { + Row() { + RichEditor(this.options) + .id('richEditor') + .onReady(() => { + this.controller.addTextSpan("RichEditor扩展") + }) + .editMenuOptions({ + onCreateMenu: (menuItems: Array) => { + return this.onCreateMenu(menuItems) + }, + onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return this.onMenuItemClicked(menuItem, textRange) + } + }) + .height(200) + .borderWidth(1) + .borderColor(Color.Red) + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0050.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0050.ets new file mode 100755 index 00000000..dae76522 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0050.ets @@ -0,0 +1,112 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; +@Entry +@Component +struct UiComponentTextInputReplacement0030 { + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + private expandedMenuOptions: Array = + [{ startIcon: $r("app.media.icon"), content: '词典', action: () => { + } }, { startIcon: $r("app.media.icon"), content: '翻译', action: () => { + } }, { startIcon: $r("app.media.icon"), content: '搜索', action: () => { + } }] + private selectionMenuOptions: SelectionMenuOptions = { + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + onCreateMenu(menuItems: Array) { + console.log('menuItems size=' + menuItems.length); + menuItems.forEach((value, index) => { + console.log('menuItem' + index + ', id=' + JSON.stringify(value)); + }) + let extensionMenuItems: Array = [ + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension1') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension2') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension3') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension4') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension5') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension6') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension7') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension8') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension9') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension10') + }, + ] + return menuItems.concat(extensionMenuItems) + } + onMenuItemClicked(menuItem: TextMenuItem, textRange: TextRange) { + if (menuItem.id.equals(TextMenuItemId.of('extension1'))) { + console.log('click' + menuItem.content + ', textRange=' + JSON.stringify(textRange)) + return true; + } + return false; + } + + build() { + Row() { + RichEditor(this.options) + .id('richEditor') + .onReady(() => { + this.controller.addTextSpan("RichEditor扩展") + }) + .editMenuOptions({ + onCreateMenu: (menuItems: Array) => { + return this.onCreateMenu(menuItems) + }, + onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return this.onMenuItemClicked(menuItem, textRange) + } + }) + .height(200) + .borderWidth(1) + .borderColor(Color.Red) + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0060.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0060.ets new file mode 100755 index 00000000..7e60eef7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0060.ets @@ -0,0 +1,106 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; +@Entry +@Component +struct UiComponentTextInputReplacement0030 { + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + @State color: Color|string = "" + private expandedMenuOptions: Array = + [{ startIcon: $r("app.media.icon"), content: '词典', action: () => { + } }, { startIcon: $r("app.media.icon"), content: '翻译', action: () => { + } }, { startIcon: $r("app.media.icon"), content: '搜索', action: () => { + } }] + private selectionMenuOptions: SelectionMenuOptions = { + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + onCreateMenu(menuItems: Array) { + console.log('menuItems size=' + menuItems.length); + menuItems.forEach((value, index) => { + console.log('menuItem' + index + ', id=' + JSON.stringify(value)); + }) + let extensionMenuItems: Array = [ + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension1'), + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension2') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension3') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension4') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension4') + }, + ]; + + return menuItems.concat(extensionMenuItems) + } + onMenuItemClicked(menuItem: TextMenuItem, textRange: TextRange) { + if (menuItem.id.equals(TextMenuItemId.of('extension1'))) { + console.log('click' + menuItem.content + ', textRange=' + JSON.stringify(textRange)) + return true; + } + return false; + } + + build() { + Column(){ + Column(){ + Row() { + RichEditor(this.options) + .id('richEditor') + .borderColor(Color.Red) + .height(200) + .borderWidth(1) + .onReady(() => { + this.controller.addTextSpan("RichEditor扩展") + }) + .editMenuOptions({ + onCreateMenu: (menuItems: Array) => { + return this.onCreateMenu(menuItems) + }, + onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return this.onMenuItemClicked(menuItem, textRange) + } + }) + .height(200) + .borderWidth(1) + .borderColor(Color.Red) + } + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0070.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0070.ets new file mode 100755 index 00000000..f846e3a1 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0070.ets @@ -0,0 +1,102 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; +@Entry +@Component +struct UiComponentTextInputReplacement0030 { + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + @State color: Color|string = "" + private expandedMenuOptions: Array = + [{ startIcon: $r("app.media.icon"), content: '词典', action: () => { + } }, { startIcon: $r("app.media.icon"), content: '翻译', action: () => { + } }, { startIcon: $r("app.media.icon"), content: '搜索', action: () => { + } }] + private selectionMenuOptions: SelectionMenuOptions = { + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + onCreateMenu(menuItems: Array) { + console.log('menuItems size=' + menuItems.length); + menuItems.forEach((value, index) => { + console.log('menuItem' + index + ', id=' + JSON.stringify(value)); + }) + let extensionMenuItems: Array = [ + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension1') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension2') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension3') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension4') + }, + ] + return menuItems.concat(extensionMenuItems) + } + onMenuItemClicked(menuItem: TextMenuItem, textRange: TextRange) { + if (menuItem.id.equals(TextMenuItemId.of('extension1'))) { + console.log('click' + menuItem.content + ', textRange=' + JSON.stringify(textRange)) + return true; + } + return false; + } + + build() { + Column(){ + Column(){ + Row() { + RichEditor(this.options) + .id('richEditor') + .borderColor(Color.Red) + .height(200) + .borderWidth(1) + .onReady(() => { + this.controller.addTextSpan("RichEditor扩展") + }) + .editMenuOptions({ + onCreateMenu: (menuItems: Array) => { + return this.onCreateMenu(menuItems) + }, + onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return this.onMenuItemClicked(menuItem, textRange) + } + }) + .height(200) + .borderWidth(1) + .borderColor(Color.Red) + } + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0080.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0080.ets new file mode 100755 index 00000000..2135a47c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0080.ets @@ -0,0 +1,102 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; +@Entry +@Component +struct UiComponentTextInputReplacement0030 { + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + @State color: Color|string = "" + private expandedMenuOptions: Array = + [{ startIcon: $r("app.media.icon"), content: '词典', action: () => { + } }, { startIcon: $r("app.media.icon"), content: '翻译', action: () => { + } }, { startIcon: $r("app.media.icon"), content: '搜索', action: () => { + } }] + private selectionMenuOptions: SelectionMenuOptions = { + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + onCreateMenu(menuItems: Array) { + console.log('menuItems size=' + menuItems.length); + menuItems.forEach((value, index) => { + console.log('menuItem' + index + ', id=' + JSON.stringify(value)); + }) + let extensionMenuItems: Array = [ + { + content: 'RichEditor扩展111111111111111111111111111111111111111111', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension1') + }, + { + content: 'RichEditor扩展111111111111111111111111111111111111111111', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension2') + }, + { + content: 'RichEditor扩展111111111111111111111111111111111111111111', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension3') + }, + { + content: 'RichEditor扩展111111111111111111111111111111111111111111', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension4') + }, + ] + return menuItems.concat(extensionMenuItems) + } + onMenuItemClicked(menuItem: TextMenuItem, textRange: TextRange) { + if (menuItem.id.equals(TextMenuItemId.of('extension1'))) { + console.log('click' + menuItem.content + ', textRange=' + JSON.stringify(textRange)) + return true; + } + return false; + } + + build() { + Column(){ + Column(){ + Row() { + RichEditor(this.options) + .id('richEditor') + .borderColor(Color.Red) + .height(200) + .borderWidth(1) + .onReady(() => { + this.controller.addTextSpan("RichEditor扩展") + }) + .editMenuOptions({ + onCreateMenu: (menuItems: Array) => { + return this.onCreateMenu(menuItems) + }, + onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return this.onMenuItemClicked(menuItem, textRange) + } + }) + .height(200) + .borderWidth(1) + .borderColor(Color.Red) + } + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0090.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0090.ets new file mode 100755 index 00000000..183ce53c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0090.ets @@ -0,0 +1,120 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { + SelectionMenu, + EditorMenuOptions, + ExpandedMenuOptions, + EditorEventInfo, + SelectionMenuOptions +} from '@kit.ArkUI'; +@Entry +@Component +struct UiComponentTextInputReplacement0030 { + controller: RichEditorController = new RichEditorController(); + options: RichEditorOptions = { controller: this.controller } + @State color: Color|string = "" + private expandedMenuOptions: Array = + [{ startIcon: $r("app.media.icon"), content: '词典', action: () => { + } }, { startIcon: $r("app.media.icon"), content: '翻译', action: () => { + } }, { startIcon: $r("app.media.icon"), content: '搜索', action: () => { + } }] + private selectionMenuOptions: SelectionMenuOptions = { + controller: this.controller, + expandedMenuOptions: this.expandedMenuOptions + } + + @Builder + MyMenu() { + Column() { + SelectionMenu(this.selectionMenuOptions); + } + .width(256) + .backgroundColor(Color.Transparent) + } + onCreateMenu(menuItems: Array) { + console.log('menuItems size=' + menuItems.length); + menuItems.forEach((value, index) => { + console.log('menuItem' + index + ', id=' + JSON.stringify(value)); + }) + let extensionMenuItems: Array = [ + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension1') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension2') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension3') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension4') + }, + { + content: 'RichEditor扩展111111111111111111111111111111111111111111', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension1') + }, + { + content: 'RichEditor扩展111111111111111111111111111111111111111111', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension2') + }, + { + content: 'RichEditor扩展111111111111111111111111111111111111111111', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension3') + }, + { + content: 'RichEditor扩展111111111111111111111111111111111111111111', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension4') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension3') + }, + { + content: 'RichEditor扩展1', icon: $r('app.media.icon'), id: TextMenuItemId.of('extension4') + }, + ] + return menuItems.concat(extensionMenuItems) + } + onMenuItemClicked(menuItem: TextMenuItem, textRange: TextRange) { + if (menuItem.id.equals(TextMenuItemId.of('extension1'))) { + console.log('click' + menuItem.content + ', textRange=' + JSON.stringify(textRange)) + return true; + } + return false; + } + + build() { + Column(){ + Column(){ + Row() { + RichEditor(this.options) + .id('richEditor') + .borderColor(Color.Red) + .height(200) + .borderWidth(1) + .onReady(() => { + this.controller.addTextSpan("RichEditor扩展") + }) + .editMenuOptions({ + onCreateMenu: (menuItems: Array) => { + return this.onCreateMenu(menuItems) + }, + onMenuItemClick: (menuItem: TextMenuItem, textRange: TextRange) => { + return this.onMenuItemClicked(menuItem, textRange) + } + }) + .height(200) + .borderWidth(1) + .borderColor(Color.Red) + } + } + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0010.ets new file mode 100644 index 00000000..2dd5b67b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0010.ets @@ -0,0 +1,48 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0010 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + + build() { + Column() { + TextInput({ + text: '文本布局' + }) + .direction(this.textInputDirection) + Search({ + value: '文本布局' + }) + .direction(this.searchDirection) + TextArea({ + text: '文本布局' + }) + .direction(this.textAreaDirection) + .margin(2) + Button('切换文本布局') + .id('changeDirection0010') + .onClick(() => { + this.textInputDirection = Direction.Ltr; + this.searchDirection = Direction.Rtl; + this.textAreaDirection = Direction.Auto; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0040.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0040.ets new file mode 100644 index 00000000..c6f6dd33 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0040.ets @@ -0,0 +1,51 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0040 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + + build() { + Column() { + TextInput({ + text: '文本布局' + }) + .textAlign(TextAlign.Start) + .direction(this.textInputDirection) + Search({ + value: '文本布局' + }) + .textAlign(TextAlign.Start) + .direction(this.searchDirection) + TextArea({ + text: '文本布局' + }) + .textAlign(TextAlign.Start) + .direction(this.textAreaDirection) + .margin(2) + Button('切换文本布局') + .id('changeDirection0040') + .onClick(() => { + this.textInputDirection = Direction.Ltr; + this.searchDirection = Direction.Rtl; + this.textAreaDirection = Direction.Auto; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0050.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0050.ets new file mode 100644 index 00000000..210b4364 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0050.ets @@ -0,0 +1,51 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0050 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + + build() { + Column() { + TextInput({ + text: '文本布局' + }) + .textAlign(TextAlign.Center) + .direction(this.textInputDirection) + Search({ + value: '文本布局' + }) + .textAlign(TextAlign.Center) + .direction(this.searchDirection) + TextArea({ + text: '文本布局' + }) + .textAlign(TextAlign.Center) + .direction(this.textAreaDirection) + .margin(2) + Button('切换文本布局') + .id('changeDirection0050') + .onClick(() => { + this.textInputDirection = Direction.Ltr; + this.searchDirection = Direction.Rtl; + this.textAreaDirection = Direction.Auto; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0060.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0060.ets new file mode 100644 index 00000000..429a4dfa --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0060.ets @@ -0,0 +1,51 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0060 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + + build() { + Column() { + TextInput({ + text: '文本布局' + }) + .textAlign(TextAlign.End) + .direction(this.textInputDirection) + Search({ + value: '文本布局' + }) + .textAlign(TextAlign.End) + .direction(this.searchDirection) + TextArea({ + text: '文本布局' + }) + .textAlign(TextAlign.End) + .direction(this.textAreaDirection) + .margin(2) + Button('切换文本布局') + .id('changeDirection0060') + .onClick(() => { + this.textInputDirection = Direction.Ltr; + this.searchDirection = Direction.Rtl; + this.textAreaDirection = Direction.Auto; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0070.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0070.ets new file mode 100644 index 00000000..5006bd82 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0070.ets @@ -0,0 +1,51 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0070 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + + build() { + Column() { + TextInput({ + text: '文本布局' + }) + .textAlign(TextAlign.JUSTIFY) + .direction(this.textInputDirection) + Search({ + value: '文本布局' + }) + .textAlign(TextAlign.JUSTIFY) + .direction(this.searchDirection) + TextArea({ + text: '文本布局' + }) + .textAlign(TextAlign.JUSTIFY) + .direction(this.textAreaDirection) + .margin(2) + Button('切换文本布局') + .id('changeDirection0070') + .onClick(() => { + this.textInputDirection = Direction.Ltr; + this.searchDirection = Direction.Rtl; + this.textAreaDirection = Direction.Auto; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0080.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0080.ets new file mode 100644 index 00000000..14d7697c --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0080.ets @@ -0,0 +1,58 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0080 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + @State inputType: InputType | undefined = undefined; + @State searchType: SearchType | undefined = undefined; + @State textAreaType: TextAreaType | undefined = undefined; + + build() { + Column() { + TextInput({ + text: '文本布局' + }) + .type(this.inputType) + .showPassword(true) + .direction(this.textInputDirection) + Search({ + value: '文本布局' + }) + .type(this.searchType) + .direction(this.searchDirection) + TextArea({ + text: '文本布局' + }) + .type(this.textAreaType) + .direction(this.textAreaDirection) + .margin(2) + Button('切换文本布局和类型') + .id('changeDirection0080') + .onClick(() => { + this.textInputDirection = Direction.Ltr; + this.searchDirection = Direction.Rtl; + this.textAreaDirection = Direction.Auto; + this.inputType = InputType.USER_NAME; + this.searchType = SearchType.NORMAL; + this.textAreaType = TextAreaType.NORMAL; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0090.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0090.ets new file mode 100644 index 00000000..eaff8994 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0090.ets @@ -0,0 +1,82 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0090 { + @State textInputDirection: Direction | undefined = undefined; + @State textInputTwoDirection: Direction | undefined = undefined; + @State textInputThrDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State textAreaTwoDirection: Direction | undefined = undefined; + @State textAreaThrDirection: Direction | undefined = undefined; + @State textOverflow: TextOverflow | undefined = TextOverflow.Ellipsis; + + build() { + Column() { + TextInput({ + text: '文本布局1111111111' + }) + .textOverflow(this.textOverflow) + .direction(this.textInputDirection) + TextInput({ + text: '文本布局111111111111' + }) + .textOverflow(this.textOverflow) + .direction(this.textInputTwoDirection) + TextInput({ + text: '文本布局111111111111111' + }) + .textOverflow(this.textOverflow) + .direction(this.textInputThrDirection) + TextArea({ + text: '文本布局2222222222222222222' + }) + .width('50%') + .maxLines(1) + .textOverflow(this.textOverflow) + .direction(this.textAreaDirection) + .margin(2) + TextArea({ + text: '文本布局22222222222222222222' + }) + .width('50%') + .maxLines(1) + .textOverflow(this.textOverflow) + .direction(this.textAreaTwoDirection) + .margin(2) + TextArea({ + text: '文本布局222222222222222' + }) + .width('50%') + .maxLines(1) + .textOverflow(this.textOverflow) + .direction(this.textAreaThrDirection) + .margin(2) + Button('切换文本布局和类型') + .id('changeDirection0090') + .onClick(() => { + this.textInputDirection = Direction.Ltr; + this.textInputTwoDirection = Direction.Rtl; + this.textInputThrDirection = Direction.Auto; + this.textAreaDirection = Direction.Ltr; + this.textAreaTwoDirection = Direction.Rtl; + this.textAreaThrDirection = Direction.Auto; + this.textOverflow = TextOverflow.Clip; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0100.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0100.ets new file mode 100644 index 00000000..881435ff --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0100.ets @@ -0,0 +1,52 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0100 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + + build() { + Column() { + TextInput({ + text: '', + placeholder:'请输入测试信息' + }) + .showPassword(true) + .direction(this.textInputDirection) + Search({ + value: '', + placeholder:'请输入测试信息' + }) + .direction(this.searchDirection) + TextArea({ + text: '', + placeholder:'请输入测试信息' + }) + .direction(this.textAreaDirection) + .margin(2) + Button('切换文本布局和类型') + .id('changeDirection0100') + .onClick(() => { + this.textInputDirection = Direction.Ltr; + this.searchDirection = Direction.Rtl; + this.textAreaDirection = Direction.Auto; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0110.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0110.ets new file mode 100644 index 00000000..1d2290ff --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0110.ets @@ -0,0 +1,93 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0110 { + @State textInputDirection: Direction | undefined = undefined; + @State textInputTwoDirection: Direction | undefined = undefined; + @State textInputThrDirection: Direction | undefined = undefined; + @State textInputForDirection: Direction | undefined = undefined; + @State passWordSrc: Resource = $r('app.media.cat') + build() { + Column() { + TextInput({ + text: '文本布局1111111111' + }) + .passwordIcon({ onIconSrc: this.passWordSrc}) + .cancelButton({ + style: CancelButtonStyle.CONSTANT, + icon: { + size: 45, + src: $r('app.media.icon'), + color: Color.Blue + } + }) + .direction(this.textInputDirection) + .margin(2) + TextInput({ + text: '文本布局111111111111' + }) + .passwordIcon({ onIconSrc: this.passWordSrc}) + .cancelButton({ + style: CancelButtonStyle.CONSTANT, + icon: { + size: 45, + src: $r('app.media.icon'), + color: Color.Blue + } + }) + .direction(this.textInputTwoDirection) + .margin(2) + TextInput({ + text: '文本布局111111111111111' + }) + .passwordIcon({ onIconSrc: this.passWordSrc}) + .cancelButton({ + style: CancelButtonStyle.CONSTANT, + icon: { + size: 45, + src: $r('app.media.icon'), + color: Color.Blue + } + }) + .direction(this.textInputThrDirection) + .margin(2) + TextInput({ + text: '文本布局111111111111111' + }) + .passwordIcon({ onIconSrc: this.passWordSrc}) + .cancelButton({ + style: CancelButtonStyle.CONSTANT, + icon: { + size: 45, + src: $r('app.media.icon'), + color: Color.Blue + } + }) + .direction(this.textInputForDirection) + .margin(2) + Button('切换文本布局和类型') + .id('changeDirection0110') + .onClick(() => { + this.textInputDirection = Direction.Ltr; + this.textInputTwoDirection = Direction.Rtl; + this.textInputThrDirection = Direction.Auto; + this.textInputForDirection = undefined; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0120.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0120.ets new file mode 100644 index 00000000..af2656e1 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0120.ets @@ -0,0 +1,51 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0120 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + @State inputStyle: TextInputStyle | undefined = undefined; + @State textAreaStyle: TextContentStyle | undefined = undefined; + + build() { + Column() { + TextInput({ + text: '文本布局' + }) + .style(this.inputStyle) + .showPassword(true) + .direction(this.textInputDirection) + TextArea({ + text: '文本布局' + }) + .style(this.textAreaStyle) + .direction(this.textAreaDirection) + .margin(2) + Button('切换文本布局和类型') + .id('changeDirection0120') + .onClick(() => { + this.textInputDirection = Direction.Ltr; + this.searchDirection = Direction.Rtl; + this.textAreaDirection = Direction.Auto; + this.inputStyle = TextInputStyle.Inline; + this.textAreaStyle = TextContentStyle.INLINE; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0130.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0130.ets new file mode 100644 index 00000000..3541c825 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0130.ets @@ -0,0 +1,93 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0130 { + @State textInputDirection: Direction | undefined = undefined; + @State textInputTwoDirection: Direction | undefined = undefined; + @State textInputThrDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State textAreaTwoDirection: Direction | undefined = undefined; + @State textAreaThrDirection: Direction | undefined = undefined; + + build() { + Column() { + TextInput({ + text: '文本布局111111111111111' + + '111111111111111111111111111' + + '11111111111111111111' + }) + .width('50%') + .height(40) + .direction(this.textInputDirection) + TextInput({ + text: '文本布局11111111111' + + '111111111111111111' + + '1111111111112' + }) + .width('50%') + .height(40) + .direction(this.textInputTwoDirection) + TextInput({ + text: '文本布局1111111111111' + + '11111111111111111111' + + '11111111' + }) + .width('50%') + .height(40) + .direction(this.textInputThrDirection) + TextArea({ + text: '文本布局222222222222222222222' + + '22222222222222' + + '22222222222222' + + '22222222' + }) + .width('50%') + .height(40) + .direction(this.textAreaDirection) + .margin(2) + TextArea({ + text: '文本布局2222222222' + + '2222222222222222222222222222' + + '22222222222222222222222' + }) + .width('50%') + .height(40) + .direction(this.textAreaTwoDirection) + .margin(2) + TextArea({ + text: '文本布局22222222' + + '22222222222222222222222222222222' + + '22222222222222222222222' + }) + .width('50%') + .height(40) + .direction(this.textAreaThrDirection) + .margin(2) + Button('切换文本布局和类型') + .id('changeDirection0130') + .onClick(() => { + this.textInputDirection = Direction.Ltr; + this.textInputTwoDirection = Direction.Rtl; + this.textInputThrDirection = Direction.Auto; + this.textAreaDirection = Direction.Ltr; + this.textAreaTwoDirection = Direction.Rtl; + this.textAreaThrDirection = Direction.Auto; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0140.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0140.ets new file mode 100644 index 00000000..89039909 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0140.ets @@ -0,0 +1,61 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0140 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + @State text: string = 'ABC priorities Sometimes,a significant change Change,a' + + 'constant and inevitable,every change brings the potentialfor growth and new' + + 'beginnings,But remember,every change brings the potentialfor,ABC priorities' + + 'Sometimes,a significantchange Change,a constant and inevitable,ever' + + build() { + Column() { + TextInput({ + text: this.text + }) + .width('50%') + .height(100) + .direction(this.textInputDirection) + .margin(2) + Search({ + value: this.text + }) + .width('50%') + .height(100) + .direction(this.searchDirection) + .margin(2) + TextArea({ + text: this.text + }) + .id('textAreaMirror0140') + .width('50%') + .height(100) + .direction(this.textAreaDirection) + .margin(2) + Button('切换文本布局') + .id('changeDirection0140') + .onClick(() => { + this.textInputDirection = Direction.Ltr; + this.searchDirection = Direction.Rtl; + this.textAreaDirection = Direction.Auto; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0150.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0150.ets new file mode 100644 index 00000000..0f2b8787 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0150.ets @@ -0,0 +1,66 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0150 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + @State text: string = 'ABCprioritiesSometimes,asignificantchangeChange,a' + + 'constantandinevitable,everychangebringsthepotentialforgrowthandnew' + + 'beginnings,But remember,everychangebringsthepotentialfor,ABCpriorities' + + 'Sometimes,asignificantchangeChange,aconstantandinevitable,ever' + @State textIndent: Dimension | undefined = undefined; + + build() { + Column() { + TextInput({ + text: this.text + }) + .width('80%') + .height(100) + .textIndent(this.textIndent) + .direction(this.textInputDirection) + .margin(2) + Search({ + value: this.text + }) + .width('80%') + .height(100) + .textIndent(this.textIndent) + .direction(this.searchDirection) + .margin(2) + TextArea({ + text: this.text + }) + .id('textAreaMirror0150') + .width('80%') + .height(100) + .textIndent(this.textIndent) + .direction(this.textAreaDirection) + .margin(2) + Button('切换文本布局') + .id('changeDirection0150') + .onClick(() => { + this.textInputDirection = Direction.Ltr; + this.searchDirection = Direction.Rtl; + this.textAreaDirection = Direction.Auto; + this.textIndent = '10vp' + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0160.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0160.ets new file mode 100644 index 00000000..1f322564 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0160.ets @@ -0,0 +1,78 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0160 { + @State searchDirection: Direction | undefined = undefined; + @State searchTwoDirection: Direction | undefined = undefined; + @State searchThrDirection: Direction | undefined = undefined; + + build() { + Column() { + Search({ + value: '文本布局auto' + }) + .searchButton('SEARCH') + .cancelButton({ + style: CancelButtonStyle.CONSTANT, + icon: { + size: 45, + src: $r('app.media.icon'), + color: Color.Blue + } + }) + .direction(this.searchDirection) + .margin(2) + Search({ + value: '文本布局Rtl' + }) + .searchButton('SEARCH') + .cancelButton({ + style: CancelButtonStyle.CONSTANT, + icon: { + size: 45, + src: $r('app.media.icon'), + color: Color.Blue + } + }) + .direction(this.searchTwoDirection) + .margin(2) + Search({ + value: '文本布局Ltr' + }) + .searchButton('SEARCH') + .cancelButton({ + style: CancelButtonStyle.CONSTANT, + icon: { + size: 45, + src: $r('app.media.icon'), + color: Color.Blue + } + }) + .searchButton('SEARCH') + .direction(this.searchThrDirection) + .margin(2) + Button('切换文本布局和类型') + .id('changeDirection0160') + .onClick(() => { + this.searchDirection = Direction.Auto; + this.searchTwoDirection = Direction.Rtl; + this.searchThrDirection = Direction.Ltr; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0170.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0170.ets new file mode 100644 index 00000000..854dc6c3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0170.ets @@ -0,0 +1,72 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0170 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + @State text: string = 'ABCprioritiesSometimes,asignificantchangeChange,a' + + 'constantandinevitable,everychangebringsthepotentialforgrowthandnew' + + 'beginnings,But remember,everychangebringsthepotentialfor,ABCpriorities' + + 'Sometimes,asignificantchangeChange,aconstantandinevitable,ever' + @State textIndent: Dimension | undefined = undefined; + + build() { + Column() { + TextInput({ + text: this.text + }) + .width('80%') + .height(100) + .textIndent(this.textIndent) + .direction(this.textInputDirection) + .margin(2) + .onTextSelectionChange(()=>{ + this.textInputDirection = Direction.Ltr; + }) + Search({ + value: this.text + }) + .width('80%') + .height(100) + .textIndent(this.textIndent) + .direction(this.searchDirection) + .margin(2) + .onTextSelectionChange(()=>{ + this.searchDirection = Direction.Rtl; + }) + TextArea({ + text: this.text + }) + .id('textAreaMirror0170') + .width('80%') + .height(100) + .textIndent(this.textIndent) + .direction(this.textAreaDirection) + .margin(2) + .onTextSelectionChange(()=>{ + this.textAreaDirection = Direction.Auto; + }) + Button('切换文本布局') + .id('changeDirection0170') + .onClick(() => { + this.textIndent = '10vp' + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0180.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0180.ets new file mode 100644 index 00000000..eb4a8011 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0180.ets @@ -0,0 +1,81 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import mediaquery from '@ohos.mediaquery'; +import window from '@ohos.window'; +import common from '@ohos.app.ability.common'; +let portraitFunc = null; + +@Entry +@Component +struct UiComponentTextMirror0180 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + listener = mediaquery.matchMediaSync('(orientation: 横屏)'); + onPortrait() { + } + + aboutToAppear() { + // 绑定当前应用实例 + portraitFunc = this.onPortrait.bind(this); + // 绑定回调函数 + this.listener.on('change', portraitFunc); + } + + // 改变设备横竖屏状态函数 + private changeOrientation(isLandscape: boolean) { + // 获取UIAbility实例的上下文信息 + let context = getContext(this) as common.UIAbilityContext; + // 调用该接口手动改变设备横竖屏状态 + window.getLastWindow(context).then((lastWindow) => { + lastWindow.setPreferredOrientation(isLandscape ? window.Orientation.LANDSCAPE : window.Orientation.PORTRAIT) + }); + } + build() { + Column() { + TextInput({ + text: '', + placeholder:'请输入测试信息' + }) + .showPassword(true) + .direction(this.textInputDirection) + Search({ + value: '', + placeholder:'请输入测试信息' + }) + .direction(this.searchDirection) + TextArea({ + text: '', + placeholder:'请输入测试信息' + }) + .direction(this.textAreaDirection) + .margin(2) + Button('切换横竖屏') + .id('changeScreenBt0180') + .onClick(() => { + this.changeOrientation(true); + }) + Button('切换文本布局和类型') + .id('changeDirection0180') + .onClick(() => { + this.textInputDirection = Direction.Ltr; + this.searchDirection = Direction.Rtl; + this.textAreaDirection = Direction.Auto; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%').height('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0190.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0190.ets new file mode 100644 index 00000000..a340ed0a --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0190.ets @@ -0,0 +1,51 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextMirror0190 { + @State textInputDirection: Direction | undefined = undefined; + @State textAreaDirection: Direction | undefined = undefined; + @State searchDirection: Direction | undefined = undefined; + build() { + Column() { + TextInput({ + text: '', + placeholder:'请输入测试信息' + }) + .showPassword(true) + .direction(this.textInputDirection) + Search({ + value: '', + placeholder:'请输入测试信息' + }) + .direction(this.searchDirection) + TextArea({ + text: '', + placeholder:'请输入测试信息' + }) + .direction(this.textAreaDirection) + .margin(2) + Button('切换文本布局和类型') + .id('changeDirection0190') + .onClick(() => { + this.textInputDirection = Direction.Ltr; + this.searchDirection = Direction.Rtl; + this.textAreaDirection = Direction.Auto; + }) + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%').height('100%') + } +} + diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0200.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0200.ets new file mode 100644 index 00000000..737dd2a0 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextMirror/UiComponentTextMirror0200.ets @@ -0,0 +1,75 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +@Entry +@Component +struct UiComponentTextMirror0200 { + @State msg: string = + "OpenHarmony是由开放原子开源基金会(OpenAtom Foundation)孵化及运营的开源项目, 目标是面向全场景、全连" + + "接、全智能时代、基于开源的方式,搭建一个智能终端设备操作系统的框架和平台" + @State txt: string = 'Text:' + this.msg + @State taTxt: string = 'TextArea:' + this.msg + @State tiTxt: string = 'TextInput:' + this.msg + @State changeValue: string = 'search:' + this.msg + @State submitValue: string = '' + searchController: SearchController = new SearchController(); + textAreaController: TextAreaController = new TextAreaController() + textInputController: TextInputController = new TextInputController() + + build() { + Column() { + TextArea({ + text: this.taTxt, + placeholder: 'The text area can hold an unlimited amount of text. input your word...', + controller: this.textAreaController + }) + .id('textMirror0200_txArea') + .width('50%') + .margin(10) + .height(100) + .fontSize(16) + .fontColor('#182431') + .backgroundColor('#FFFFFF') + + TextInput({ + text: this.tiTxt, + controller: this.textInputController + }) + .id('textMirror0200_txInput') + .margin(30) + .fontColor(Color.Blue) + .fontSize(20) + .width('70%') + .height('20%') + + Search({ + value: this.changeValue, + placeholder: 'Type to search...', + controller: this.searchController + }) + .id('textMirror0200_search') + .searchButton('SEARCH') + .width('100%') + .height(50) + .backgroundColor('#F5F5F5') + .placeholderColor(Color.Grey) + .placeholderFont({ size: 14, weight: 400 }) + .textFont({ size: 14, weight: 400 }) + .margin(20) + } + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0020.ets new file mode 100644 index 00000000..4d4bd350 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0020.ets @@ -0,0 +1,27 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0020 { + @State text: string = 'aaaa'; + + build() { + Column() { + TextInput({ text: this.text}) + .id('textInputTextRefactorAdjustment0020') + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0050.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0050.ets new file mode 100644 index 00000000..9ddf92d9 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0050.ets @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0050 { + @State text: string = ''; + + build() { + Column() { + TextInput({ text: this.text}) + .id('textInputTextRefactorAdjustment0050') + .type(InputType.Password) + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0110.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0110.ets new file mode 100644 index 00000000..2dafc3f3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0110.ets @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0110 { + @State insertValue: string = ""; + @State insertOffset: number = 0; + @State text: string = 'abcda'; + + build() { + Column() { + TextInput({ text: this.text}) + .id('textInputTextRefactorAdjustment0110') + .margin(2) + .width('50%') + TextArea() + .id('textAreaTextRefactorAdjustment0110') + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0120.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0120.ets new file mode 100644 index 00000000..a5b3161b --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0120.ets @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0120 { + @State text: string = ''; + + build() { + Column() { + TextInput({ text: this.text}) + .id('textInputTextRefactorAdjustment0120') + .type(InputType.Email) + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0130.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0130.ets new file mode 100644 index 00000000..936c1bb6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0130.ets @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0130 { + @State text: string = ''; + + build() { + Column() { + TextInput({ text: this.text }) + .id('textInputTextRefactorAdjustment0130') + .margin(2) + .width('50%') + TextArea({ text: this.text }) + .id('TextAreaTextRefactorAdjustment0130') + .margin(2) + .width('50%') + Search({ value: this.text }) + .id('SearchTextRefactorAdjustment0130') + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0140.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0140.ets new file mode 100644 index 00000000..d864387d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0140.ets @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0140 { + @State text: string = ''; + + build() { + Column() { + TextInput({ text: this.text}) + .id('textInputTextRefactorAdjustment0140') + .type(InputType.Password) + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0160.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0160.ets new file mode 100644 index 00000000..4061643a --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0160.ets @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0160 { + @State text: string = ''; + + build() { + Column() { + TextInput({ text: this.text}) + .id('textInputTextRefactorAdjustment0160') + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0170.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0170.ets new file mode 100644 index 00000000..884ab984 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0170.ets @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0170 { + @State text: string = ''; + controller: TextInputController = new TextInputController() + + build() { + Column() { + TextInput({ + text: this.text, + controller: this.controller + }) + .id('textInputTextRefactorAdjustment0170') + .margin(2) + .width('50%') + .onClick(() => { + this.controller.caretPosition(5) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0190.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0190.ets new file mode 100644 index 00000000..fbe13dde --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0190.ets @@ -0,0 +1,37 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0190 { + @State text: string = ''; + controller: TextInputController = new TextInputController(); + + build() { + Column() { + TextInput({ + text: this.text, + controller: this.controller + }) + .id('textInputTextRefactorAdjustment0190') + .margin(2) + .width('50%') + Button('textInput失去焦点') + .id('ButtonTextRefactorAdjustment0190') + .onClick(() => { + this.controller.stopEditing() + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0230.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0230.ets new file mode 100644 index 00000000..f9517295 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0230.ets @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0230 { + @State text: string = ''; + + build() { + Column() { + TextInput({ + text: this.text + }) + .id('TextInputTextRefactorAdjustment0230') + .margin(2) + .width('50%') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0260.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0260.ets new file mode 100644 index 00000000..cccecda7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0260.ets @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0260 { + @State text: string = ''; + controller: TextInputController = new TextInputController(); + + build() { + Column() { + TextInput({ + text: this.text, + controller: this.controller + }) + .id('TextInputTextRefactorAdjustment0260') + .margin(2) + .width('50%') + .onClick(() => { + this.controller.setTextSelection(3, 3) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0270.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0270.ets new file mode 100644 index 00000000..84909cf7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0270.ets @@ -0,0 +1,38 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0270 { + @State text: string = ''; + controller: TextAreaController = new TextAreaController(); + @State length: number = 5; + + build() { + Column() { + TextArea({ + text: this.text, + controller: this.controller + }) + .id('TextAreaTextRefactorAdjustment0270') + .margin(2) + .width('50%') + .maxLength(this.length) + .showCounter(true) + .onChange(() => { + this.length = 20; + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0280.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0280.ets new file mode 100644 index 00000000..0933f994 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0280.ets @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0280 { + @State text: string = 'aaaaaaaaaaaaaaaaaaaaaaaa'; + build() { + Column() { + TextArea({ + text: this.text, + }) + .id('TextAreaTextRefactorAdjustment0280') + .margin(2) + .width('50%') + TextInput({ + }) + .width('auto') + .id('TextInputTextRefactorAdjustment0280') + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0290.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0290.ets new file mode 100644 index 00000000..2d52b791 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0290.ets @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0290 { + @State text: string = 'aaaaaaaaaaaaaaaaaaaaaaaa'; + build() { + Column() { + TextArea({ + text: this.text, + }) + .id('TextAreaTextRefactorAdjustment0290') + .margin(2) + .width('50%') + TextInput({ + }) + .width('auto') + .id('TextInputTextRefactorAdjustment0290') + .margin(2) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0300.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0300.ets new file mode 100644 index 00000000..5d236568 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0300.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0300 { + @State text: string = 'ABC priorities Sometimes,a significant change Change,a' + + 'constant and inevitable,every change brings the potentialfor growth and new' + + 'beginnings,But remember,every change brings the potentialfor,ABC priorities' + + 'Sometimes,a significantchange Change,a constant and inevitable,ever' + build() { + Column() { + TextArea({ + text: this.text, + }) + .id('TextAreaTextRefactorAdjustment0300') + .margin(2) + .width('50%') + .height(100) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0310.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0310.ets new file mode 100644 index 00000000..feb20b1f --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0310.ets @@ -0,0 +1,44 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0310 { + @State text: string = 'ABC priorities Sometimes,a significant change Change,ac' + + 'onstant and inevitable,every change brings the potentialfor growth and newbe' + + 'ginnings,But remember,every change brings the potentialfor,ABC prioritiesSom' + + 'etimes,a significantchange Change,a constant and inevitable,everABC priorities Som' + + 'etimes,a significant change Change,aconstant and inevitable,every change brin' + + 'gs the potentialfor growth and newbeginnings,But remember,every change brings the po' + + 'tentialfor,ABC prioritiesSometimes,a significantchange Change,a constant and inev' + + 'itable,everABC priorities Sometimes,a significant change Change,aconstant and inevit' + + 'able,every change brings the potentialfor growth and newbeginnings,But remember,eve' + + 'ry change brings the potentialfor,ABC prioritiesSometimes,a significantchange Chang' + + 'e,a constant and inevitable,everABC priorities Sometimes,a significant change Chan' + + 'ge,aconstant and inevitable,every change brings the potentialfor growth and newb' + + 'eginnings,But remember,every change brings the potentialfor,ABC prioritiesSome' + + 'times,a significantchange Change,a constant and inevitable,ever' + + build() { + Column() { + TextArea({ + text: this.text + }) + .id('TextAreaTextRefactorAdjustment0310') + .margin(2) + .width('50%') + .height(100) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0320.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0320.ets new file mode 100644 index 00000000..068dc1f1 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0320.ets @@ -0,0 +1,44 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0320 { + @State text: string = 'ABC priorities' + build() { + Column() { + TextArea({ + text: this.text, + }) + .id('TextAreaTextRefactorAdjustment0320') + .margin(2) + .width('50%') + .height(100) + TextInput({ + text: this.text, + }) + .id('TextInputTextRefactorAdjustment0320') + .margin(2) + .width('50%') + .height(100) + Search({ + value: this.text, + }) + .id('SearchTextRefactorAdjustment0320') + .margin(2) + .width('50%') + .height(100) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0330.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0330.ets new file mode 100644 index 00000000..5683bda9 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0330.ets @@ -0,0 +1,37 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0330 { + controller: TextInputController = new TextInputController(); + + build() { + Column() { + TextInput({ + controller: this.controller + }) + .id('TextInputTextRefactorAdjustment0330') + .margin(2) + .width('50%') + .height(100) + Button('选中文本textselection start>end') + .id('ButtonTextRefactorAdjustment0330') + .margin(2) + .onClick(() => { + this.controller.setTextSelection(6, 3) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0340.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0340.ets new file mode 100644 index 00000000..69d9885d --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0340.ets @@ -0,0 +1,37 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0340 { + controller: TextInputController = new TextInputController(); + + build() { + Column() { + TextInput({ + controller: this.controller + }) + .id('TextAreaTextRefactorAdjustment0340') + .margin(2) + .width('50%') + .height(100) + Button('选中文本') + .id('ButtonTextRefactorAdjustment0340') + .margin(2) + .onClick(() => { + this.controller.setTextSelection(5, 10) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0350.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0350.ets new file mode 100644 index 00000000..d82fcca9 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0350.ets @@ -0,0 +1,37 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0350 { + controller: TextInputController = new TextInputController(); + + build() { + Column() { + TextInput({ + controller: this.controller + }) + .id('TextInputTextRefactorAdjustment0350') + .margin(2) + .width('50%') + .height(100) + Button('选中文本') + .id('ButtonTextRefactorAdjustment0350') + .margin(2) + .onClick(() => { + this.controller.setTextSelection(1, 4) + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0360.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0360.ets new file mode 100644 index 00000000..537983da --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0360.ets @@ -0,0 +1,44 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0360 { + @State text: string = 'ABC priorities' + build() { + Column() { + TextArea({ + text: this.text, + }) + .id('TextAreaTextRefactorAdjustment0360') + .margin(2) + .width('50%') + .height(100) + TextInput({ + text: this.text, + }) + .id('TextInputTextRefactorAdjustment0360') + .margin(2) + .width('50%') + .height(100) + Search({ + value: this.text, + }) + .id('SearchTextRefactorAdjustment0360') + .margin(2) + .width('50%') + .height(100) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0370.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0370.ets new file mode 100644 index 00000000..be12306e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0370.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0370 { + @State text: string = 'ABC priorities Sometimes,a significant change Change,a' + + 'constant and inevitable,every change brings the potentialfor growth and new' + + 'beginnings,But remember,every change brings the potentialfor,ABC priorities' + + 'Sometimes,a significantchange Change,a constant and inevitable,ever' + build() { + Column() { + TextArea({ + text: this.text, + }) + .id('TextAreaTextRefactorAdjustment0370') + .margin(2) + .width('50%') + .height(100) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0380.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0380.ets new file mode 100644 index 00000000..c8caf4b7 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0380.ets @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0380 { + @State text: string = 'ABC priorities Sometimes,a significant change Change,a' + + 'constant and inevitable,every change brings the potentialfor growth and new' + + 'beginnings,But remember,every change brings the potentialfor,ABC priorities' + + 'Sometimes,a significantchange Change,a constant and inevitable,ever' + build() { + Column() { + TextArea({ + text: this.text, + }) + .id('TextAreaTextRefactorAdjustment0380') + .margin(2) + .width('50%') + .height(100) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0420.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0420.ets new file mode 100644 index 00000000..b9cbd5c2 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0420.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0420 { + @State text: string = '' + build() { + Column() { + TextArea({ + text: this.text, + placeholder:'请输入...' + }) + .id('TextAreaTextRefactorAdjustment0420') + .margin(2) + .width('50%') + .height(100) + .fontSize('') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0440.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0440.ets new file mode 100644 index 00000000..119eb3b8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0440.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0440 { + @State text: string = 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' + build() { + Column() { + TextArea({ + text: this.text, + }) + .id('TextAreaTextRefactorAdjustment0440') + .margin(2) + .width('50%') + .height(50) + .fontSize('') + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0450.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0450.ets new file mode 100644 index 00000000..226d8341 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0450.ets @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextRefactorAdjustment0450 { + @State text: string = 'aaaaaaaaaaaaa' + build() { + Column() { + TextArea({ + text: this.text, + }) + .id('TextAreaTextRefactorAdjustment0450') + .margin(2) + .width('50%') + .height(50) + .showCounter(true) + .maxLength(20) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0010.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0010.ets new file mode 100644 index 00000000..fd4f6ad0 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0010.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextSearchEnterKeyType0010 { + @State submitValue: string = '' + build() { + Column() { + Text('onSubmit:' + this.submitValue).fontSize(18).margin(15) + Search() + .id('SearchTextSearchEnterKeyType0010') + .margin(2) + .enterKeyType(EnterKeyType.Go) + .onSubmit((value: string) => { + this.submitValue = value + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0020.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0020.ets new file mode 100644 index 00000000..d2b120c6 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0020.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextSearchEnterKeyType0020 { + @State submitValue: string = '' + build() { + Column() { + Text('onSubmit:' + this.submitValue).fontSize(18).margin(15) + Search() + .id('SearchTextSearchEnterKeyType0020') + .margin(2) + .enterKeyType(EnterKeyType.Search) + .onSubmit((value: string) => { + this.submitValue = value + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0030.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0030.ets new file mode 100644 index 00000000..dd9440d8 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0030.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextSearchEnterKeyType0030 { + @State submitValue: string = '' + build() { + Column() { + Text('onSubmit:' + this.submitValue).fontSize(18).margin(15) + Search() + .id('SearchTextSearchEnterKeyType0030') + .margin(2) + .enterKeyType(EnterKeyType.Send) + .onSubmit((value: string) => { + this.submitValue = value + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0040.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0040.ets new file mode 100644 index 00000000..dfb814ba --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0040.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextSearchEnterKeyType0040 { + @State submitValue: string = '' + build() { + Column() { + Text('onSubmit:' + this.submitValue).fontSize(18).margin(15) + Search() + .id('SearchTextSearchEnterKeyType0040') + .margin(2) + .enterKeyType(EnterKeyType.Next) + .onSubmit((value: string) => { + this.submitValue = value + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0050.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0050.ets new file mode 100644 index 00000000..7c6f59cb --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0050.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextSearchEnterKeyType0050 { + @State submitValue: string = '' + build() { + Column() { + Text('onSubmit:' + this.submitValue).fontSize(18).margin(15) + Search() + .id('SearchTextSearchEnterKeyType0050') + .margin(2) + .enterKeyType(EnterKeyType.Done) + .onSubmit((value: string) => { + this.submitValue = value + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0060.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0060.ets new file mode 100644 index 00000000..4281a4fa --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0060.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextSearchEnterKeyType0060 { + @State submitValue: string = '' + build() { + Column() { + Text('onSubmit:' + this.submitValue).fontSize(18).margin(15) + Search() + .id('SearchTextSearchEnterKeyType0060') + .margin(2) + .enterKeyType(EnterKeyType.PREVIOUS) + .onSubmit((value: string) => { + this.submitValue = value + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0070.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0070.ets new file mode 100644 index 00000000..37e5a094 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0070.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextSearchEnterKeyType0070 { + @State submitValue: string = '' + build() { + Column() { + Text('onSubmit:' + this.submitValue).fontSize(18).margin(15) + Search() + .id('SearchTextSearchEnterKeyType0070') + .margin(2) + .enterKeyType(EnterKeyType.NEW_LINE) + .onSubmit((value: string) => { + this.submitValue = value + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0080.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0080.ets new file mode 100644 index 00000000..b04982c3 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0080.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextSearchEnterKeyType0080 { + @State submitValue: string = '' + build() { + Column() { + Text('onSubmit:' + this.submitValue).fontSize(18).margin(15) + Search() + .id('SearchTextSearchEnterKeyType0080') + .margin(2) + .enterKeyType(undefined) + .onSubmit((value: string) => { + this.submitValue = value + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0090.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0090.ets new file mode 100644 index 00000000..44c1a10e --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0090.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextSearchEnterKeyType0090 { + @State submitValue: string = '' + build() { + Column() { + Text('onSubmit:' + this.submitValue).fontSize(18).margin(15) + Search() + .id('SearchTextSearchEnterKeyType0090') + .margin(2) + .enterKeyType(4) + .onSubmit((value: string) => { + this.submitValue = value + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0100.ets b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0100.ets new file mode 100644 index 00000000..efe33a65 --- /dev/null +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0100.ets @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2024 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the 'License') + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an 'AS IS' BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +@Entry +@Component +struct UiComponentTextSearchEnterKeyType0100 { + @State submitValue: string = '' + build() { + Column() { + Text('onSubmit:' + this.submitValue).fontSize(18).margin(15) + Search() + .id('SearchTextSearchEnterKeyType0100') + .margin(2) + .enterKeyType(EnterKeyType.Search) + .onSubmit((value: string) => { + this.submitValue = value + }) + }.alignItems(HorizontalAlign.Center).width('100%') + } +} diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/resources/containerspan_click_error.png b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/resources/containerspan_click_error.png new file mode 100644 index 0000000000000000000000000000000000000000..476223a2cbaa029e0ccc67660eb768effb766501 GIT binary patch literal 15905 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 literal 0 HcmV?d00001 diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/resources/containerspan_width_error.png b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/resources/containerspan_width_error.png new file mode 100644 index 0000000000000000000000000000000000000000..eaae1996c7bcdeafd8a6287b9d5d44cfda56a934 GIT binary patch literal 35731 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 I-00i?1;{rY6951J literal 0 HcmV?d00001 diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/resources/span_null_param_error.png b/function/ui_compare_rh/uicompare/entry/src/ohosTest/ets/testability/resources/span_null_param_error.png new file mode 100644 index 0000000000000000000000000000000000000000..846adf54057902753c7ad575ea11769db6c5eec8 GIT binary patch literal 16861 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 BMD+jw literal 0 HcmV?d00001 diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/module.json5 b/function/ui_compare_rh/uicompare/entry/src/ohosTest/module.json5 index e58bd507..4eafa4d2 100644 --- a/function/ui_compare_rh/uicompare/entry/src/ohosTest/module.json5 +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/module.json5 @@ -12,12 +12,33 @@ "installationFree": false, "pages": "$profile:test_pages", "requestPermissions": [ + { + "name": "ohos.permission.SYSTEM_FLOAT_WINDOW", + "usedScene": { + "abilities": [ + "EntryAbility" + ], + "when": "inuse" + } + }, + { + "name": "ohos.permission.GRANT_SENSITIVE_PERMISSIONS" + }, { "name": "ohos.permission.WRITE_MEDIA" }, + { + "name": "ohos.permission.INTERNET" + }, { "name": "ohos.permission.READ_MEDIA" }, + { + "name": "ohos.permission.CAPTURE_SCREEN" + }, + { + "name": "ohos.permission.ACCESS_SCREEN_LOCK_INNER" + }, { "name":"ohos.permission.UPDATE_CONFIGURATION" }, @@ -26,6 +47,9 @@ }, { "name":"ohos.permission.INTERNET" + }, + { + "name": "ohos.permission.READ_PASTEBOARD" } ], "abilities": [ diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/resources/base/element/string.json b/function/ui_compare_rh/uicompare/entry/src/ohosTest/resources/base/element/string.json index ce65c09b..2b1068bb 100644 --- a/function/ui_compare_rh/uicompare/entry/src/ohosTest/resources/base/element/string.json +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/resources/base/element/string.json @@ -243,6 +243,10 @@ { "name": "20string", "value": "20" + }, + { + "name": "search_width", + "value": "30fp" } ] } \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/entry/src/ohosTest/resources/base/profile/test_pages.json b/function/ui_compare_rh/uicompare/entry/src/ohosTest/resources/base/profile/test_pages.json index 5cc05ce9..b0c2b987 100644 --- a/function/ui_compare_rh/uicompare/entry/src/ohosTest/resources/base/profile/test_pages.json +++ b/function/ui_compare_rh/uicompare/entry/src/ohosTest/resources/base/profile/test_pages.json @@ -1801,6 +1801,578 @@ "testability/pages/UIComponentPopupBoxFullDialogInterface/UIComponentPopupBoxFullDialogInterface007", "testability/pages/UIComponentPopupBoxFullDialogInterface/UIComponentPopupBoxFullDialogInterface008", "testability/pages/UIComponentPopupBoxFullDialogInterface/UIComponentPopupBoxFullDialogInterface009", - "testability/pages/UIComponentPopupBoxFullDialogInterface/UIComponentPopupBoxFullDialogInterface0010" + "testability/pages/UIComponentPopupBoxFullDialogInterface/UIComponentPopupBoxFullDialogInterface0010", + + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize008", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize009", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize010", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize011", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize012", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize013", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize014", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize015", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize016", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize017", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize018", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize019", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize020", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize021", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize022", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize023", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize024", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize025", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize026", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize027", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize028", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize029", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize030", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize031", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize032", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize033", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize034", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize035", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize036", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize037", + "testability/pages/UiComponentTextCommonTextMinFontSize/UiComponentTextCommonTextMinFontSize038", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0010", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0020", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0030", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0040", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0050", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0060", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0070", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0080", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0090", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0100", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0110", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0120", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0130", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0140", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0150", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0160", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0170", + "testability/pages/UiComponentTextCommonTextImprove/UiComponentTextCommonTextImprove0180", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0210", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0220", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0320", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0330", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0340", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0350", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0360", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0730", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0740", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0750", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0760", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0770", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0780", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0790", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0800", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0810", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0820", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0830", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle0840", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1150", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1160", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1170", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1450", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1460", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1470", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1850", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1860", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1870", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1880", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1890", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1910", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1920", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1930", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle1940", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2040", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2050", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2060", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2070", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2120", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2130", + "testability/pages/UiComponentTextCommonTextStyle/UiComponentTextCommonTextStyle2140", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0010", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0020", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0030", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0040", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0050", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0060", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0070", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0080", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0090", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0100", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0110", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0120", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0130", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0140", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0150", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0160", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0170", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0180", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0190", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0200", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0210", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0220", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0230", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0240", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0250", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0260", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0270", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0280", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0290", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0300", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0310", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0320", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0330", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0360", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0380", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0390", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0400", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0410", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0420", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0430", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0440", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0450", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0460", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0480", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0490", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0500", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0510", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0520", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0530", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0540", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0550", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0560", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0570", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0580", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0600", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0610", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0620", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0630", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0640", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0650", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0660", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0670", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0680", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0690", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0710", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0720", + "testability/pages/UiComponentTextDecoration/UiComponentTextDecoration0470", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0010", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0040", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0050", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0060", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0070", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0080", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0090", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0100", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0110", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0120", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0130", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0140", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0150", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0160", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0170", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0180", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0190", + "testability/pages/UiComponentTextMirror/UiComponentTextMirror0200", + "testability/pages/UiComponentTextEditMeauOptions/UiComponentTextEditMeauOptions0030", + "testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0010", + "testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0020", + "testability/pages/UiComponentTextInputDeleteCallBack/UiComponentTextInputDeleteCallBack0030", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0020", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0050", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0110", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0120", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0130", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0140", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0160", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0170", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0190", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0230", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0260", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0270", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0280", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0290", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0300", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0310", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0320", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0330", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0340", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0350", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0360", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0380", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0420", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0440", + "testability/pages/UiComponentTextRefactorAdjustment/UiComponentTextRefactorAdjustment0450", + "testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0100", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0010", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0020", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0030", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0040", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0050", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0060", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0070", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0080", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0090", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0100", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0110", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0120", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0140", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0150", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0160", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0180", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0200", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0210", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0220", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0230", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0240", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0250", + "testability/pages/UiComponentTextCommonEmoji/UiComponentTextCommonEmoji0270", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0010", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0020", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0030", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0040", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0050", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0060", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0070", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0080", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0090", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0100", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0110", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0120", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0130", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0140", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0150", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0160", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0170", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0180", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0190", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0200", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0210", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0220", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0230", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0240", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0250", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0260", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0270", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0280", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0290", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0300", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0310", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0320", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0330", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0340", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0350", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0360", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0370", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0380", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0390", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0400", + "testability/pages/UiComponentTextCommonQuanXuanCaiDan/UiComponentTextCommonQuanXuanCaiDan0410", + + + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface001", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface002", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface003", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface004", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface005", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface006", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface007", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface008", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface009", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0010", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0011", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0012", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0013", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0014", + + "testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface001", + "testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface002", + "testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface003", + "testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface004", + "testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface005", + "testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface006", + "testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface007", + "testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface008", + "testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface009", + "testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0010", + "testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0011", + "testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0012", + "testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0013", + "testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0014", + "testability/pages/UIComponentTextInputDeleteCallbackInterface/UIComponentTextInputDeleteCallbackInterface0015", + + "testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface001", + "testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface002", + "testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface003", + "testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface004", + "testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface005", + "testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface006", + "testability/pages/UIComponentTextRefactorAdjustMentInterface/UIComponentTextRefactorAdjustMentInterface007", + + "testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface001", + "testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface002", + "testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface003", + "testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface004", + "testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface005", + "testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface006", + "testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface007", + "testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface008", + "testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface009", + "testability/pages/UIComponentTextAffineTransformationInterface/UIComponentTextAffineTransformationInterface0010", + "testability/pages/UIComponentReverseAnalysisInterface/UIComponentReverseAnalysisInterface002", + "testability/pages/UIComponentReverseAnalysisInterface/UIComponentReverseAnalysisInterface001", + + "testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface001", + "testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface002", + "testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface003", + "testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface004", + "testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface005", + "testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface006", + "testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface007", + "testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface008", + "testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface009", + "testability/pages/UIComponentTextCommonHandleInterface/UIComponentTextCommonHandleInterface0010", + + "testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface001", + "testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface002", + "testability/pages/UIComponentTextSearchActionInterface/UIComponentTextSearchActionInterface003", + "testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0020", + "testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0110", + "testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0120", + "testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0160", + "testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0430", + "testability/pages/UIComponentTextSelectionAction/UIComponentTextSelectionAction0630", + "testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0010", + "testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0190", + "testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0200", + "testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_1", + "testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_2", + "testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0230_3", + "testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0240_1", + "testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0240_2", + "testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0250", + "testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0260", + "testability/pages/UIComponentTextCommonSelectionState/UIComponentTextCommonSelectionState0210", + "testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0040", + "testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0050", + "testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0060", + "testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0090", + "testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0110", + "testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0150", + "testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0160", + "testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0170", + "testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0180", + "testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0190", + "testability/pages/UIComponentTextEditMenuOptions/UIComponentTextEditMenuOptions0260", + + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0010", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0020", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0030", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0040", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0050", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0060", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0070", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0080", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0090", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0100", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0110", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0120", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0130", + + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0160", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0170", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0200", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0210", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0220", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0230", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0240", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0250", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0260", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0270", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0280", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0290", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0300", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0310", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0320", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0330", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0340", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0370", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0380", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0410", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0420", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0430", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0440", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0450", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0460", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0470", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0480", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0490", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0500", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0510", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0520", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0530", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0540", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0550", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0580", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0590", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0600", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0610", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0620", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0650", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0660", + + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0010", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0020", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0030", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0040", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0050", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0060", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0070", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0080", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0090", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0100", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0110", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0120", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0130", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0140", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0150", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0160", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0170", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0180", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0190", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0200", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0210", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0220", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0230", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0250", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0260", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0270", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0280", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0290", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0300", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0310", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0320", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0330", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0340", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0350", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0360", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0370", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0380", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0390", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0400", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0410", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0420", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0430", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0440", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0450", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0460", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0470", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0480", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0490", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0500", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0510", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0520", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0530", + "testability/pages/UiComponentTextCommonMenuAvoid/UiComponentTextCommonMenuAvoid0540", + + "testability/pages/UiComponentTextCommonApplicationLevelFonts/UiComponentTextCommonApplicationLevelFonts0010", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0150", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0360", + "testability/pages/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance/UiComponentTextCommonCustomKeyBoardIsSupportAvoidance0570", + "testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0010", + "testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0060", + "testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0040", + "testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0030", + "testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0090", + "testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0050", + "testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0070", + "testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0020", + "testability/pages/UiComponentTextSearchEnterKeyType/UiComponentTextSearchEnterKeyType0080", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0530", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0020", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0030", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0040", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0370", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0390", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0400", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0410", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0420", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface0430", + "testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol020", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol030", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol040", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol050", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol060", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol070", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Symbol080", + "testability/pages/UIComponentTextSearchInterface/UIComponentTextSearchInterface_Interface200", + "testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface020", + "testability/pages/UIComponentTextSelectionInterface/UIComponentTextSelectionInterface040", + + "testability/pages/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement0210", + "testability/pages/UIComponentSettextselectionReplacement/UIComponentSettextselectionReplacement0220", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0050", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0060", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0070", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0080", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0090", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0100", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0110", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0120", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0130", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0140", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0150", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0160", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0170", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0180", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0190", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0200", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0210", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0220", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0370", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0380", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0230", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0240", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0250", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0260", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0270", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0280", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0290", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0300", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0310", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0320", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0330", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0340", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0350", + "testability/pages/UIComponentTextCopyAttributeReplacement/UIComponentTextCopyAttributeReplacement0360", + + "testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0340", + "testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0630", + "testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement0730", + "testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentEditAbleTextThreeReplacement1020", + "testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentCommonAttrCom0080", + "testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentCustomSpanInvailDate0110", + "testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize042", + "testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize043", + "testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize044", + "testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize045", + "testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize046", + "testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize047", + "testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextMinFontSize048", + "testability/pages/UIComponentEditAbleTextThreeReplacement/UIComponentTextCopyAttribute0010", + "testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0010", + "testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0020", + "testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0030", + "testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0040", + "testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0050", + "testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0060", + "testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0070", + "testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0080", + "testability/pages/UiComponentTextInputReplacement/UiComponentTextInputReplacement0090" ] } diff --git a/function/ui_compare_rh/uicompare/hvigor/hvigor-wrapper.js b/function/ui_compare_rh/uicompare/hvigor/hvigor-wrapper.js new file mode 100644 index 00000000..372eae8e --- /dev/null +++ b/function/ui_compare_rh/uicompare/hvigor/hvigor-wrapper.js @@ -0,0 +1 @@ +"use strict";var u=require("path"),D=require("os"),e=require("fs"),t=require("crypto"),r=require("child_process"),n="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},i={},C={},F=n&&n.__importDefault||function(u){return u&&u.__esModule?u:{default:u}};Object.defineProperty(C,"__esModule",{value:!0}),C.maxPathLength=C.isMac=C.isLinux=C.isWindows=void 0;const E=F(D),A="Windows_NT",o="Darwin";function a(){return E.default.type()===A}function c(){return E.default.type()===o}C.isWindows=a,C.isLinux=function(){return"Linux"===E.default.type()},C.isMac=c,C.maxPathLength=function(){return c()?1016:a()?259:4095},function(e){var t=n&&n.__createBinding||(Object.create?function(u,D,e,t){void 0===t&&(t=e);var r=Object.getOwnPropertyDescriptor(D,e);r&&!("get"in r?!D.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return D[e]}}),Object.defineProperty(u,t,r)}:function(u,D,e,t){void 0===t&&(t=e),u[t]=D[e]}),r=n&&n.__setModuleDefault||(Object.create?function(u,D){Object.defineProperty(u,"default",{enumerable:!0,value:D})}:function(u,D){u.default=D}),i=n&&n.__importStar||function(u){if(u&&u.__esModule)return u;var D={};if(null!=u)for(var e in u)"default"!==e&&Object.prototype.hasOwnProperty.call(u,e)&&t(D,u,e);return r(D,u),D};Object.defineProperty(e,"__esModule",{value:!0}),e.WORK_SPACE=e.HVIGOR_PROJECT_WRAPPER_HOME=e.HVIGOR_PROJECT_ROOT_DIR=e.HVIGOR_PROJECT_CACHES_HOME=e.HVIGOR_PNPM_STORE_PATH=e.HVIGOR_WRAPPER_PNPM_SCRIPT_PATH=e.PROJECT_CACHES=e.HVIGOR_WRAPPER_TOOLS_HOME=e.HVIGOR_USER_HOME=e.DEFAULT_PACKAGE_JSON=e.DEFAULT_HVIGOR_CONFIG_JSON_FILE_NAME=e.PNPM=e.HVIGOR=e.NPM_TOOL=e.PNPM_TOOL=e.HVIGOR_ENGINE_PACKAGE_NAME=void 0;const F=i(D),E=i(u),A=C;e.HVIGOR_ENGINE_PACKAGE_NAME="@ohos/hvigor",e.PNPM_TOOL=(0,A.isWindows)()?"pnpm.cmd":"pnpm",e.NPM_TOOL=(0,A.isWindows)()?"npm.cmd":"npm",e.HVIGOR="hvigor",e.PNPM="pnpm",e.DEFAULT_HVIGOR_CONFIG_JSON_FILE_NAME="hvigor-config.json5",e.DEFAULT_PACKAGE_JSON="package.json",e.HVIGOR_USER_HOME=E.resolve(F.homedir(),".hvigor"),e.HVIGOR_WRAPPER_TOOLS_HOME=E.resolve(e.HVIGOR_USER_HOME,"wrapper","tools"),e.PROJECT_CACHES="project_caches",e.HVIGOR_WRAPPER_PNPM_SCRIPT_PATH=E.resolve(e.HVIGOR_WRAPPER_TOOLS_HOME,"node_modules",".bin",e.PNPM_TOOL),e.HVIGOR_PNPM_STORE_PATH=E.resolve(e.HVIGOR_USER_HOME,"caches"),e.HVIGOR_PROJECT_CACHES_HOME=E.resolve(e.HVIGOR_USER_HOME,e.PROJECT_CACHES),e.HVIGOR_PROJECT_ROOT_DIR=process.cwd(),e.HVIGOR_PROJECT_WRAPPER_HOME=E.resolve(e.HVIGOR_PROJECT_ROOT_DIR,e.HVIGOR),e.WORK_SPACE="workspace"}(i);var s={},l={};Object.defineProperty(l,"__esModule",{value:!0}),l.logInfoPrintConsole=l.logErrorAndExit=void 0,l.logErrorAndExit=function(u){u instanceof Error?console.error(u.message):console.error(u),process.exit(-1)},l.logInfoPrintConsole=function(u){console.log(u)};var B=n&&n.__createBinding||(Object.create?function(u,D,e,t){void 0===t&&(t=e);var r=Object.getOwnPropertyDescriptor(D,e);r&&!("get"in r?!D.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return D[e]}}),Object.defineProperty(u,t,r)}:function(u,D,e,t){void 0===t&&(t=e),u[t]=D[e]}),d=n&&n.__setModuleDefault||(Object.create?function(u,D){Object.defineProperty(u,"default",{enumerable:!0,value:D})}:function(u,D){u.default=D}),f=n&&n.__importStar||function(u){if(u&&u.__esModule)return u;var D={};if(null!=u)for(var e in u)"default"!==e&&Object.prototype.hasOwnProperty.call(u,e)&&B(D,u,e);return d(D,u),D};Object.defineProperty(s,"__esModule",{value:!0});var _=s.executeBuild=void 0;const p=f(e),O=f(u),h=l;_=s.executeBuild=function(u){const D=O.resolve(u,"node_modules","@ohos","hvigor","bin","hvigor.js");try{const u=p.realpathSync(D);require(u)}catch(e){(0,h.logErrorAndExit)(`Error: ENOENT: no such file ${D},delete ${u} and retry.`)}};var P={},v={};!function(u){var D=n&&n.__importDefault||function(u){return u&&u.__esModule?u:{default:u}};Object.defineProperty(u,"__esModule",{value:!0}),u.hashFile=u.hash=u.createHash=void 0;const r=D(t),i=D(e);u.createHash=(u="MD5")=>r.default.createHash(u);u.hash=(D,e)=>(0,u.createHash)(e).update(D).digest("hex");u.hashFile=(D,e)=>{if(i.default.existsSync(D))return(0,u.hash)(i.default.readFileSync(D,"utf-8"),e)}}(v);var g={},m={},R={};Object.defineProperty(R,"__esModule",{value:!0}),R.Unicode=void 0;class y{}R.Unicode=y,y.SPACE_SEPARATOR=/[\u1680\u2000-\u200A\u202F\u205F\u3000]/,y.ID_START=/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF2D-\uDF4A\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC03-\uDC37\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE83\uDE86-\uDE89\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]/,y.ID_CONTINUE=/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u08D4-\u08E1\u08E3-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u09FC\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0AF9-\u0AFF\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C60-\u0C63\u0C66-\u0C6F\u0C80-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D00-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D54-\u0D57\u0D5F-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19D9\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1C80-\u1C88\u1CD0-\u1CD2\u1CD4-\u1CF9\u1D00-\u1DF9\u1DFB-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u2E2F\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099\u309A\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA8FD\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDDFD\uDE80-\uDE9C\uDEA0-\uDED0\uDEE0\uDF00-\uDF1F\uDF2D-\uDF4A\uDF50-\uDF7A\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCA0-\uDCA9\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00-\uDE03\uDE05\uDE06\uDE0C-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE38-\uDE3A\uDE3F\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE6\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC00-\uDC46\uDC66-\uDC6F\uDC7F-\uDCBA\uDCD0-\uDCE8\uDCF0-\uDCF9\uDD00-\uDD34\uDD36-\uDD3F\uDD50-\uDD73\uDD76\uDD80-\uDDC4\uDDCA-\uDDCC\uDDD0-\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE37\uDE3E\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEEA\uDEF0-\uDEF9\uDF00-\uDF03\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3C-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF50\uDF57\uDF5D-\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC00-\uDC4A\uDC50-\uDC59\uDC80-\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDB5\uDDB8-\uDDC0\uDDD8-\uDDDD\uDE00-\uDE40\uDE44\uDE50-\uDE59\uDE80-\uDEB7\uDEC0-\uDEC9\uDF00-\uDF19\uDF1D-\uDF2B\uDF30-\uDF39]|\uD806[\uDCA0-\uDCE9\uDCFF\uDE00-\uDE3E\uDE47\uDE50-\uDE83\uDE86-\uDE99\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC36\uDC38-\uDC40\uDC50-\uDC59\uDC72-\uDC8F\uDC92-\uDCA7\uDCA9-\uDCB6\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD47\uDD50-\uDD59]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDED0-\uDEED\uDEF0-\uDEF4\uDF00-\uDF36\uDF40-\uDF43\uDF50-\uDF59\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50-\uDF7E\uDF8F-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99\uDC9D\uDC9E]|\uD834[\uDD65-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB\uDFCE-\uDFFF]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A]|\uD83A[\uDC00-\uDCC4\uDCD0-\uDCD6\uDD00-\uDD4A\uDD50-\uDD59]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uDB40[\uDD00-\uDDEF]/,Object.defineProperty(m,"__esModule",{value:!0}),m.JudgeUtil=void 0;const I=R;m.JudgeUtil=class{static isIgnoreChar(u){return"string"==typeof u&&("\t"===u||"\v"===u||"\f"===u||" "===u||" "===u||"\ufeff"===u||"\n"===u||"\r"===u||"\u2028"===u||"\u2029"===u)}static isSpaceSeparator(u){return"string"==typeof u&&I.Unicode.SPACE_SEPARATOR.test(u)}static isIdStartChar(u){return"string"==typeof u&&(u>="a"&&u<="z"||u>="A"&&u<="Z"||"$"===u||"_"===u||I.Unicode.ID_START.test(u))}static isIdContinueChar(u){return"string"==typeof u&&(u>="a"&&u<="z"||u>="A"&&u<="Z"||u>="0"&&u<="9"||"$"===u||"_"===u||"‌"===u||"‍"===u||I.Unicode.ID_CONTINUE.test(u))}static isDigitWithoutZero(u){return/[1-9]/.test(u)}static isDigit(u){return"string"==typeof u&&/[0-9]/.test(u)}static isHexDigit(u){return"string"==typeof u&&/[0-9A-Fa-f]/.test(u)}};var N=n&&n.__importDefault||function(u){return u&&u.__esModule?u:{default:u}};Object.defineProperty(g,"__esModule",{value:!0}),g.parseJsonText=g.parseJsonFile=void 0;const b=N(e),S=N(D),w=N(u),H=m;var x;!function(u){u[u.Char=0]="Char",u[u.EOF=1]="EOF",u[u.Identifier=2]="Identifier"}(x||(x={}));let M,T,V,G,j,J,W="start",U=[],L=0,$=1,k=0,K=!1,z="default",q="'",Z=1;function X(u,D=!1){T=String(u),W="start",U=[],L=0,$=1,k=0,G=void 0,K=D;do{M=Q(),nu[W]()}while("eof"!==M.type);return G}function Q(){for(z="default",j="",q="'",Z=1;;){J=Y();const u=Du[z]();if(u)return u}}function Y(){if(T[L])return String.fromCodePoint(T.codePointAt(L))}function uu(){const u=Y();return"\n"===u?($++,k=0):u?k+=u.length:k++,u&&(L+=u.length),u}g.parseJsonFile=function(u,D=!1,e="utf-8"){const t=b.default.readFileSync(w.default.resolve(u),{encoding:e});try{return X(t,D)}catch(D){if(D instanceof SyntaxError){const e=D.message.split("at");if(2===e.length)throw new Error(`${e[0].trim()}${S.default.EOL}\t at ${u}:${e[1].trim()}`)}throw new Error(`${u} is not in valid JSON/JSON5 format.`)}},g.parseJsonText=X;const Du={default(){switch(J){case"/":return uu(),void(z="comment");case void 0:return uu(),eu("eof")}if(!H.JudgeUtil.isIgnoreChar(J)&&!H.JudgeUtil.isSpaceSeparator(J))return Du[W]();uu()},start(){z="value"},beforePropertyName(){switch(J){case"$":case"_":return j=uu(),void(z="identifierName");case"\\":return uu(),void(z="identifierNameStartEscape");case"}":return eu("punctuator",uu());case'"':case"'":return q=J,uu(),void(z="string")}if(H.JudgeUtil.isIdStartChar(J))return j+=uu(),void(z="identifierName");throw Eu(x.Char,uu())},afterPropertyName(){if(":"===J)return eu("punctuator",uu());throw Eu(x.Char,uu())},beforePropertyValue(){z="value"},afterPropertyValue(){switch(J){case",":case"}":return eu("punctuator",uu())}throw Eu(x.Char,uu())},beforeArrayValue(){if("]"===J)return eu("punctuator",uu());z="value"},afterArrayValue(){switch(J){case",":case"]":return eu("punctuator",uu())}throw Eu(x.Char,uu())},end(){throw Eu(x.Char,uu())},comment(){switch(J){case"*":return uu(),void(z="multiLineComment");case"/":return uu(),void(z="singleLineComment")}throw Eu(x.Char,uu())},multiLineComment(){switch(J){case"*":return uu(),void(z="multiLineCommentAsterisk");case void 0:throw Eu(x.Char,uu())}uu()},multiLineCommentAsterisk(){switch(J){case"*":return void uu();case"/":return uu(),void(z="default");case void 0:throw Eu(x.Char,uu())}uu(),z="multiLineComment"},singleLineComment(){switch(J){case"\n":case"\r":case"\u2028":case"\u2029":return uu(),void(z="default");case void 0:return uu(),eu("eof")}uu()},value(){switch(J){case"{":case"[":return eu("punctuator",uu());case"n":return uu(),tu("ull"),eu("null",null);case"t":return uu(),tu("rue"),eu("boolean",!0);case"f":return uu(),tu("alse"),eu("boolean",!1);case"-":case"+":return"-"===uu()&&(Z=-1),void(z="numerical");case".":case"0":case"I":case"N":return void(z="numerical");case'"':case"'":return q=J,uu(),j="",void(z="string")}if(void 0===J||!H.JudgeUtil.isDigitWithoutZero(J))throw Eu(x.Char,uu());z="numerical"},numerical(){switch(J){case".":return j=uu(),void(z="decimalPointLeading");case"0":return j=uu(),void(z="zero");case"I":return uu(),tu("nfinity"),eu("numeric",Z*(1/0));case"N":return uu(),tu("aN"),eu("numeric",NaN)}if(void 0!==J&&H.JudgeUtil.isDigitWithoutZero(J))return j=uu(),void(z="decimalInteger");throw Eu(x.Char,uu())},zero(){switch(J){case".":case"e":case"E":return void(z="decimal");case"x":case"X":return j+=uu(),void(z="hexadecimal")}return eu("numeric",0)},decimalInteger(){switch(J){case".":case"e":case"E":return void(z="decimal")}if(!H.JudgeUtil.isDigit(J))return eu("numeric",Z*Number(j));j+=uu()},decimal(){switch(J){case".":j+=uu(),z="decimalFraction";break;case"e":case"E":j+=uu(),z="decimalExponent"}},decimalPointLeading(){if(H.JudgeUtil.isDigit(J))return j+=uu(),void(z="decimalFraction");throw Eu(x.Char,uu())},decimalFraction(){switch(J){case"e":case"E":return j+=uu(),void(z="decimalExponent")}if(!H.JudgeUtil.isDigit(J))return eu("numeric",Z*Number(j));j+=uu()},decimalExponent(){switch(J){case"+":case"-":return j+=uu(),void(z="decimalExponentSign")}if(H.JudgeUtil.isDigit(J))return j+=uu(),void(z="decimalExponentInteger");throw Eu(x.Char,uu())},decimalExponentSign(){if(H.JudgeUtil.isDigit(J))return j+=uu(),void(z="decimalExponentInteger");throw Eu(x.Char,uu())},decimalExponentInteger(){if(!H.JudgeUtil.isDigit(J))return eu("numeric",Z*Number(j));j+=uu()},hexadecimal(){if(H.JudgeUtil.isHexDigit(J))return j+=uu(),void(z="hexadecimalInteger");throw Eu(x.Char,uu())},hexadecimalInteger(){if(!H.JudgeUtil.isHexDigit(J))return eu("numeric",Z*Number(j));j+=uu()},identifierNameStartEscape(){if("u"!==J)throw Eu(x.Char,uu());uu();const u=ru();switch(u){case"$":case"_":break;default:if(!H.JudgeUtil.isIdStartChar(u))throw Eu(x.Identifier)}j+=u,z="identifierName"},identifierName(){switch(J){case"$":case"_":case"‌":case"‍":return void(j+=uu());case"\\":return uu(),void(z="identifierNameEscape")}if(!H.JudgeUtil.isIdContinueChar(J))return eu("identifier",j);j+=uu()},identifierNameEscape(){if("u"!==J)throw Eu(x.Char,uu());uu();const u=ru();switch(u){case"$":case"_":case"‌":case"‍":break;default:if(!H.JudgeUtil.isIdContinueChar(u))throw Eu(x.Identifier)}j+=u,z="identifierName"},string(){switch(J){case"\\":return uu(),void(j+=function(){const u=Y(),D=function(){switch(Y()){case"b":return uu(),"\b";case"f":return uu(),"\f";case"n":return uu(),"\n";case"r":return uu(),"\r";case"t":return uu(),"\t";case"v":return uu(),"\v"}return}();if(D)return D;switch(u){case"0":if(uu(),H.JudgeUtil.isDigit(Y()))throw Eu(x.Char,uu());return"\0";case"x":return uu(),function(){let u="",D=Y();if(!H.JudgeUtil.isHexDigit(D))throw Eu(x.Char,uu());if(u+=uu(),D=Y(),!H.JudgeUtil.isHexDigit(D))throw Eu(x.Char,uu());return u+=uu(),String.fromCodePoint(parseInt(u,16))}();case"u":return uu(),ru();case"\n":case"\u2028":case"\u2029":return uu(),"";case"\r":return uu(),"\n"===Y()&&uu(),""}if(void 0===u||H.JudgeUtil.isDigitWithoutZero(u))throw Eu(x.Char,uu());return uu()}());case'"':case"'":if(J===q){const u=eu("string",j);return uu(),u}return void(j+=uu());case"\n":case"\r":case void 0:throw Eu(x.Char,uu());case"\u2028":case"\u2029":!function(u){console.warn(`JSON5: '${Fu(u)}' in strings is not valid ECMAScript; consider escaping.`)}(J)}j+=uu()}};function eu(u,D){return{type:u,value:D,line:$,column:k}}function tu(u){for(const D of u){if(Y()!==D)throw Eu(x.Char,uu());uu()}}function ru(){let u="",D=4;for(;D-- >0;){const D=Y();if(!H.JudgeUtil.isHexDigit(D))throw Eu(x.Char,uu());u+=uu()}return String.fromCodePoint(parseInt(u,16))}const nu={start(){if("eof"===M.type)throw Eu(x.EOF);iu()},beforePropertyName(){switch(M.type){case"identifier":case"string":return V=M.value,void(W="afterPropertyName");case"punctuator":return void Cu();case"eof":throw Eu(x.EOF)}},afterPropertyName(){if("eof"===M.type)throw Eu(x.EOF);W="beforePropertyValue"},beforePropertyValue(){if("eof"===M.type)throw Eu(x.EOF);iu()},afterPropertyValue(){if("eof"===M.type)throw Eu(x.EOF);switch(M.value){case",":return void(W="beforePropertyName");case"}":Cu()}},beforeArrayValue(){if("eof"===M.type)throw Eu(x.EOF);"punctuator"!==M.type||"]"!==M.value?iu():Cu()},afterArrayValue(){if("eof"===M.type)throw Eu(x.EOF);switch(M.value){case",":return void(W="beforeArrayValue");case"]":Cu()}},end(){}};function iu(){const u=function(){let u;switch(M.type){case"punctuator":switch(M.value){case"{":u={};break;case"[":u=[]}break;case"null":case"boolean":case"numeric":case"string":u=M.value}return u}();if(K&&"object"==typeof u&&(u._line=$,u._column=k),void 0===G)G=u;else{const D=U[U.length-1];Array.isArray(D)?K&&"object"!=typeof u?D.push({value:u,_line:$,_column:k}):D.push(u):D[V]=K&&"object"!=typeof u?{value:u,_line:$,_column:k}:u}!function(u){if(u&&"object"==typeof u)U.push(u),W=Array.isArray(u)?"beforeArrayValue":"beforePropertyName";else{const u=U[U.length-1];W=u?Array.isArray(u)?"afterArrayValue":"afterPropertyValue":"end"}}(u)}function Cu(){U.pop();const u=U[U.length-1];W=u?Array.isArray(u)?"afterArrayValue":"afterPropertyValue":"end"}function Fu(u){const D={"'":"\\'",'"':'\\"',"\\":"\\\\","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","\t":"\\t","\v":"\\v","\0":"\\0","\u2028":"\\u2028","\u2029":"\\u2029"};if(D[u])return D[u];if(u<" "){const D=u.charCodeAt(0).toString(16);return`\\x${`00${D}`.substring(D.length)}`}return u}function Eu(u,D){let e="";switch(u){case x.Char:e=void 0===D?`JSON5: invalid end of input at ${$}:${k}`:`JSON5: invalid character '${Fu(D)}' at ${$}:${k}`;break;case x.EOF:e=`JSON5: invalid end of input at ${$}:${k}`;break;case x.Identifier:k-=5,e=`JSON5: invalid identifier character at ${$}:${k}`}const t=new Au(e);return t.lineNumber=$,t.columnNumber=k,t}class Au extends SyntaxError{}var ou={},au=n&&n.__createBinding||(Object.create?function(u,D,e,t){void 0===t&&(t=e);var r=Object.getOwnPropertyDescriptor(D,e);r&&!("get"in r?!D.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return D[e]}}),Object.defineProperty(u,t,r)}:function(u,D,e,t){void 0===t&&(t=e),u[t]=D[e]}),cu=n&&n.__setModuleDefault||(Object.create?function(u,D){Object.defineProperty(u,"default",{enumerable:!0,value:D})}:function(u,D){u.default=D}),su=n&&n.__importStar||function(u){if(u&&u.__esModule)return u;var D={};if(null!=u)for(var e in u)"default"!==e&&Object.prototype.hasOwnProperty.call(u,e)&&au(D,u,e);return cu(D,u),D},lu=n&&n.__importDefault||function(u){return u&&u.__esModule?u:{default:u}};Object.defineProperty(ou,"__esModule",{value:!0}),ou.isFileExists=ou.offlinePluginConversion=ou.executeCommand=ou.getNpmPath=ou.hasNpmPackInPaths=void 0;const Bu=r,du=lu(e),fu=su(u),_u=i,pu=l;ou.hasNpmPackInPaths=function(u,D){try{return require.resolve(u,{paths:[...D]}),!0}catch(u){return!1}},ou.getNpmPath=function(){const u=process.execPath;return fu.join(fu.dirname(u),_u.NPM_TOOL)},ou.executeCommand=function(u,D,e){0!==(0,Bu.spawnSync)(u,D,e).status&&(0,pu.logErrorAndExit)(`Error: ${u} ${D} execute failed.See above for details.`)},ou.offlinePluginConversion=function(u,D){return D.startsWith("file:")||D.endsWith(".tgz")?fu.resolve(u,_u.HVIGOR,D.replace("file:","")):D},ou.isFileExists=function(u){return du.default.existsSync(u)&&du.default.statSync(u).isFile()};var Ou=n&&n.__createBinding||(Object.create?function(u,D,e,t){void 0===t&&(t=e);var r=Object.getOwnPropertyDescriptor(D,e);r&&!("get"in r?!D.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return D[e]}}),Object.defineProperty(u,t,r)}:function(u,D,e,t){void 0===t&&(t=e),u[t]=D[e]}),hu=n&&n.__setModuleDefault||(Object.create?function(u,D){Object.defineProperty(u,"default",{enumerable:!0,value:D})}:function(u,D){u.default=D}),Pu=n&&n.__importStar||function(u){if(u&&u.__esModule)return u;var D={};if(null!=u)for(var e in u)"default"!==e&&Object.prototype.hasOwnProperty.call(u,e)&&Ou(D,u,e);return hu(D,u),D},vu=n&&n.__importDefault||function(u){return u&&u.__esModule?u:{default:u}};Object.defineProperty(P,"__esModule",{value:!0});var gu=P.initProjectWorkSpace=void 0;const mu=Pu(e),Ru=vu(D),yu=Pu(u),Iu=v,Nu=i,bu=g,Su=l,wu=ou;let Hu,xu,Mu;function Tu(u,D,e){return void 0!==e.dependencies&&(0,wu.offlinePluginConversion)(Nu.HVIGOR_PROJECT_ROOT_DIR,D.dependencies[u])===yu.normalize(e.dependencies[u])}function Vu(){const u=yu.join(Mu,Nu.WORK_SPACE);if((0,Su.logInfoPrintConsole)("Hvigor cleaning..."),!mu.existsSync(u))return;const D=mu.readdirSync(u);if(!D||0===D.length)return;const e=yu.resolve(Mu,"node_modules","@ohos","hvigor","bin","hvigor.js");mu.existsSync(e)&&(0,wu.executeCommand)(process.argv[0],[e,"--stop-daemon"],{});try{D.forEach((D=>{mu.rmSync(yu.resolve(u,D),{recursive:!0})}))}catch(D){(0,Su.logErrorAndExit)(`The hvigor build tool cannot be installed. Please manually clear the workspace directory and synchronize the project again.\n\n Workspace Path: ${u}.`)}}gu=P.initProjectWorkSpace=function(){if(Hu=function(){const u=yu.resolve(Nu.HVIGOR_PROJECT_WRAPPER_HOME,Nu.DEFAULT_HVIGOR_CONFIG_JSON_FILE_NAME);mu.existsSync(u)||(0,Su.logErrorAndExit)(`Error: Hvigor config file ${u} does not exist.`);return(0,bu.parseJsonFile)(u)}(),Mu=function(u){let D;D=function(u){let D=u.hvigorVersion;if(D.startsWith("file:")||D.endsWith(".tgz"))return!1;const e=u.dependencies,t=Object.getOwnPropertyNames(e);for(const u of t){const D=e[u];if(D.startsWith("file:")||D.endsWith(".tgz"))return!1}if(1===t.length&&"@ohos/hvigor-ohos-plugin"===t[0])return D>"2.5.0";return!1}(u)?function(u){let D=`${Nu.HVIGOR_ENGINE_PACKAGE_NAME}@${u.hvigorVersion}`;const e=u.dependencies;if(e){Object.getOwnPropertyNames(e).sort().forEach((u=>{D+=`,${u}@${e[u]}`}))}return(0,Iu.hash)(D)}(u):(0,Iu.hash)(process.cwd());return yu.resolve(Ru.default.homedir(),".hvigor","project_caches",D)}(Hu),xu=function(){const u=yu.resolve(Mu,Nu.WORK_SPACE,Nu.DEFAULT_PACKAGE_JSON);return mu.existsSync(u)?(0,bu.parseJsonFile)(u):{dependencies:{}}}(),!(0,wu.hasNpmPackInPaths)(Nu.HVIGOR_ENGINE_PACKAGE_NAME,[yu.join(Mu,Nu.WORK_SPACE)])||(0,wu.offlinePluginConversion)(Nu.HVIGOR_PROJECT_ROOT_DIR,Hu.hvigorVersion)!==xu.dependencies[Nu.HVIGOR_ENGINE_PACKAGE_NAME]||!function(){function u(u){const D=null==u?void 0:u.dependencies;return void 0===D?0:Object.getOwnPropertyNames(D).length}const D=u(Hu),e=u(xu);if(D+1!==e)return!1;for(const u in null==Hu?void 0:Hu.dependencies)if(!(0,wu.hasNpmPackInPaths)(u,[yu.join(Mu,Nu.WORK_SPACE)])||!Tu(u,Hu,xu))return!1;return!0}()){Vu();try{!function(){(0,Su.logInfoPrintConsole)("Hvigor installing...");for(const u in Hu.dependencies)Hu.dependencies[u]&&(Hu.dependencies[u]=(0,wu.offlinePluginConversion)(Nu.HVIGOR_PROJECT_ROOT_DIR,Hu.dependencies[u]));const u={dependencies:{...Hu.dependencies}};u.dependencies[Nu.HVIGOR_ENGINE_PACKAGE_NAME]=(0,wu.offlinePluginConversion)(Nu.HVIGOR_PROJECT_ROOT_DIR,Hu.hvigorVersion);const D=yu.join(Mu,Nu.WORK_SPACE);try{mu.mkdirSync(D,{recursive:!0});const e=yu.resolve(D,Nu.DEFAULT_PACKAGE_JSON);mu.writeFileSync(e,JSON.stringify(u))}catch(u){(0,Su.logErrorAndExit)(u)}(function(){const u=["config","set","store-dir",Nu.HVIGOR_PNPM_STORE_PATH],D={cwd:yu.join(Mu,Nu.WORK_SPACE),stdio:["inherit","inherit","inherit"]};(0,wu.executeCommand)(Nu.HVIGOR_WRAPPER_PNPM_SCRIPT_PATH,u,D)})(),function(){const u=["install"],D={cwd:yu.join(Mu,Nu.WORK_SPACE),stdio:["inherit","inherit","inherit"]};(0,wu.executeCommand)(Nu.HVIGOR_WRAPPER_PNPM_SCRIPT_PATH,u,D)}(),(0,Su.logInfoPrintConsole)("Hvigor install success.")}()}catch(u){Vu()}}return Mu};var Gu={};!function(t){var C=n&&n.__createBinding||(Object.create?function(u,D,e,t){void 0===t&&(t=e);var r=Object.getOwnPropertyDescriptor(D,e);r&&!("get"in r?!D.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return D[e]}}),Object.defineProperty(u,t,r)}:function(u,D,e,t){void 0===t&&(t=e),u[t]=D[e]}),F=n&&n.__setModuleDefault||(Object.create?function(u,D){Object.defineProperty(u,"default",{enumerable:!0,value:D})}:function(u,D){u.default=D}),E=n&&n.__importStar||function(u){if(u&&u.__esModule)return u;var D={};if(null!=u)for(var e in u)"default"!==e&&Object.prototype.hasOwnProperty.call(u,e)&&C(D,u,e);return F(D,u),D},A=n&&n.__importDefault||function(u){return u&&u.__esModule?u:{default:u}};Object.defineProperty(t,"__esModule",{value:!0}),t.executeInstallPnpm=t.isPnpmInstalled=t.environmentHandler=t.checkNpmConifg=t.PNPM_VERSION=void 0;const o=r,a=E(e),c=A(D),s=E(u),B=i,d=l,f=ou;t.PNPM_VERSION="7.30.0",t.checkNpmConifg=function(){const u=s.resolve(B.HVIGOR_PROJECT_ROOT_DIR,".npmrc"),D=s.resolve(c.default.homedir(),".npmrc");if((0,f.isFileExists)(u)||(0,f.isFileExists)(D))return;const e=(0,f.getNpmPath)(),t=(0,o.spawnSync)(e,["config","get","prefix"],{cwd:B.HVIGOR_PROJECT_ROOT_DIR});if(0!==t.status||!t.stdout)return void(0,d.logErrorAndExit)("Error: The hvigor depends on the npmrc file. Configure the npmrc file first.");const r=s.resolve(`${t.stdout}`.replace(/[\r\n]/gi,""),".npmrc");(0,f.isFileExists)(r)||(0,d.logErrorAndExit)("Error: The hvigor depends on the npmrc file. Configure the npmrc file first.")},t.environmentHandler=function(){process.env["npm_config_update-notifier"]="false"},t.isPnpmInstalled=function(){return!!a.existsSync(B.HVIGOR_WRAPPER_PNPM_SCRIPT_PATH)&&(0,f.hasNpmPackInPaths)("pnpm",[B.HVIGOR_WRAPPER_TOOLS_HOME])},t.executeInstallPnpm=function(){(0,d.logInfoPrintConsole)(`Installing pnpm@${t.PNPM_VERSION}...`);const u=(0,f.getNpmPath)();!function(){const u=s.resolve(B.HVIGOR_WRAPPER_TOOLS_HOME,B.DEFAULT_PACKAGE_JSON);try{a.existsSync(B.HVIGOR_WRAPPER_TOOLS_HOME)||a.mkdirSync(B.HVIGOR_WRAPPER_TOOLS_HOME,{recursive:!0});const D={dependencies:{}};D.dependencies[B.PNPM]=t.PNPM_VERSION,a.writeFileSync(u,JSON.stringify(D))}catch(D){(0,d.logErrorAndExit)(`Error: EPERM: operation not permitted,create ${u} failed.`)}}(),(0,f.executeCommand)(u,["install","pnpm"],{cwd:B.HVIGOR_WRAPPER_TOOLS_HOME,stdio:["inherit","inherit","inherit"],env:process.env}),(0,d.logInfoPrintConsole)("Pnpm install success.")}}(Gu),function(){Gu.checkNpmConifg(),Gu.environmentHandler(),Gu.isPnpmInstalled()||Gu.executeInstallPnpm();const D=gu();_(u.join(D,i.WORK_SPACE))}(); \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare/oh-package-lock.json5 b/function/ui_compare_rh/uicompare/oh-package-lock.json5 new file mode 100644 index 00000000..1faa6b99 --- /dev/null +++ b/function/ui_compare_rh/uicompare/oh-package-lock.json5 @@ -0,0 +1,15 @@ +{ + "lockfileVersion": 2, + "ATTENTION": "THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.", + "specifiers": { + "@ohos/hypium@1.0.6": "@ohos/hypium@1.0.6" + }, + "packages": { + "@ohos/hypium@1.0.6": { + "resolved": "https://repo.harmonyos.com/ohpm/@ohos/hypium/-/hypium-1.0.6.tgz", + "integrity": "sha512-bb3DWeWhYrFqj9mPFV3yZQpkm36kbcK+YYaeY9g292QKSjOdmhEIQR2ULPvyMsgSR4usOBf5nnYrDmaCCXirgQ==", + "registryType": "ohpm", + "shasum": "3f5fed65372633233264b3447705b0831dfe7ea1" + } + } +} \ No newline at end of file diff --git a/function/ui_compare_rh/uicompare_tools/UiCompareTools_progress.py b/function/ui_compare_rh/uicompare_tools/UiCompareTools_progress.py index 302b2172..99b9b7e9 100644 --- a/function/ui_compare_rh/uicompare_tools/UiCompareTools_progress.py +++ b/function/ui_compare_rh/uicompare_tools/UiCompareTools_progress.py @@ -12,6 +12,7 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# -*- coding:utf-8 -*- import os diff --git a/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextCommonEmojiTest.xlsx b/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextCommonEmojiTest.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..626b771c2e9cf16803b6e8727403e5331180b419 GIT binary patch literal 11137 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 Jh)o9o{6Fpc2OR(a literal 0 HcmV?d00001 diff --git a/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextCommonTextImproveTest.xlsx b/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextCommonTextImproveTest.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..4277930ed2f02400f1e4055cf9b6d99c925ee65c GIT binary patch literal 11105 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 literal 0 HcmV?d00001 diff --git a/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextCommonTextMinFontsizeTest.xlsx b/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextCommonTextMinFontsizeTest.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..4078fab2d3fa51e73e3d9a45c996199cbc6ed96b GIT binary patch literal 11256 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 literal 0 HcmV?d00001 diff --git a/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextEditMeauOptionsTest.xlsx b/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextEditMeauOptionsTest.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..71ebcc3f3b933c68877845738e827ffca57900fd GIT binary patch literal 10847 zcmbt)1z225)8^nFAi>?;-7P?HclY4#5*&iN2SRYS0Kol7)gs1U$BIg*B1K@BcIe@IPh_rb^BZjxNkfU@;8v z1^6Fg+sbLQfe-*d79;?G_D?ZmM@J@4JKOBUF6#vrw6NpA_F!~il{x)TRqO1N(3%aj z*-+c8rD(F4Iy!?vsmS+PF9#{ZMV3g4+vTCWqN5K#^A#2^y|R*g@O{X=GwUeN$9gmK z1%o2y+0#ID4Qm(uc;>843i1Th1t|kvC>Y)VYU<7KeBVP`C??AjbR8VScsux!AQk4u znsuSRx~|AN`+g{*Ma~8pD~Mu^g@aD$Pl;xd#>Aac@kv`BNO1|U?LdaARucW&9rjO9 zAk(h5i%J_-AXHOd?E=cw$5coSLPgrUUr*n-N^hTXSe%~r%i0wHFQ-4)YK#<3G`BmS z?4u;UfI0~i;be_G} zyk|PQd4fGG<@!<3bp^(%d2#_7dAtE7++ZdKwaVA))!p^_{pBicu@>=>H?KXRjUeM> zJH*G^zEPu<&TgOXm?xZ|6df1rdx$r&fj(gn9-YmzkRirf>D7wSN%v<({;$-pVSjg5 zVJB0?3$VL1!R|u;r@KrYoXsEo6`D99)5C%hb_}!pZlhiPv%RX=eBh@l3~1^|4^rOw zAbGsRCVR!zbC6VfsNKwTL{J*__E5jSLgJW5OJw6pTbX>IrI-@5s}NiNNXNrC!8 zUDKhD^oCFh2pPsGfwDwAMKv^g&^$+J_%e3mI@mq(UYH;%3+BE5IB1!4V`+=huF<`oPcZ~NV=+k z=fwK@_v_Q!jx+|ta3aDGuIxnGA|WFRv&u|`BbB?0rc<)$=t?uyOPNRv;?S<4gB!Z$ z8EcHM?%gEe@l+puZ2DnHiR^=Rz>+c=1K3p*`^viT zI~+m7x&#M?2{C1g?iRP61ljhfzTI&pgtjvUpvo05WycjF`t^l;kr@MmUKdm{K%>Pq zl|jlePE0XNkCaAm`Ku%c!hIv`?;w+k(KU6JZRKGynjW-Bfi+{C8m~d5OenY;Ic>4_ zb%bWiJ5`z{_(h?G=A03=`OB%x5se+&i|180bzY~R!oMj!@ML~ z=rYoUFq&^1&7L)WYOuK2I3y$56i{Gt>Jyn*1VeLU;@!=tqvSB|L0*lq_*t>wEu)85 zVrQHG!=)N^b=7|PR-5$sAcy=yv+cL(Yp-P9^BQykxFzNVHhGLoL5QdNKHJS0S{RxOKb2fnW0=e7tnjVse*` zA9I>F1^1}s!|(*b6ZKtp`D0^>My9OYu?X0HqXHD zKA7eVZL&4je=iW&r!xvZbKAQ6R(LgHr3oVQYa&)yaY++gIHvz9A#_vV5-xv3+A&{Q zMC-?beBJ7tMzloT?&w+mqwY zvl9B!Rg;6_?AfmknAs-o+}Zl8xfM8OB6ifNb(pB=K{|2I688Ny#QBBv@PG!I99b2` z=funF;uEq%X60cnYxvu%?KVsZDUp&_c3mlB$5^gwls%|&;bS`h@4RZ%$=idJCm*KJ ziOr$)XL!gykTh&!M+E#$NM~N-QFp9=l~G_Jc$YP9jYab(J$mZ zJsk!MCnN+38UXS&j;O)|?Q0xZTMU`bchD5+by!F4o`lV6M0>f=jBK!s@pV{CFMFL2 z542kJ;B`WBVN||!hem7V7ONco{kszUyTTeh2#eG*FuB2zlN`&k0xT*4uR~(axG?q_ z#=0Eb1@4#9MoQx_2|OwTcl}f)AETAq`3tHKhSvTE%JAOv3eL8r8k#|-Gly_4KwMCL)+@t|sGzzU=wG3;E z#5KF^Pitr(kcuiOm%dAk`~5WpFlp$nh6p-AN2ZS?tTr>`espG%8Gq_Ztoo(<*9bhB z{(o5cgV1Pm+~fNI`Ky!w2?Q+`bH>vn=HMfGQQ2`nIc?dt+o9aszXtI1_?~U2{b@b) zVn6u4(eIfw6pPxtNXez#5i0tpLr*S9AKCrCW(2J3w;SmKL~VilH$%N-aef<4V!8sY z%TY(od{@$kPcHT^c0(GQlEQg3R`zdPcNYNZzdCnDEMv`L9TVf=UD=8N4Lu7 zY+G{g-dXwHk>4y5@e^nJTO~DG>R)O36;t!qW6Nt!toN?cu2I=#je1CIPHsru`8+3{ zYHiG;mQwvn=&iL^{uExGe(0JbeYfA%m*?h$`0Lp zJE5Gg=mC35V6JYEFHG2Q0G)1aW6(;k6b81BkjiC;Ow z91h@6&qCd*9puIm%Vr#^(UAohQ!v#c7oXU6dj?VXZYoo5>_Fd9)z_(4a?vA@l^z$; zKz#T>_3WvUzsG8$VwVS9C>}fwFam1%<#4 zNd5b^rhB#8xPr0xCai9ceeMHdYd6Uo`(0iy4kqf#8T`vFgIz*_8MrRf{%1+~B=p*%8BFY=hkd z_2IP}IM})EV;KZH`?{bkmmOX1F@mL7DR*5_^zAr4v_?&*#v|mzDR{Oj6W2E)Zp&h* zJ=fN^jzo~%EYgu3hw6g^D2YT;NDK0goj}7Vb?A!^rawE57q3;D%q5JD-o92M`4To2 zodeG^Xx876LpqBtTU~8<2fF#leta2KTpXA4R_JE);&grTh46MeLl0E4WYKE*aR=yj zUJ=-l<9D?;sA=EEa@z55G3U_nY8SR!NQce)`f^e@N7(OrWZVD#q!(g&-O{%E1w~hP zYlLDOKSN-{Zs+XqX?jP-M;giAIuTZod(+X-EacJ~^1bduQ-04Y9;w$zo_60l*Z88Z z<(~ErbFcM660u5N;d;QXgk=uBKCw)dJQ}chfoKsWt2!+Tg5&GtYKl#6A*2Ml6fDfpD)_ zldZjzR&~M!J_+$rJ@JH>33)SxYTDTI-t>rrS}Sfz>8FETLvU8rb9;3FVm}WwdL)O7`7IU9*4=C25Y5Cw^J)ZULY<_055F=QoyvOL( z+L!HPv-MLSF&e^8ydT5G-gd%pl&BTsdUfiAsJ+fO*k;GWoyd#s!; zMYQvK>79WcA}SM%wLHG*9WTo^tE%~-WSt8&nn*1i4xO}zn2!=JDDLH7MO0O3E%&lr z@3!2bWT-^6``>mR5(-h_PQ@xw>xz?mUSmq-IDn#PWcxx7NYS?;X7ZBCMa3w#h$yA| zHHVldMN}(EGj;8dpjWdgXJECxW(Gt*A5yFjLc@KQYh}$N%l3x}9c$>mR?9LZs9=~w z{wx^X^UOi+<=vB@r#AK0bOEI3Cy~XeFW4zgH0m(w%)eK16p6Wy%mlTBojHlW$H650 zh;dF(RoGUL-;u(~(vE2p7Jx@ei?_<7g7O8qY+8P(D#2xT)@_VSC4pVsWsaRuU0Hv! z(&P(r6j#mDp(swT;Ayhnai)|eS(Zfxw7 zWMz6qFcy%ONH3OL)zA_sdT_|iSd#*G16s%3bJ$UKb7aDT(&)5^22r^4 z&#v)Dl@Gh5qO;-flc~9Jq#>U0$G!s0tr7*ujWH)~MBiiwx3iCL+&7>o@f&H8$%?x%0|q=DDPq zlA3jSpY@31Ek7673uq&_=iD^Dx%-1mrc`3=FJK~%zu;pqHx#~s+I1W3;!U`6rtk!mKh=_@oed2&E zLY$l+g^+?b65|^h7TSJcgHTlyb+(dK_B2Y6J01nkL-dTEkm2Oc&)wVxV8Re)2hk1);sJlIPRe zU+jFZ|9WkPia10;?gN~R_jOnn#zit_n}1$t8QBg~P;)9?tzrlfePREeHxdfnT^oCf zbjhVt3vI1{Xd!(02O$0+u*~0Kf-6F^Y^C-x{ zZ>F-$fTdvH=Vd*Yu*yRj8TKV86+9WGazdiXtF0|*Nn-sBe zz>?tU(y{13?R?C2>!3KNcIKT`u)lkEY5(EAW!bk`FYumMsX%ZhZhuXn#djLS{rh^t zbRAmlM+N|}jR63Zzt)qhm#z7ag|w(|=P=(#=r3%v9H>+S#G#V)9f#5%%3#bA3CxAx zvc;)EfuL08VwIVqp{wP`7)Z64<1-UUu$yav+}AOii~6|OVvO>Y>N{J4Nyk^s*@q*k zrEJdvOI=jgL+qlGTj7VJ`>TVP@^HZyE#_X&=MT9N&vcqew7)mb*WTX7bYI!yeDoH@ zyRqmn<+ES5#)z#jUftW8>1brVh$FB$?yU1g(7FhZ=?*+b{UTdveA~H~(ZlIsbh(;U zwSOr`EaZJ#xZ3%CcoYr&@=c-&lcucTJ)1i^J5z*?aUY z^?2{Y%bBa&s+WxfN|)o4&qq&iOc&qJ=kU9>-s9EKH7`~zHk#mlnofMVSeM{&(Y+<< zKgI5SuVmet-@Z&^IYA%cd+rTq@ChaYXVH~Ew@-do_j8JaVY5m*Eif#{U(HO|@4T3N z#=lbPe&y+MGcBgfJDSvLwvjZn@5e*^8-bY5ZX;9hZWG%E3PSiQ#Yx;M1uCsPu|SEm#RIDT2I<0etUntw7Y$55(G7gFXl%opoRjZM<3l@Tjn5a-JE-A zQdvFik_!nLhe%G?-j$t3G&p0oc`Wi9R%EGLt z%8-!oO?8w|;zit?cp{KE8m;*^o4Ke7)Sw|zF4z^*ih3QqzGRnn4QqW=MGihH6Kcg4O%x2wQ)A>Dw^a5ntAHjE17I_nJV&MV>OW3}7i2@>l z8RL$H9go`U0l}*`Kc(f)zi59+G>AA#I|m;? z9pieX+GE15Hybjm_T8Fws%PBfQ_`3_AkW+ysx&c`^4ly+`VKWkeJfQ;HO=%VHYB(q z0`Dj@v}r52hNJINLNXFM5?R(2#@1|H+&&sxY*bVHxZK>h@&=m&uK_dshXDJT=2Hs+ zgnH0dDX}CWCx`h0SDusrz(Bnml@g79V@Hlda;892_|ok_nVC&!Px4tBsW6kAxSBi% zhsuPtPIHlZGTo_{#<>{3IB7xBzV`D0B{L+_=kcr|$R7o43!e38+nLeS%?+TL)hE2; zDUTuafJRzHCo-K}CZm7(x%cpmG+B)+mAr=TOEu|Qf}Q|OApyH5@^fB$g*8Qvmwt^S zdZ!$mL0edO$BmmjJ|!97MY*lJIHy90-7{h!YeJzIsq=yGJLpt&!7o1RC84fx$4d1e z-G(3vMwU{zusFsxIz8!HINfIKUpl^G5Kvbkk*M;ia%k{tD}`1BoOhqlJtT&RK0#Tm z_3SxWilf9WT16q1ecBg*2*Zp*d{^nxR!mF2P4%;vZ-)9JLX9XrKjD~0 z6DqK362s_B-%YfN&a4_zpEN>^*D@Dzve06{YO3*~zoN@a)yMFZGV(e#NsPR%d|*qu zUrpfBjvrTPYcb+ro5LU~Rf&JEQH+tq!ds}ZM@vN=^lD1=_8UiHL5LbU5Qbc1F{Q{~Oj zI${SdWt7hxadVghQ}y6THAm2*WSMxkHDsA|w`F9p(yrwNDpIdU1Q?jkv%Iw!&$E2e zU+3GuxSyA$>}U>;Xi8jO=&?o^OCwpk9uc%X9CSD`CeL}imI3~d6adRiv;7dv{Le*k zz0mFH#yv{+>vRSx_WglN7e;c~aQ#znHWF$*H;K5sL0eB^m81w73nFB($nBz8H?uaQ zu}bo{FW@_zu|74wwp>XV5rSeKV^lAg{fbHBESZ3vRhso&Lza#&=P;#4#S$5#6FFcyXHKr$fieOQ0U>+C0i$m$CtJWPtF){#;jpu4xa4a;Jkf&R z^<5W8vqQk|*n<=o6hKP;GOGv35cnqPK>%0y)=Me?PnHgjxG5v`d{2>CWME@m3cdh3 z4E8NiMiDN1%lDeQbtSyLPbyX*k!}u3<+yjEgt9Wh9v}KG?|qIhR-*?cNrH(p|6pws~B72e$kt5Jl*Zarv&wR_@!IQGyU+~b4 z<%^={tzL{W8wmN}C7fs}g=pdUpUw>mA4B%_D-vhF0^JW*3%{!gCGTMPf@w^t@o70e zQiTqmh<;od+fy}bB&Ye|oQ1k9Z3XrVz2kyTC&>goI=+Cxy8u$n zBDtAd@oFV5U!MX*r?ef+Pp~=Z7V?-qtg$I2s}S6d$RQxP3qZLt_k{NlsG;0 z*9(sb0cTE9XBe#r9gUQJ2E7k%SQX%F7RKy_0rGj8H26f#H8C2URF9S%q42HcXZaA@ zAX!PTVHf%O0_2~WaG^gc)0Tfd_qVcVK(V<1f35tG0ZdOA5-d*`ty<)ebon3V8_9ZY zf2zeKb$%2)8K^Yc_}nGvddMH{>d$lGbP|hbgczrW~3aw(~E+lQ9<$5z`oLuI4bd%O?C8<%ESiwu+R8t zJ>F56AZ&z(Kj+Q1AcbnJ$=)~^hlto7=h1#2o9h(1-ml*@sjR2nl@Yhmy&4e*HS>NM z`dp6syOOjT5)2%KY%+oiUtG)qZx1GdzSJ~okEEUx#QAeW3#dyN(z}#XX%jb-z@*AG zM&6(~&ao+taGsExtS8+im%}E^bZ-!c^}a}ReQVZa@iCEjcCkIEIaGSU9*A8^YJJCE zoUO)Gs`R~#hffwL7?-A08Tjf$98*po97jH{8;+t|MHR2}9sWdG45VNCk+vgcjkimA z%xGN~2@{RqV*BPzx_Z9ITWKpwx{*latqD~vR5V3jAqJlBsO#uWxITVnJ<1br)i1IS zt@W+2=rgM@8y2${*EAaRm{W)3{XUo^qv$Iy2h~DzI?n{|2j8}Dtlu8n6F0?%76zl6 zfkI!zNpGUA&^Zp>R{8ML#r9W7fAqs{k+QWC5LcjEYyiGncFk5swZ}%S?|Obt0ofm& z(!X9-aHa()dB5%RtuxYWg;bvoMcFzs+O?9FaDS7eYLFzJg%Dqp16L8MT+PP2VW|SU zJgioAD$}~5Y1;OagrA2jm-~h{@biKUlC6Leiz>=oOxX|=DHbg+XN`2uFy1n)W;g9y zjK!K7pfY`xsdat0#{8j2i0gauSS2=VQs(Z$8w^^WEomVN$dAdMPst-3jgEA~?0BQ8#O zqZDc}JIq97TB}EToBP0hP2T!88v8CS#rd2OKz$Pju^(RN-mZH+czcNuI==-XSvxW21CRt7Fsws)Q<>!{Min)O9@z5-Z5u4p`l|B zned8A3q}+Pz0h>k$c0V44kw0;emw=^NXp!iYmv#x?e4CG3Elc3DZUWOy!{6Xw*KCY zR4*Y;Ln-Go#&VDUV*>x*=p3+}b3Opm*aD^#5Bv>I+WZuIJj4D^w&5>!<*j>I&_b_5 zmqdr#Q?pZ5WHxMNNaw!@2E_NJMld3bT=ajab|iHoDZqDtc7O$5jY!Qej`6%^mYagB z&ZUz<+mWvU9%J}&RC_3ryl(j54NrtACskAK;Lzy6V>y~OaG4-Fxm@G{d!9$WoR~v7v5J?H7Af-YP&UrACC0=y~G37Vjn5;o2 zeMnoMZ|Y>#zj&&YnopWluC8G#-#KaFz# zjrp-+{+qGKGqs=X(b!}ANB!IH_WrDZdldd@kNTgmzv|)sr0CCrtY7HI^y1$}|5Kjz zC;ZRKqF-=1aAxus{O>xW|2FBz`k9~Yani-me^t{wPWRtk@;gh0@SNS{|WnbCi|y?KeNrh6cB*}9@y?bY5Q-3ek_3c*&aPS@YBP;l|%i0Z~s{k h^@#oHwTu6O{Z$^NBn$Inv7&=Z4B^0XVpNZ~{{q!6r literal 0 HcmV?d00001 diff --git a/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextInputDeleteCallBackTest.xlsx b/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextInputDeleteCallBackTest.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..40241ad0b6047afede359765ce2288265f1c097b GIT binary patch literal 10902 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 literal 0 HcmV?d00001 diff --git a/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextMirrorTest.xlsx b/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextMirrorTest.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..4de78049c492fcff122f89fa7879c8ddb2bce637 GIT binary patch literal 11100 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 literal 0 HcmV?d00001 diff --git a/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextRefactorAdjustmentTest.xlsx b/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextRefactorAdjustmentTest.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..546680d91801b9163ef8e55ce009f1ad7033af6d GIT binary patch literal 11000 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 literal 0 HcmV?d00001 diff --git a/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextSearchEnterKeyTypeTest.xlsx b/function/ui_compare_rh/uicompare_tools/excel/UiComponentTextSearchEnterKeyTypeTest.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..0de59ae611c64c8af3fce31d1ca9cd765c872f9c GIT binary patch literal 10682 zcmbt)1yr2NvM%lHt*(jmaWQ2s7vXm8KxZeyL9&|$gAj1qbr01QHHtu&z}w(Z=>3>;Z`@Xvhm|q&1%o^q z9W4M=&C*FXjwyYMoGkwNqJ*9{Bs7md71dT)p7)_OB%}EWsuqrZoDJM?pb`_HdPAV6 zwj-j}wil9ciQ|)$1$dF#;z2vqK!UNjAyK&5Ggl1 zg(aU>!IhJJcfm?kN0mtQLWF>wZ>MjaC3jBQO;1mIrET(CFQ@CR)rJel8-b1|`^X8t zu&7@hdcaglangs;In*cFhs7x0Cq=QKI58$}CT`LeZJgfVp4hfpRc11sbJAKAarJv4|r8dZCWo zVJWL~=QQ3Mak8=u9hymgBqjDSgFO4VjCDT1rHKuQ^Y{NY<162Z@-gUw;SQyS^E>S!p(-;@z{QVic&A@AL`3kohf z-QP8kF&sEwL3n>bf0If#7iKyUc#@Ng5=0=H%_~1Qd}tZqE;S)3Q_G!4mr!fb1Lx6y z8jg2#uBd_B_`s%wm+1V8h76rEH49fBVwvjU2J;&GpQHne4asOhq@#jJNB;-uE>6yN zHczw{#0yJDo4NvH*t`6k*C>>FTzzcwl#SyyG=Q5+(r?m~&+TQ|h1_UK1UgM_`6(G&r0z&D!T zD^oYXEeR|(W(}(>TuxmMt9>Q%MdCiEK3`Jy!5b#N9S+T?ba^oO2L43tzeg!Z5Vh{s zKjPEB3q1QN;AZD&y!-q&<72QWjJ79pr0pYf0O+IVR>>^bgHi10w-vV zz#a&~HB}kU#biPOB74NE!CxrQ-!-Ti^J0;vrit}h_d5{vQO*DW}`ko$vcuDiJz)$c(t`_LhyLGvr)9by{F?lzw?ei)#ZNJ`E+M^RIq{( z;By$$)9}`m+hzaytBzB4p{@hF%Q6Lkh01fsV1d`|!saf)Ro3dvhp4p7nKzYwf|p6Y zX2^cU*Z7$icT&jQ+`3MBVxpv$@>a~36@tOS=8f1ptXRO zzAje9;XwyQNQJWIynBkZw((-D2V;t~ zqeW9b_l;^hxXIvD!(pQnV0nu%maFUm!P{nX*iwIj=ByxA%SoeGzxHnFp0kkamc%b* zd!l2%Z);S(kTrzOt4V$R?QwvamA=PnRWK!=hoFDa5TZITwW6fdrDb^Andtk1_B991 zL`OhX6|naKcr!2V<sM&EY^Bn`t&QT56_b~weWv{k-ir?4Kvn1C$+29)*KG+y@>J-u z-^DI2NzsRo5^#OJ?Q>JJ-vV#LZMXX&1d_YNHgB^r$K$WG^QvYrWfQlIzil|Zr*8P9 z5>whH=e=*OR?#Y^LWj4+!IL7;oIT0GgyU;C-}V|ihwK)RT0X(m)DS{+N=#<1-}P1| zc6Ix9{;^z}iH(@-cXO@*BXd8VvEyvz*C5`K_@K=+*uU*B8ksD^Pe0Bc}nCv&ez z>})i{pkc5UdFCsSoJYKO{n@wxoCcBsodJ(Ofmo8i6&FxN=A9529F#v8sg%%bToh(i z2ykK)Fo?I*;JV@d{v~K|U;$t#LSpa@avNkurBDz;#9&Y;iVzQU&h!R<`-sYc^&2WI z{zwmp<5`Z8<==%KXCS5Bu(07{tmIJ~L}eb&VjhqLu;+nHwlWKwFcBFeg<^=Cz+yCR zhv0u_Y4+D=Ta$JOlS?cTbJRdA2@6DZHiLj3&q$OyIAO&6x{y2EY9X7}S8!UvInYY; zofOC#InB!;MIvJmG&XC6F!Txrb|4_h4^z63SmrhLaKa$8kd$WO+R>GU%L;n6I|P=D zg>=K6vU$zHXY{(LrdSZPDMsEJf#KT^yIxP@{0CUOp%NUiZdN-u2V|PKfI(-*A6n}G zWcBA9Dy`Zf{)2rQ^9+YU0G8LUG4JD53q}4OvkPdJd(<@>UvUV@HP+GCS`e_`r#vAXGv68|91lB2C z(Zr-8@Jn{6#~h2u5_bYlzDF$u81pZ z=ktPNMRIb!uh**Ichp_0RL0~C#kOFyyKHkF5t=)RGi-NxJlGkjDrR0>ZtLypLl*1w zUTS|gZPUD+1jB%;p2&#Y{aCZIe9VDR4n82r>wTrwdYBf%b#GVYuxwTAhgc=t_;`!w z%luUYgP{dx>$(RIsAp&6vX7+~*91{^0nX&kiH8t zNxX2a?6~dvZb81aEz9R>uV3A^h55AY@nX)d&36~3Q$UN=^X76=FiX(qW_ZW%;iMaU zWy9RM^EG)#XLGoG%S-xzPrL22L#OZCQa@9Rch?HBT)Q?L4bDO=XOQi69=>_$e#I^E z7SY}2Tl+e1)Qt>U?-18|Hv}Pz_!X`j%xY-b;M)`PWbvc^o1yL{;jgnCZrBBCmUkbK z>Jl4tT;Euax5z5eDh4al^It~EvbdHX36QAi#7eZM8ldkkQ7sFQj>JXv&C=!!48;fANBt=%|ip+{1{hkz6@tRJ8kj_(6>Ym$>A1=QByX^x4?Y z7*ZG>^{LJsvF}?&r`-A=rML?32s_l8MzI2$b22CkOah9j*pB+PIEKn^2}X9I3@ccP z50dq$$oZ99&T*FqU3*tHx*I*7sdamz9|=;A^Rr9ay_v<_XV_~MX;U|U^s5?6|8}-8 zvsHi*BvsaB;Jf~1=h%4T)Jue#V1Vaym`HXzG<%LcSkQo+KCgoZ!JyG~u`8>L!5V2y zU372ieQ=*UP9BonF^4`+xY!ymnqCjoBHm^7WPRtPrek;K{TI!$k{70ogb@8(?w=H6 zx}t@*znWTkB+@Qf0pfwDjBwNoTqK4vrirtzapnv#s&N)|vouj#4c_c%EZyMRGk_4cw-Lbzqm}n4#h#n)_fAh;#*it4C_PciEA}@jT!`53 z*(#adDsYXF(I$^_{3!Xg?<*mt5ypBh@AOv>^A?NBg~24P3l-`J4IFl@l*j1Lubhxw z%jSiYm1)fPGM(?YT_L3?g*1D!+Ybo@C~>D^6sWYt$lPx*C9>?UBdMi(LJmk!cfeGAU+YG(BeegeMNkH~OJqCuEvga!E7&phHGK zb>66?>*JTx&mm3lM|Gjw$(Y?g3q-T3v!wMWK|P5mN`B2oexg>3QET$Og1u10b$BMQ zDfG-i>>~~)!Dozf{K|rs{JgezEX+Vmt5APD5*oZUZYAU|NTt)VgO%}4v$HOvoJ#R* zVoq~x462H{lNCl^kRmy&(FP+qJc6c4yT=%ZpJhv5m2LvCwdx(^sGFgnTB5S^_OtRx zaHf(IHK#B(TyWLWbfe~5-_*3T6=xPn;*_rFH0XwF&yi(JcC3c*3eHxjF(Aoe?MM+= zeD4amL4(^89z$e;(|%+b;^pKnJ^a(C<@91hf}8nHxHq7%MwF zTG*O7JslQo6g#B4giu-$A4F%H=ca<*lGAXMYed*sa2m)PE=9=_H@{#*x9}6XCm8jO zy?$YfDl8Iv%)j00!FK9wH@}MMX`LZEOCF^Grq*0q(;SR>cC?-bEis^0>Vk#l3T8Zc zaZfLv-#)4(qai!BWFON6lgI2#pi#xwyi9#oz2b1-set(f%vj48_m%o$aZjyKbB9u= zcb`Fe3V5wxM$c?MOM(8e-3n1QOA-6_>+O{33X!^jb`4^o2?P>u3ISw*rMxto>;u@1 zLx+(7Cqvp$>c~tzxuHByvEEE4+65wapD64^QB2s`Iv~R&mwwv>;HgoSY(yhXLuis3 zIY-&d#E+F8GCOdnl{8Ks(erFR73JH2GefZGhGNmJUr6Jl&@JRYNo7nX!u|px^aymG zd;a?rW@Kk)_2clRtZSFfjNy}A_h@jF`95|G3ZqyAUaO$6bb@{KqD6@_AtG8z{kJHY@l5mG_tp+fiaC zu<<9n57&m%PN!!>H;7{pGUC-rrO2oW9-sg4$dCZ^`ilYi!mOJ0n=2irsmgaNtL=k{50bpE-=2Nwqf*I0$PZC>1 zGld5HL5EC1ID<|hB>V+rq@awcOchb6%pBDF)a$|SZxAzSW^$&(neBjtO-tJwi|rdk zs@A#dxvEGysyq$g$HEVds|hKV$>%W9l`U+unz?K29i`~EOWkFP4D9Bv;`$wqP$LzO zF2W7cvUEF>k7NRSZrX|An+MGC?oMq>c2thXoOgEeb1G+^>G}J+_m{Ty4^1oHjXD7j zJPP^zGqL;Yd`;fd*IfU61TdWk*Lsn_z_1O$z>xp5uADurO@1t>C0!f4g&qPwL4%b5 zh3ZxuN@?#gNZr9yhIFBT9Jp<3oN8on3Pny9sVQpOnwJ=T$)#zOHnb4?KYTE=sc zpO=~pk>@GDv&I{>&8yEo9!V@`y62l~KX*RFE-bzid^~!%I*2X{`;vu?l$c1pG z)kv)Q9k5VycNg7xWsCFKQyA~owCxSA?TRHvOu6CO-u6rzfaM|<-|D!%)*D{qA}qQy z;Q09$=>o&M_Px|D4mX3#we-sUOBo^o&%1)P_K!m&D5#ei2}+FW()^Q0*l=N&dM^mfJ55lMiPfP`6d%JP$8tuI?($0Qd@*W0RsICpd4GJ}zXvbZ&mYtEO#S zs$2pX;SEeDm@U=DyIpi{i~CKnc|IsuHs=9XsLjXe!oANuVf6-}!*Q0JU*`14?rKlG zv(s->0@AdGX8EZY3;LWFk*t;2kiGCOH4(~3Z zr7u62w?d5ArGn3d$fv`h&68tE!Y0j6M)ROG&g)>IeWd$XIf({(d};A(lMkLT^ef!f zxkVfx%@Qj?F(qq+!h(yA{Mk3{=s?4y)924J<~~Z)oJMXW?hs`^+$`_z92*5fPQDQF zA>mU&ZlyyV*;!vmtegjB@CuUB#k)D?A$d4GePwpI_8~AW$>AcH0Qz)tB(r zY~t6H_Ng{$5=#DxffF9LHJ@P^pV4z9mJb!qmDjmrmg9cqO6-ebUK=VS9?2hpjZgpR zk-H@gQ^f;$&EkvadRl3M}dbk;#047#TV0HWVV3Lb#>)vqQ z+tP?z{}WRuNEia()+O>aG4v=`49r;MUe`68Y9ksASKbBCjIbYJgk}ydwDOHx9M+vI zU?rT^^JDlXAdu<6x0kohfLMuwKt_D6e1KxWlGDXUvK9lu#fGQ07i%2Y<)_r+;?fzs+w_;eV4-2265){sZt$NA+N=} zxaUw^*t!wD&aO0WsnuAhnnZi*p>{6vQj8=&abHukPr(?GL^O^i80j;g zbv}BRrj0Rm?OY#q4RKhotE2MO06WxaylBCtnl(K5tW-5|3_+9>( z0(>^lWam8g3aSh3FMR;RI;ZR$f!kPk$AB$vuj172!d#Xe98E`Vz!R~I6UiEJl$dFT|T~|=TlW8epTsJY4^#e zr36YI?7Z`Y_Awz?_!;t2jeFP0ax4XI;TkfDG+K{80yGmcpzgQ*5RRztN1-4$(a zvMz?Zgn`GYQ9{H`#UpFt!&*G2X55%kOOpXR>l_AQiBjB0wIYl}W}X7IJsL`?K;J3l z6JM7sDXE|nfmbv^(m{yg8cNGSS00M-lFlfyc=H!M#&_i#afmMN7?hucot;X_6Bmhr zJgN!(1SmHdwEf12Q)P`%S|SHdr4;D)xLHgA$vUtk>cc3J(u_PiYSN6_J5thEDL1lw z<;ge0eDsXx>7E)4=jmSW-{#rAepryEXlo1$Z%9~K?6QO(O(9;t8RoY>?6*5IB+Gj0 zO9j1%^MPchS$_zo{naU^6S6Z6*rRa0c~4Ktw%>Q@#6Tt;rhDqiN=&8W@+vmB-`br> zDKVVdln_ZIVyAG{#kj>_w1O=AHC&q`)c^jGob~Og@kF zlG2L!!}h|V;`v@U!bP8(`;Ke%Ha?$YHxk@ye-bjY^sZL=fQ-aPK3u^&4+(!fXU+%} zypAu{BKz%#!Wn3V+87EU4+{l64T6-Atd`jt92Eokt-E_)X9KjD z0z2{gsql!5Z1c(H=dROMI0Dw^&vCB1C>c=uzmJmA@R1r|Fp}~-?3Zo4Mum@s$3a7s zpd?yKz27>$?l|tfI+7E(Ce7V)_y7m_ikK+x^EnQ?o_$$_#8KOk{E;_dL{}mLQaFn8 zM(=3enRnR-I1-kJ3vSxcJYm$_wTlrZJpnJg_!A9xcd- z!4K6TWNq|cFbyfx23F!ClxSZN(v2x%yDO&;hxW$OcFVhPz93W{o5nOJW2P!iS%vvR zXTPY`PCQPB`hrjIgFlISq0CHdzFmAm@HujjI6`ZLYpK2KrPrx0m4_~EcM&PJQ19?+KF4TY?9`q@LeZ?vSm(Jvyt77P@s2Wp-vfI+vmPt{|y`2n`D^odoa18ykJV(}fAID>41NOI*hR{9IJu z6!H?9+nJKw`x@15e-_$LN$=7P6yX#6l3UMLY3&E^D!pFP#`Km;e)hp`lCZYm6O*G|`qcVi z#W_>)xh?kdx(?BEa){ojcfA{>`DYqn#UFRPzO_dfuafA}A}d-(L^)T`5bSReSN0Rf zF%!H{XUCO?EK{-a{Ipz-T^3rSJe6kosbSiB;FXV?G^gvPXY0hG6rwes0<$vmTy*Im zBncJ`4@b3R))3wbjd~|dHpWtQb*my>0~pn9Eckv{ ztt(LbX3$fT>X8R*)yS6-n{9C(bf4U~1mM4fYH zB0Z2b_VIr&^EgI{o}hUMY!z0dpK5}QO}*JpU-33>ez8QX$5I&666m5BC}h{?3RFDt zcGp-6lqheVhV)Re?}TdJJ2Scq4%+5Rnr9@B*Y#E!V-0&rlV~x%tD+#3{gUHV5s%;- zvLMb@TLs&JGx45mLIqjA&&#xLy_#VhxIdG@QgaT2n-&(NrjbHm@**0(g}I59I?2i)8;^*+N&c+6hV|k22h9wr3M!DZI$xOjk<F7$(gU{lw6Xim>zWW#I9mt0qm4nmXRH1eyb1I zxC{%`<1xWJfa@AWmZVjX-F$11brlD;TsyHJZ>?}X9vC0ZT~!o7oTc5nSpXK$e;_4 zr^*FwQ9D~_6I*9}6%Tt8C*7xfOhwY590UtS=oKZfD_@&U+1@b9&|uA^gnS)x>RUVe zMRHc)$+s*T0|?=OsB}r*!<)9p`&J}zI;#i@v8mL{rE*iE#FVov%=f{{ zo$jz4+K{#5C%2Z&ny~GGr37EfC29EVV`{t4)?!eXS)`c~2Qs}V!qnDa2^`Z| z-;Rp$BU>-yzrZ{!31RUI%Q=_$@7T3DfoX0-oecKg6kVNz7(bGXKkKgk^bE*3VBlcHpjT+}fA!N(1^-?c@f2}> zwx<#2si%? z@K2VSNdFd}{v7C^f$Yi7PnOpH4*MTr?N2>_X0w0mAqSO;{abGPPYr+O?S5^EURkMI6u;`3v^@ZuZY1|Cw$6t-u5Ahl0P;_TL8m zR9y74J$bnIr-%PmKJ=&IKZ}i?us^+a{y(t4OOF(!p?@q^R8aLEEJ!Ys;tBVE00