From 016682df212722010a115156ba86ee0d973bae73 Mon Sep 17 00:00:00 2001 From: Swapnil Bhalgat Date: Tue, 17 Dec 2024 17:05:48 -0800 Subject: [PATCH 1/4] serialize Locked --- schemas/pa-yaml/v3.0/pa.schema.yaml | 2 + .../PaYaml/Models/SchemaV3/ControlInstance.cs | 2 + .../Examples/Src/Screens/FormsScreen2.pa.yaml | 57 +++++++++++++++++++ src/schemas/pa-yaml/v3.0/pa.schema.yaml | 2 + 4 files changed, 63 insertions(+) diff --git a/schemas/pa-yaml/v3.0/pa.schema.yaml b/schemas/pa-yaml/v3.0/pa.schema.yaml index d81680c5..2e19473e 100644 --- a/schemas/pa-yaml/v3.0/pa.schema.yaml +++ b/schemas/pa-yaml/v3.0/pa.schema.yaml @@ -212,6 +212,8 @@ definitions: Layout: type: string minLength: 1 + Locked: + type: boolean Group: true Properties: true Children: { $ref: "#/definitions/Children-Control-instance-sequence" } diff --git a/src/Persistence/PaYaml/Models/SchemaV3/ControlInstance.cs b/src/Persistence/PaYaml/Models/SchemaV3/ControlInstance.cs index f08da803..8d8c5777 100644 --- a/src/Persistence/PaYaml/Models/SchemaV3/ControlInstance.cs +++ b/src/Persistence/PaYaml/Models/SchemaV3/ControlInstance.cs @@ -28,6 +28,8 @@ public ControlInstance(string controlType) public string? Layout { get; init; } + public bool? Locked { get; init; } + /// /// The name of the group of controls that this control should be grouped with. /// This does not impact the visual layout of the control or behavior, but is used to group controls together for organizational purposes from within the Studio. diff --git a/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml b/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml index 6bc881bb..949910e6 100644 --- a/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml +++ b/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml @@ -46,6 +46,7 @@ Screens: Children: - "First Name_DataCard1": Control: TypedDataCard + Locked: true Variant: textualEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -65,6 +66,7 @@ Screens: Children: - DataCardKey7: Control: Label + Locked: true Properties: AutoHeight: =true Height: =34 @@ -76,6 +78,7 @@ Screens: - DataCardValue7: Control: TextInput + Locked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -94,6 +97,7 @@ Screens: - ErrorMessage5: Control: Label + Locked: true Properties: AutoHeight: =true Height: =10 @@ -110,6 +114,7 @@ Screens: - StarVisible5: Control: Label + Locked: true Properties: Align: =Align.Center Height: =DataCardKey7.Height @@ -121,6 +126,7 @@ Screens: - "Last Name_DataCard1": Control: TypedDataCard + Locked: true Variant: textualEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -140,6 +146,7 @@ Screens: Children: - DataCardKey9: Control: Label + Locked: true Properties: AutoHeight: =true Height: =34 @@ -151,6 +158,7 @@ Screens: - DataCardValue9: Control: TextInput + Locked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -169,6 +177,7 @@ Screens: - ErrorMessage7: Control: Label + Locked: true Properties: AutoHeight: =true Height: =10 @@ -185,6 +194,7 @@ Screens: - StarVisible7: Control: Label + Locked: true Properties: Align: =Align.Center Height: =DataCardKey9.Height @@ -196,6 +206,7 @@ Screens: - "Company Name_DataCard1": Control: TypedDataCard + Locked: true Variant: blankPolymorphicEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -212,6 +223,7 @@ Screens: - "Job Title_DataCard1": Control: TypedDataCard + Locked: true Variant: textualEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -231,6 +243,7 @@ Screens: Children: - DataCardKey8: Control: Label + Locked: true Properties: AutoHeight: =true Height: =34 @@ -242,6 +255,7 @@ Screens: - DataCardValue8: Control: TextInput + Locked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -260,6 +274,7 @@ Screens: - ErrorMessage6: Control: Label + Locked: true Properties: AutoHeight: =true Height: =10 @@ -276,6 +291,7 @@ Screens: - StarVisible6: Control: Label + Locked: true Properties: Align: =Align.Center Height: =DataCardKey8.Height @@ -287,6 +303,7 @@ Screens: - "Mobile Phone_DataCard1": Control: TypedDataCard + Locked: true Variant: textualEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -306,6 +323,7 @@ Screens: Children: - DataCardKey10: Control: Label + Locked: true Properties: AutoHeight: =true Height: =34 @@ -317,6 +335,7 @@ Screens: - DataCardValue10: Control: TextInput + Locked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -335,6 +354,7 @@ Screens: - ErrorMessage8: Control: Label + Locked: true Properties: AutoHeight: =true Height: =10 @@ -351,6 +371,7 @@ Screens: - StarVisible8: Control: Label + Locked: true Properties: Align: =Align.Center Height: =DataCardKey10.Height @@ -362,6 +383,7 @@ Screens: - "User Name_DataCard1": Control: TypedDataCard + Locked: true Variant: textualEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -381,6 +403,7 @@ Screens: Children: - DataCardKey12: Control: Label + Locked: true Properties: AutoHeight: =true Height: =34 @@ -392,6 +415,7 @@ Screens: - DataCardValue12: Control: TextInput + Locked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -410,6 +434,7 @@ Screens: - ErrorMessage10: Control: Label + Locked: true Properties: AutoHeight: =true Height: =10 @@ -426,6 +451,7 @@ Screens: - StarVisible10: Control: Label + Locked: true Properties: Align: =Align.Center Height: =DataCardKey12.Height @@ -437,6 +463,7 @@ Screens: - "Address 1_DataCard1": Control: TypedDataCard + Locked: true Variant: textualViewCard Properties: BorderStyle: =BorderStyle.Solid @@ -454,6 +481,7 @@ Screens: Children: - DataCardKey4: Control: Label + Locked: true Properties: AutoHeight: =true Height: =34 @@ -465,6 +493,7 @@ Screens: - DataCardValue4: Control: Label + Locked: true Properties: AutoHeight: =true DisplayMode: =Parent.DisplayMode @@ -479,6 +508,7 @@ Screens: - Website_DataCard1: Control: TypedDataCard + Locked: true Variant: urlEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -497,6 +527,7 @@ Screens: Children: - DataCardKey11: Control: Label + Locked: true Properties: AutoHeight: =true Height: =34 @@ -508,6 +539,7 @@ Screens: - DataCardValue11: Control: TextInput + Locked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -525,6 +557,7 @@ Screens: - ErrorMessage9: Control: Label + Locked: true Properties: AutoHeight: =true Height: =10 @@ -541,6 +574,7 @@ Screens: - StarVisible9: Control: Label + Locked: true Properties: Align: =Align.Center Height: =DataCardKey11.Height @@ -552,6 +586,7 @@ Screens: - Birthday_DataCard1: Control: TypedDataCard + Locked: true Variant: dateEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -570,6 +605,7 @@ Screens: Children: - DataCardKey5: Control: Label + Locked: true Properties: AutoHeight: =true Height: =34 @@ -581,6 +617,7 @@ Screens: - DataCardValue5: Control: DatePicker + Locked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) DefaultDate: =Parent.Default @@ -597,6 +634,7 @@ Screens: - ErrorMessage3: Control: Label + Locked: true Properties: AutoHeight: =true Height: =10 @@ -613,6 +651,7 @@ Screens: - StarVisible3: Control: Label + Locked: true Properties: Align: =Align.Center Height: =DataCardKey5.Height @@ -624,6 +663,7 @@ Screens: - Description_DataCard1: Control: TypedDataCard + Locked: true Variant: textualMultiLineEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -642,6 +682,7 @@ Screens: Children: - DataCardKey6: Control: Label + Locked: true Properties: AutoHeight: =true Height: =34 @@ -653,6 +694,7 @@ Screens: - DataCardValue6: Control: TextInput + Locked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -672,6 +714,7 @@ Screens: - ErrorMessage4: Control: Label + Locked: true Properties: AutoHeight: =true Height: =10 @@ -688,6 +731,7 @@ Screens: - StarVisible4: Control: Label + Locked: true Properties: Align: =Align.Center Height: =DataCardKey6.Height @@ -699,6 +743,7 @@ Screens: - "Full Name_DataCard1": Control: TypedDataCard + Locked: true Variant: textualViewCard Properties: BorderStyle: =BorderStyle.Solid @@ -716,6 +761,7 @@ Screens: Children: - DataCardKey1: Control: Label + Locked: true Properties: AutoHeight: =true Height: =34 @@ -727,6 +773,7 @@ Screens: - DataCardValue1: Control: Label + Locked: true Properties: AutoHeight: =true DisplayMode: =Parent.DisplayMode @@ -741,6 +788,7 @@ Screens: - Email_DataCard1: Control: TypedDataCard + Locked: true Variant: textualEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -760,6 +808,7 @@ Screens: Children: - DataCardKey2: Control: Label + Locked: true Properties: AutoHeight: =true Height: =34 @@ -771,6 +820,7 @@ Screens: - DataCardValue2: Control: TextInput + Locked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -789,6 +839,7 @@ Screens: - ErrorMessage1: Control: Label + Locked: true Properties: AutoHeight: =true Height: =10 @@ -805,6 +856,7 @@ Screens: - StarVisible1: Control: Label + Locked: true Properties: Align: =Align.Center Height: =DataCardKey2.Height @@ -816,6 +868,7 @@ Screens: - "Business Phone_DataCard1": Control: TypedDataCard + Locked: true Variant: textualEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -835,6 +888,7 @@ Screens: Children: - DataCardKey3: Control: Label + Locked: true Properties: AutoHeight: =true Height: =34 @@ -846,6 +900,7 @@ Screens: - DataCardValue3: Control: TextInput + Locked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -864,6 +919,7 @@ Screens: - ErrorMessage2: Control: Label + Locked: true Properties: AutoHeight: =true Height: =10 @@ -880,6 +936,7 @@ Screens: - StarVisible2: Control: Label + Locked: true Properties: Align: =Align.Center Height: =DataCardKey3.Height diff --git a/src/schemas/pa-yaml/v3.0/pa.schema.yaml b/src/schemas/pa-yaml/v3.0/pa.schema.yaml index f5de31de..60b74371 100644 --- a/src/schemas/pa-yaml/v3.0/pa.schema.yaml +++ b/src/schemas/pa-yaml/v3.0/pa.schema.yaml @@ -233,6 +233,8 @@ definitions: Layout: type: string minLength: 1 + Locked: + type: boolean Group: true Properties: true Children: { $ref: "#/definitions/Children-Control-instance-sequence" } From 55d3839b3000e56930372a7c548b4f64f7bb4e55 Mon Sep 17 00:00:00 2001 From: Swapnil Bhalgat Date: Tue, 17 Dec 2024 19:04:00 -0800 Subject: [PATCH 2/4] rename Locked to IsLocked --- schemas/pa-yaml/v3.0/pa.schema.yaml | 2 +- .../PaYaml/Models/SchemaV3/ControlInstance.cs | 2 +- .../Examples/Src/Screens/FormsScreen2.pa.yaml | 114 +++++++++--------- src/schemas/pa-yaml/v3.0/pa.schema.yaml | 2 +- 4 files changed, 60 insertions(+), 60 deletions(-) diff --git a/schemas/pa-yaml/v3.0/pa.schema.yaml b/schemas/pa-yaml/v3.0/pa.schema.yaml index 2e19473e..55aafbc2 100644 --- a/schemas/pa-yaml/v3.0/pa.schema.yaml +++ b/schemas/pa-yaml/v3.0/pa.schema.yaml @@ -212,7 +212,7 @@ definitions: Layout: type: string minLength: 1 - Locked: + IsLocked: type: boolean Group: true Properties: true diff --git a/src/Persistence/PaYaml/Models/SchemaV3/ControlInstance.cs b/src/Persistence/PaYaml/Models/SchemaV3/ControlInstance.cs index 8d8c5777..919e3162 100644 --- a/src/Persistence/PaYaml/Models/SchemaV3/ControlInstance.cs +++ b/src/Persistence/PaYaml/Models/SchemaV3/ControlInstance.cs @@ -28,7 +28,7 @@ public ControlInstance(string controlType) public string? Layout { get; init; } - public bool? Locked { get; init; } + public bool? IsLocked { get; init; } /// /// The name of the group of controls that this control should be grouped with. diff --git a/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml b/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml index 949910e6..42580bb5 100644 --- a/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml +++ b/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml @@ -46,7 +46,7 @@ Screens: Children: - "First Name_DataCard1": Control: TypedDataCard - Locked: true + IsLocked: true Variant: textualEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -66,7 +66,7 @@ Screens: Children: - DataCardKey7: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -78,7 +78,7 @@ Screens: - DataCardValue7: Control: TextInput - Locked: true + IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -97,7 +97,7 @@ Screens: - ErrorMessage5: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -114,7 +114,7 @@ Screens: - StarVisible5: Control: Label - Locked: true + IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey7.Height @@ -126,7 +126,7 @@ Screens: - "Last Name_DataCard1": Control: TypedDataCard - Locked: true + IsLocked: true Variant: textualEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -146,7 +146,7 @@ Screens: Children: - DataCardKey9: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -158,7 +158,7 @@ Screens: - DataCardValue9: Control: TextInput - Locked: true + IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -177,7 +177,7 @@ Screens: - ErrorMessage7: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -194,7 +194,7 @@ Screens: - StarVisible7: Control: Label - Locked: true + IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey9.Height @@ -206,7 +206,7 @@ Screens: - "Company Name_DataCard1": Control: TypedDataCard - Locked: true + IsLocked: true Variant: blankPolymorphicEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -223,7 +223,7 @@ Screens: - "Job Title_DataCard1": Control: TypedDataCard - Locked: true + IsLocked: true Variant: textualEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -243,7 +243,7 @@ Screens: Children: - DataCardKey8: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -255,7 +255,7 @@ Screens: - DataCardValue8: Control: TextInput - Locked: true + IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -274,7 +274,7 @@ Screens: - ErrorMessage6: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -291,7 +291,7 @@ Screens: - StarVisible6: Control: Label - Locked: true + IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey8.Height @@ -303,7 +303,7 @@ Screens: - "Mobile Phone_DataCard1": Control: TypedDataCard - Locked: true + IsLocked: true Variant: textualEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -323,7 +323,7 @@ Screens: Children: - DataCardKey10: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -335,7 +335,7 @@ Screens: - DataCardValue10: Control: TextInput - Locked: true + IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -354,7 +354,7 @@ Screens: - ErrorMessage8: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -371,7 +371,7 @@ Screens: - StarVisible8: Control: Label - Locked: true + IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey10.Height @@ -383,7 +383,7 @@ Screens: - "User Name_DataCard1": Control: TypedDataCard - Locked: true + IsLocked: true Variant: textualEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -403,7 +403,7 @@ Screens: Children: - DataCardKey12: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -415,7 +415,7 @@ Screens: - DataCardValue12: Control: TextInput - Locked: true + IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -434,7 +434,7 @@ Screens: - ErrorMessage10: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -451,7 +451,7 @@ Screens: - StarVisible10: Control: Label - Locked: true + IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey12.Height @@ -463,7 +463,7 @@ Screens: - "Address 1_DataCard1": Control: TypedDataCard - Locked: true + IsLocked: true Variant: textualViewCard Properties: BorderStyle: =BorderStyle.Solid @@ -481,7 +481,7 @@ Screens: Children: - DataCardKey4: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -493,7 +493,7 @@ Screens: - DataCardValue4: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true DisplayMode: =Parent.DisplayMode @@ -508,7 +508,7 @@ Screens: - Website_DataCard1: Control: TypedDataCard - Locked: true + IsLocked: true Variant: urlEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -527,7 +527,7 @@ Screens: Children: - DataCardKey11: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -539,7 +539,7 @@ Screens: - DataCardValue11: Control: TextInput - Locked: true + IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -557,7 +557,7 @@ Screens: - ErrorMessage9: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -574,7 +574,7 @@ Screens: - StarVisible9: Control: Label - Locked: true + IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey11.Height @@ -586,7 +586,7 @@ Screens: - Birthday_DataCard1: Control: TypedDataCard - Locked: true + IsLocked: true Variant: dateEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -605,7 +605,7 @@ Screens: Children: - DataCardKey5: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -617,7 +617,7 @@ Screens: - DataCardValue5: Control: DatePicker - Locked: true + IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) DefaultDate: =Parent.Default @@ -634,7 +634,7 @@ Screens: - ErrorMessage3: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -651,7 +651,7 @@ Screens: - StarVisible3: Control: Label - Locked: true + IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey5.Height @@ -663,7 +663,7 @@ Screens: - Description_DataCard1: Control: TypedDataCard - Locked: true + IsLocked: true Variant: textualMultiLineEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -682,7 +682,7 @@ Screens: Children: - DataCardKey6: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -694,7 +694,7 @@ Screens: - DataCardValue6: Control: TextInput - Locked: true + IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -714,7 +714,7 @@ Screens: - ErrorMessage4: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -731,7 +731,7 @@ Screens: - StarVisible4: Control: Label - Locked: true + IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey6.Height @@ -743,7 +743,7 @@ Screens: - "Full Name_DataCard1": Control: TypedDataCard - Locked: true + IsLocked: true Variant: textualViewCard Properties: BorderStyle: =BorderStyle.Solid @@ -761,7 +761,7 @@ Screens: Children: - DataCardKey1: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -773,7 +773,7 @@ Screens: - DataCardValue1: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true DisplayMode: =Parent.DisplayMode @@ -788,7 +788,7 @@ Screens: - Email_DataCard1: Control: TypedDataCard - Locked: true + IsLocked: true Variant: textualEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -808,7 +808,7 @@ Screens: Children: - DataCardKey2: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -820,7 +820,7 @@ Screens: - DataCardValue2: Control: TextInput - Locked: true + IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -839,7 +839,7 @@ Screens: - ErrorMessage1: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -856,7 +856,7 @@ Screens: - StarVisible1: Control: Label - Locked: true + IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey2.Height @@ -868,7 +868,7 @@ Screens: - "Business Phone_DataCard1": Control: TypedDataCard - Locked: true + IsLocked: true Variant: textualEditCard Properties: BorderStyle: =BorderStyle.Solid @@ -888,7 +888,7 @@ Screens: Children: - DataCardKey3: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -900,7 +900,7 @@ Screens: - DataCardValue3: Control: TextInput - Locked: true + IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -919,7 +919,7 @@ Screens: - ErrorMessage2: Control: Label - Locked: true + IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -936,7 +936,7 @@ Screens: - StarVisible2: Control: Label - Locked: true + IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey3.Height diff --git a/src/schemas/pa-yaml/v3.0/pa.schema.yaml b/src/schemas/pa-yaml/v3.0/pa.schema.yaml index 60b74371..6880af06 100644 --- a/src/schemas/pa-yaml/v3.0/pa.schema.yaml +++ b/src/schemas/pa-yaml/v3.0/pa.schema.yaml @@ -233,7 +233,7 @@ definitions: Layout: type: string minLength: 1 - Locked: + IsLocked: type: boolean Group: true Properties: true From a137822505f440bbf955fbfe1de20dadbc5ac582 Mon Sep 17 00:00:00 2001 From: Swapnil Bhalgat Date: Wed, 18 Dec 2024 11:26:05 -0800 Subject: [PATCH 3/4] remove isLocked from children --- .../Examples/Src/Screens/FormsScreen2.pa.yaml | 44 ------------------- 1 file changed, 44 deletions(-) diff --git a/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml b/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml index 42580bb5..457517a0 100644 --- a/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml +++ b/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml @@ -66,7 +66,6 @@ Screens: Children: - DataCardKey7: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -78,7 +77,6 @@ Screens: - DataCardValue7: Control: TextInput - IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -97,7 +95,6 @@ Screens: - ErrorMessage5: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -114,7 +111,6 @@ Screens: - StarVisible5: Control: Label - IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey7.Height @@ -146,7 +142,6 @@ Screens: Children: - DataCardKey9: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -158,7 +153,6 @@ Screens: - DataCardValue9: Control: TextInput - IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -177,7 +171,6 @@ Screens: - ErrorMessage7: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -194,7 +187,6 @@ Screens: - StarVisible7: Control: Label - IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey9.Height @@ -243,7 +235,6 @@ Screens: Children: - DataCardKey8: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -255,7 +246,6 @@ Screens: - DataCardValue8: Control: TextInput - IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -274,7 +264,6 @@ Screens: - ErrorMessage6: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -291,7 +280,6 @@ Screens: - StarVisible6: Control: Label - IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey8.Height @@ -323,7 +311,6 @@ Screens: Children: - DataCardKey10: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -335,7 +322,6 @@ Screens: - DataCardValue10: Control: TextInput - IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -354,7 +340,6 @@ Screens: - ErrorMessage8: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -371,7 +356,6 @@ Screens: - StarVisible8: Control: Label - IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey10.Height @@ -403,7 +387,6 @@ Screens: Children: - DataCardKey12: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -415,7 +398,6 @@ Screens: - DataCardValue12: Control: TextInput - IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -434,7 +416,6 @@ Screens: - ErrorMessage10: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -451,7 +432,6 @@ Screens: - StarVisible10: Control: Label - IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey12.Height @@ -481,7 +461,6 @@ Screens: Children: - DataCardKey4: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -493,7 +472,6 @@ Screens: - DataCardValue4: Control: Label - IsLocked: true Properties: AutoHeight: =true DisplayMode: =Parent.DisplayMode @@ -527,7 +505,6 @@ Screens: Children: - DataCardKey11: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -539,7 +516,6 @@ Screens: - DataCardValue11: Control: TextInput - IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -557,7 +533,6 @@ Screens: - ErrorMessage9: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -574,7 +549,6 @@ Screens: - StarVisible9: Control: Label - IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey11.Height @@ -605,7 +579,6 @@ Screens: Children: - DataCardKey5: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -617,7 +590,6 @@ Screens: - DataCardValue5: Control: DatePicker - IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) DefaultDate: =Parent.Default @@ -634,7 +606,6 @@ Screens: - ErrorMessage3: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -651,7 +622,6 @@ Screens: - StarVisible3: Control: Label - IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey5.Height @@ -682,7 +652,6 @@ Screens: Children: - DataCardKey6: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -694,7 +663,6 @@ Screens: - DataCardValue6: Control: TextInput - IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -714,7 +682,6 @@ Screens: - ErrorMessage4: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -731,7 +698,6 @@ Screens: - StarVisible4: Control: Label - IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey6.Height @@ -761,7 +727,6 @@ Screens: Children: - DataCardKey1: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -773,7 +738,6 @@ Screens: - DataCardValue1: Control: Label - IsLocked: true Properties: AutoHeight: =true DisplayMode: =Parent.DisplayMode @@ -808,7 +772,6 @@ Screens: Children: - DataCardKey2: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -820,7 +783,6 @@ Screens: - DataCardValue2: Control: TextInput - IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -839,7 +801,6 @@ Screens: - ErrorMessage1: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -856,7 +817,6 @@ Screens: - StarVisible1: Control: Label - IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey2.Height @@ -888,7 +848,6 @@ Screens: Children: - DataCardKey3: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =34 @@ -900,7 +859,6 @@ Screens: - DataCardValue3: Control: TextInput - IsLocked: true Properties: BorderColor: =If(IsBlank(Parent.Error), Parent.BorderColor, Color.Red) Default: =Parent.Default @@ -919,7 +877,6 @@ Screens: - ErrorMessage2: Control: Label - IsLocked: true Properties: AutoHeight: =true Height: =10 @@ -936,7 +893,6 @@ Screens: - StarVisible2: Control: Label - IsLocked: true Properties: Align: =Align.Center Height: =DataCardKey3.Height From 8d7554b6563ba44ca060ea417a8eef6877e9b97a Mon Sep 17 00:00:00 2001 From: Swapnil Bhalgat Date: Wed, 18 Dec 2024 12:37:29 -0800 Subject: [PATCH 4/4] move IsLocked after variant and text json version update --- ...rosoft.PowerPlatform.Formulas.Tools.csproj | 4 +- src/PAModel/packages.lock.json | 69 ++++++++++--------- .../Examples/Src/Screens/FormsScreen2.pa.yaml | 26 +++---- 3 files changed, 53 insertions(+), 46 deletions(-) diff --git a/src/PAModel/Microsoft.PowerPlatform.Formulas.Tools.csproj b/src/PAModel/Microsoft.PowerPlatform.Formulas.Tools.csproj index 213c4f39..e3aeb9a5 100644 --- a/src/PAModel/Microsoft.PowerPlatform.Formulas.Tools.csproj +++ b/src/PAModel/Microsoft.PowerPlatform.Formulas.Tools.csproj @@ -54,8 +54,8 @@ - - + + diff --git a/src/PAModel/packages.lock.json b/src/PAModel/packages.lock.json index 7d21cb1c..c42046cf 100644 --- a/src/PAModel/packages.lock.json +++ b/src/PAModel/packages.lock.json @@ -19,27 +19,27 @@ }, "System.Text.Encodings.Web": { "type": "Direct", - "requested": "[6.0.0, )", - "resolved": "6.0.0", - "contentHash": "Vg8eB5Tawm1IFqj4TVK1czJX89rhFxJo9ELqc/Eiq0eXy13RK00eubyU6TJE6y+GQXjyV5gSfiewDUZjQgSE0w==", + "requested": "[9.0.0, )", + "resolved": "9.0.0", + "contentHash": "e2hMgAErLbKyUUwt18qSBf9T5Y+SFAL3ZedM8fLupkVj8Rj2PZ9oxQ37XX2LF8fTO1wNIxvKpihD7Of7D/NxZw==", "dependencies": { "System.Buffers": "4.5.1", - "System.Memory": "4.5.4", + "System.Memory": "4.5.5", "System.Runtime.CompilerServices.Unsafe": "6.0.0" } }, "System.Text.Json": { "type": "Direct", - "requested": "[6.0.0, )", - "resolved": "6.0.0", - "contentHash": "zaJsHfESQvJ11vbXnNlkrR46IaMULk/gHxYsJphzSF+07kTjPHv+Oc14w6QEOfo3Q4hqLJgStUaYB9DBl0TmWg==", + "requested": "[9.0.0, )", + "resolved": "9.0.0", + "contentHash": "js7+qAu/9mQvnhA4EfGMZNEzXtJCDxgkgj8ohuxq/Qxv+R56G+ljefhiJHOxTNiw54q8vmABCWUwkMulNdlZ4A==", "dependencies": { - "Microsoft.Bcl.AsyncInterfaces": "6.0.0", + "Microsoft.Bcl.AsyncInterfaces": "9.0.0", "System.Buffers": "4.5.1", - "System.Memory": "4.5.4", - "System.Numerics.Vectors": "4.5.0", + "System.IO.Pipelines": "9.0.0", + "System.Memory": "4.5.5", "System.Runtime.CompilerServices.Unsafe": "6.0.0", - "System.Text.Encodings.Web": "6.0.0", + "System.Text.Encodings.Web": "9.0.0", "System.Threading.Tasks.Extensions": "4.5.4" } }, @@ -51,8 +51,8 @@ }, "Microsoft.Bcl.AsyncInterfaces": { "type": "Transitive", - "resolved": "6.0.0", - "contentHash": "UcSjPsst+DfAdJGVDsu346FX0ci0ah+lw3WRtn18NUwEqRt70HaOQ7lI72vy3+1LxtqI3T5GWwV39rQSrCzAeg==", + "resolved": "9.0.0", + "contentHash": "owmu2Cr3IQ8yQiBleBHlGk8dSQ12oaF2e7TpzwJKEl4m84kkZJjEY1n33L67Y3zM5jPOjmmbdHjbfiL0RqcMRQ==", "dependencies": { "System.Threading.Tasks.Extensions": "4.5.4" } @@ -67,10 +67,20 @@ "resolved": "4.5.1", "contentHash": "Rw7ijyl1qqRS0YQD/WycNst8hUUMgrMH4FCn1nNm27M4VxchZ1js3fVjQaANHO5f3sN4isvP4a+Met9Y4YomAg==" }, + "System.IO.Pipelines": { + "type": "Transitive", + "resolved": "9.0.0", + "contentHash": "eA3cinogwaNB4jdjQHOP3Z3EuyiDII7MT35jgtnsA4vkn0LUrrSHsU0nzHTzFzmaFYeKV7MYyMxOocFzsBHpTw==", + "dependencies": { + "System.Buffers": "4.5.1", + "System.Memory": "4.5.5", + "System.Threading.Tasks.Extensions": "4.5.4" + } + }, "System.Memory": { "type": "Transitive", - "resolved": "4.5.4", - "contentHash": "1MbJTHS1lZ4bS4FmsJjnuGJOu88ZzTT2rLvrhW7Ygic+pC0NWA+3hgAen0HRdsocuQXCkUTdFn9yHJJhsijDXw==", + "resolved": "4.5.5", + "contentHash": "XIWiDvKPXaTveaB7HVganDlOCRoj03l+jrwNvcge/t8vhGYKvqV+dMv6G4SAX2NoNmN0wZfVPTAlFwZcZvVOUw==", "dependencies": { "System.Buffers": "4.5.1", "System.Numerics.Vectors": "4.4.0", @@ -79,8 +89,8 @@ }, "System.Numerics.Vectors": { "type": "Transitive", - "resolved": "4.5.0", - "contentHash": "QQTlPTl06J/iiDbJCiepZ4H//BVraReU4O4EoRw1U02H5TLUIT7xn3GnDp9AXPSlJUDyFs4uWjWafNX6WrAojQ==" + "resolved": "4.4.0", + "contentHash": "UiLzLW+Lw6HLed1Hcg+8jSRttrbuXv7DANVj0DkL9g6EnnzbL75EB7EWsw5uRbhxd/4YdG8li5XizGWepmG3PQ==" }, "System.Runtime.CompilerServices.Unsafe": { "type": "Transitive", @@ -105,21 +115,18 @@ }, "System.Text.Encodings.Web": { "type": "Direct", - "requested": "[6.0.0, )", - "resolved": "6.0.0", - "contentHash": "Vg8eB5Tawm1IFqj4TVK1czJX89rhFxJo9ELqc/Eiq0eXy13RK00eubyU6TJE6y+GQXjyV5gSfiewDUZjQgSE0w==", - "dependencies": { - "System.Runtime.CompilerServices.Unsafe": "6.0.0" - } + "requested": "[9.0.0, )", + "resolved": "9.0.0", + "contentHash": "e2hMgAErLbKyUUwt18qSBf9T5Y+SFAL3ZedM8fLupkVj8Rj2PZ9oxQ37XX2LF8fTO1wNIxvKpihD7Of7D/NxZw==" }, "System.Text.Json": { "type": "Direct", - "requested": "[6.0.0, )", - "resolved": "6.0.0", - "contentHash": "zaJsHfESQvJ11vbXnNlkrR46IaMULk/gHxYsJphzSF+07kTjPHv+Oc14w6QEOfo3Q4hqLJgStUaYB9DBl0TmWg==", + "requested": "[9.0.0, )", + "resolved": "9.0.0", + "contentHash": "js7+qAu/9mQvnhA4EfGMZNEzXtJCDxgkgj8ohuxq/Qxv+R56G+ljefhiJHOxTNiw54q8vmABCWUwkMulNdlZ4A==", "dependencies": { - "System.Runtime.CompilerServices.Unsafe": "6.0.0", - "System.Text.Encodings.Web": "6.0.0" + "System.IO.Pipelines": "9.0.0", + "System.Text.Encodings.Web": "9.0.0" } }, "YamlDotNet": { @@ -128,10 +135,10 @@ "resolved": "15.1.6", "contentHash": "T/cQEK/KHK96Q8kytJ4iUGDXg1/fj2Qtk6rCQeIlHYU1zTeyGVHW0QNZgREQyxZpygGMDMmrXNWt0sj5TsQnjA==" }, - "System.Runtime.CompilerServices.Unsafe": { + "System.IO.Pipelines": { "type": "Transitive", - "resolved": "6.0.0", - "contentHash": "/iUeP3tq1S0XdNNoMz5C9twLSrM/TH+qElHkXWaPvuNOt+99G75NrV0OS2EqHx5wMN7popYjpc8oTjC1y16DLg==" + "resolved": "9.0.0", + "contentHash": "eA3cinogwaNB4jdjQHOP3Z3EuyiDII7MT35jgtnsA4vkn0LUrrSHsU0nzHTzFzmaFYeKV7MYyMxOocFzsBHpTw==" } } } diff --git a/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml b/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml index 457517a0..5079bd2c 100644 --- a/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml +++ b/src/schemas-tests/pa-yaml/v3.0/Examples/Src/Screens/FormsScreen2.pa.yaml @@ -46,8 +46,8 @@ Screens: Children: - "First Name_DataCard1": Control: TypedDataCard - IsLocked: true Variant: textualEditCard + IsLocked: true Properties: BorderStyle: =BorderStyle.Solid DataField: ="firstname" @@ -122,8 +122,8 @@ Screens: - "Last Name_DataCard1": Control: TypedDataCard - IsLocked: true Variant: textualEditCard + IsLocked: true Properties: BorderStyle: =BorderStyle.Solid DataField: ="lastname" @@ -198,8 +198,8 @@ Screens: - "Company Name_DataCard1": Control: TypedDataCard - IsLocked: true Variant: blankPolymorphicEditCard + IsLocked: true Properties: BorderStyle: =BorderStyle.Solid DataField: ="_parentcustomerid_value" @@ -215,8 +215,8 @@ Screens: - "Job Title_DataCard1": Control: TypedDataCard - IsLocked: true Variant: textualEditCard + IsLocked: true Properties: BorderStyle: =BorderStyle.Solid DataField: ="jobtitle" @@ -291,8 +291,8 @@ Screens: - "Mobile Phone_DataCard1": Control: TypedDataCard - IsLocked: true Variant: textualEditCard + IsLocked: true Properties: BorderStyle: =BorderStyle.Solid DataField: ="mobilephone" @@ -367,8 +367,8 @@ Screens: - "User Name_DataCard1": Control: TypedDataCard - IsLocked: true Variant: textualEditCard + IsLocked: true Properties: BorderStyle: =BorderStyle.Solid DataField: ="adx_identity_username" @@ -443,8 +443,8 @@ Screens: - "Address 1_DataCard1": Control: TypedDataCard - IsLocked: true Variant: textualViewCard + IsLocked: true Properties: BorderStyle: =BorderStyle.Solid DataField: ="address1_composite" @@ -486,8 +486,8 @@ Screens: - Website_DataCard1: Control: TypedDataCard - IsLocked: true Variant: urlEditCard + IsLocked: true Properties: BorderStyle: =BorderStyle.Solid DataField: ="websiteurl" @@ -560,8 +560,8 @@ Screens: - Birthday_DataCard1: Control: TypedDataCard - IsLocked: true Variant: dateEditCard + IsLocked: true Properties: BorderStyle: =BorderStyle.Solid DataField: ="birthdate" @@ -633,8 +633,8 @@ Screens: - Description_DataCard1: Control: TypedDataCard - IsLocked: true Variant: textualMultiLineEditCard + IsLocked: true Properties: BorderStyle: =BorderStyle.Solid DataField: ="description" @@ -709,8 +709,8 @@ Screens: - "Full Name_DataCard1": Control: TypedDataCard - IsLocked: true Variant: textualViewCard + IsLocked: true Properties: BorderStyle: =BorderStyle.Solid DataField: ="fullname" @@ -752,8 +752,8 @@ Screens: - Email_DataCard1: Control: TypedDataCard - IsLocked: true Variant: textualEditCard + IsLocked: true Properties: BorderStyle: =BorderStyle.Solid DataField: ="emailaddress1" @@ -828,8 +828,8 @@ Screens: - "Business Phone_DataCard1": Control: TypedDataCard - IsLocked: true Variant: textualEditCard + IsLocked: true Properties: BorderStyle: =BorderStyle.Solid DataField: ="telephone1"