diff --git a/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddAlign.ets b/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddAlign.ets index 78512711c2f104ca4493b4782faf74f1a516d708..ac4d827fa5354ca1bad65c1f8a6a0cdfc5861e8c 100644 --- a/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddAlign.ets +++ b/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddAlign.ets @@ -48,6 +48,5 @@ struct AlignStart_AddAlign { .align(this.DadAddAlign) } .width("100%") - .backgroundColor(0xAFEEE) } } diff --git a/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddAllSpace.ets b/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddAllSpace.ets index 8e05bd1b0f51efe00ce28af4a4c5b8ddaa2cced8..92d823097c999fb6c2561e29fd56895694174c5d 100644 --- a/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddAllSpace.ets +++ b/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddAllSpace.ets @@ -50,8 +50,6 @@ struct AlignStart_AddAllSpace { } .key("Start_AddAllSpace_01_Box") .width("100%") - .height(200) - .backgroundColor(0xAFEEE) .alignItems(HorizontalAlign.Start) } } \ No newline at end of file diff --git a/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddLayoutWeight.ets b/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddLayoutWeight.ets index 57db8d82693c6fbb0db4660647236b547c791921..0147963d1125d5b9b0ed70ff9e88ce2bded4f783 100644 --- a/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddLayoutWeight.ets +++ b/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddLayoutWeight.ets @@ -60,21 +60,6 @@ struct AlignStart_AddLayoutWeight { .width(500) .height(200) .backgroundColor(0xAFEEEE) - Flex({ justifyContent: this.justifyContent, direction: FlexDirection.Row }) { - Text('1') - .width(150) - .height(50) - .backgroundColor(0xF5DEB3) - .key("Start_AddLayoutWeight_021") - .layoutWeight(this.OneLayoutWeight1) - Text('2').width(150).height(100).backgroundColor(0xD2B48C).key("Start_AddLayoutWeight_022") - .layoutWeight(this.OneLayoutWeight2) - Text('3').width(150).height(150).backgroundColor(0xF5DEB3).key("Start_AddLayoutWeight_023") - } - .key("Start_AddLayoutWeight_02") - .width(500) - .height(200) - .backgroundColor(0xAFEEEE) } } } diff --git a/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddMargin.ets b/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddMargin.ets index 6aba30693f5c148057da9c2f77c7dd772c27fc2a..5f76f60d9c8f688a72534d00f171a04d6a05c480 100644 --- a/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddMargin.ets +++ b/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddMargin.ets @@ -48,8 +48,6 @@ struct AlignStart_AddMargin { } .key("Start_AddMargin_01_Box") .width("100%") - .height(200) - .backgroundColor(0xAFEEE) .alignItems(HorizontalAlign.Start) } } diff --git a/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddPadding.ets b/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddPadding.ets index 28927044e4c90b4c113484eaeb426c4812823676..6145b401e2d98df91709b665a42d80d09794c76d 100644 --- a/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddPadding.ets +++ b/arkui/ace_ets_layout_test/entry/src/main/ets/MainAbility/pages/Flex/justifyContent/Start/AlignStart_AddPadding.ets @@ -35,7 +35,7 @@ struct AlignStart_AddPadding { @State justifyContent: FlexAlign = FlexAlign.Start build() { Column() { - Text('alignContent:Start').fontSize(9).fontColor(0xCCCCCC).width('100%') + Text('justifyContent:FlexAlign.Start').fontSize(9).fontColor(0xCCCCCC).width('90%') Flex({ justifyContent: this.justifyContent, direction:FlexDirection.Row }) { Text('1').width(150).height(50).backgroundColor(0xF5DEB3).key("Start_AddPadding_011") Text('2').width(150).height(100).backgroundColor(0xD2B48C).key("Start_AddPadding_012") diff --git a/arkui/ace_ets_layout_test/entry/src/main/ets/test/Flex/justifyContent/Start/AlignStart_AddLayoutWeight.test.ets b/arkui/ace_ets_layout_test/entry/src/main/ets/test/Flex/justifyContent/Start/AlignStart_AddLayoutWeight.test.ets index 6fa0c6d205a506e812f152bc723aa424d54e0ebf..a5d23c16b491637c1de381ba36038309c0adbe4a 100644 --- a/arkui/ace_ets_layout_test/entry/src/main/ets/test/Flex/justifyContent/Start/AlignStart_AddLayoutWeight.test.ets +++ b/arkui/ace_ets_layout_test/entry/src/main/ets/test/Flex/justifyContent/Start/AlignStart_AddLayoutWeight.test.ets @@ -90,16 +90,17 @@ export default function AlignStart_AddLayoutWeight() { console.info('[SUB_ACE_FLEX_JUSTIFYCONTENT_FLEXALIGN_START_TEST_1600] START'); globalThis.value.message.notify({name:'OneLayoutWeight1', value:1}); globalThis.value.message.notify({name:'OneLayoutWeight2', value:2}); + globalThis.value.message.notify({name:'OneLayoutWeight3', value:0}); await CommonFunc.sleep(3000); let strJson = getInspectorByKey('Start_AddLayoutWeight_01'); let obj = JSON.parse(strJson); expect(obj.$type).assertEqual('Flex'); expect(obj.$attrs.constructor.direction).assertEqual('FlexDirection.Row'); expect(obj.$attrs.constructor.justifyContent).assertEqual('FlexAlign.Start'); - let Start_AddLayoutWeight_011 = CommonFunc.getComponentRect('Start_AddLayoutWeight_021'); - let Start_AddLayoutWeight_012 = CommonFunc.getComponentRect('Start_AddLayoutWeight_022'); - let Start_AddLayoutWeight_013 = CommonFunc.getComponentRect('Start_AddLayoutWeight_023'); - let Start_AddLayoutWeight_01 = CommonFunc.getComponentRect('Start_AddLayoutWeight_02'); + let Start_AddLayoutWeight_011 = CommonFunc.getComponentRect('Start_AddLayoutWeight_011'); + let Start_AddLayoutWeight_012 = CommonFunc.getComponentRect('Start_AddLayoutWeight_012'); + let Start_AddLayoutWeight_013 = CommonFunc.getComponentRect('Start_AddLayoutWeight_013'); + let Start_AddLayoutWeight_01 = CommonFunc.getComponentRect('Start_AddLayoutWeight_01'); expect(Start_AddLayoutWeight_011.top).assertEqual(Start_AddLayoutWeight_012.top); expect(Start_AddLayoutWeight_013.top).assertEqual(Start_AddLayoutWeight_012.top); expect(Start_AddLayoutWeight_011.top).assertEqual(Start_AddLayoutWeight_01.top); diff --git a/arkui/ace_ets_layout_test/entry/src/main/ets/test/Flex/justifyContent/Start/AlignStart_AddOneMargin.test.ets b/arkui/ace_ets_layout_test/entry/src/main/ets/test/Flex/justifyContent/Start/AlignStart_AddOneMargin.test.ets index 3fc1be33000259602b03f0bfc1925512f4b08fd4..2627bfbcd6591dc7468873ba5617e5a7c445db5f 100644 --- a/arkui/ace_ets_layout_test/entry/src/main/ets/test/Flex/justifyContent/Start/AlignStart_AddOneMargin.test.ets +++ b/arkui/ace_ets_layout_test/entry/src/main/ets/test/Flex/justifyContent/Start/AlignStart_AddOneMargin.test.ets @@ -103,12 +103,12 @@ export default function AlignStart_AddOneMargin() { expect(Start_AddOneMargin_01.top).assertEqual(Start_AddOneMargin_012.top); expect(Start_AddOneMargin_013.left).assertEqual(Start_AddOneMargin_012.right); expect(Start_AddOneMargin_013.right).assertEqual(Start_AddOneMargin_01.right); - expect(Start_AddOneMargin_012.left - Start_AddOneMargin_011.right).assertEqual(vp2px(30)); + expect(Start_AddOneMargin_012.left - Start_AddOneMargin_011.right).assertEqual(vp2px(500/17)); expect(Start_AddOneMargin_011.top - Start_AddOneMargin_01.top).assertEqual(vp2px(30)); - expect(Start_AddOneMargin_011.left - Start_AddOneMargin_01.left).assertEqual(vp2px(30)); - expect(Start_AddOneMargin_011.right - Start_AddOneMargin_011.left).assertEqual(vp2px(440/3)); - expect(Start_AddOneMargin_012.right - Start_AddOneMargin_012.left).assertEqual(vp2px(440/3)); - expect(Start_AddOneMargin_013.right - Start_AddOneMargin_013.left).assertEqual(vp2px(440/3)); + expect(Start_AddOneMargin_011.left - Start_AddOneMargin_01.left).assertEqual(vp2px(500/17)); + expect(Start_AddOneMargin_011.right - Start_AddOneMargin_011.left).assertEqual(vp2px(2500/17)); + expect(Start_AddOneMargin_012.right - Start_AddOneMargin_012.left).assertEqual(vp2px(2500/17)); + expect(Start_AddOneMargin_013.right - Start_AddOneMargin_013.left).assertEqual(vp2px(2500/17)); expect(Start_AddOneMargin_011.bottom - Start_AddOneMargin_011.top).assertEqual(vp2px(50)); expect(Start_AddOneMargin_012.bottom - Start_AddOneMargin_012.top).assertEqual(vp2px(100)); expect(Start_AddOneMargin_013.bottom - Start_AddOneMargin_013.top).assertEqual(vp2px(150));