From 37c67bd1da070f65bf0641e4a31c4976dfe8d739 Mon Sep 17 00:00:00 2001 From: Keeyou Date: Wed, 20 Mar 2024 16:37:48 +0800 Subject: [PATCH] harmony: fix display layout --- harmony/entry/src/main/ets/view/DetailListComponent.ets | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/harmony/entry/src/main/ets/view/DetailListComponent.ets b/harmony/entry/src/main/ets/view/DetailListComponent.ets index f556a8aec..b43d4813c 100644 --- a/harmony/entry/src/main/ets/view/DetailListComponent.ets +++ b/harmony/entry/src/main/ets/view/DetailListComponent.ets @@ -18,6 +18,7 @@ export struct DetailListComponent { Text($r('app.string.server_host')) .fontSize($r('app.float.name_text_size')) .fontColor($r('app.color.text')) + .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT) Blank() TextInput({text: this.dataItem.serverHost}) .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT) @@ -33,6 +34,7 @@ export struct DetailListComponent { Text($r('app.string.server_sni')) .fontSize($r('app.float.name_text_size')) .fontColor($r('app.color.text')) + .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT) Blank() TextInput({text: this.dataItem.serverSNI}) .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT) @@ -48,6 +50,7 @@ export struct DetailListComponent { Text($r('app.string.server_port')) .fontSize($r('app.float.name_text_size')) .fontColor($r('app.color.text')) + .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT) Blank() TextInput({text: this.dataItem.serverPort.toString()}) .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT) @@ -64,6 +67,7 @@ export struct DetailListComponent { Text($r('app.string.username')) .fontSize($r('app.float.name_text_size')) .fontColor($r('app.color.text')) + .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT) Blank() TextInput({text: this.dataItem.username}) .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT) @@ -79,6 +83,7 @@ export struct DetailListComponent { Text($r('app.string.password')) .fontSize($r('app.float.name_text_size')) .fontColor($r('app.color.text')) + .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT) Blank() TextInput({text: this.dataItem.password}) .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT) @@ -95,6 +100,7 @@ export struct DetailListComponent { Text($r('app.string.cipher')) .fontSize($r('app.float.name_text_size')) .fontColor($r('app.color.text')) + .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT) Blank() TextPicker({range: yass.getCipherStrings(), selected: yass.getCipherStrings().indexOf(this.dataItem.cipher)}) .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT) @@ -109,6 +115,7 @@ export struct DetailListComponent { Text($r('app.string.doh_url')) .fontSize($r('app.float.name_text_size')) .fontColor($r('app.color.text')) + .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT) Blank() TextInput({text: this.dataItem.dohUrl}) .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT) @@ -124,6 +131,7 @@ export struct DetailListComponent { Text($r('app.string.timeout')) .fontSize($r('app.float.name_text_size')) .fontColor($r('app.color.text')) + .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT) Blank() TextInput({text: this.dataItem.timeout.toString()}) .width(CommonConstants.DETAIL_INPUT_WIDTH_PERCENT)