This repository was archived by the owner on Jun 27, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 6 files changed +16
-8
lines changed Expand file tree Collapse file tree 6 files changed +16
-8
lines changed Original file line number Diff line number Diff line change @@ -97,6 +97,7 @@ export default defineComponent({
9797 ' color' ,
9898 ' customField1' ,
9999 ' customStyles' ,
100+ ' readonly' ,
100101 ],
101102 fields: {
102103 name: {
@@ -109,16 +110,10 @@ export default defineComponent({
109110 label: ' Email' ,
110111 type: ' email' ,
111112 validations: [emailValidator ],
112- /* customClass: 'active text-red', */
113113 customClass: {
114114 active: true ,
115115 ' text-blue' : true ,
116116 },
117- /* customClass: {
118- active: true,
119- 'text-blue': true,
120- }, */
121- /* customClass: ['active', 'text-red'], */
122117 } as EmailInput ,
123118 password: {
124119 label: ' Password' ,
@@ -208,6 +203,12 @@ export default defineComponent({
208203 border: ' 1px solid teal' ,
209204 },
210205 } as TextInput ,
206+ readonly: {
207+ label: ' Readonly' ,
208+ type: ' text' ,
209+ value: ' Alvaro' ,
210+ readonly: true ,
211+ } as TextInput ,
211212 },
212213 });
213214
Original file line number Diff line number Diff line change @@ -26,6 +26,7 @@ export default defineComponent({
2626 disabled: props ?.control ?.disabled ,
2727 placeholder: props ?.control ?.placeholder ,
2828 required: props .control .required ,
29+ readonly: props ?.control .readonly ,
2930 autocomplete: props .control .autocomplete ,
3031 ariaLabel: props .control .ariaLabel ,
3132 ariaLabelledBy: props .control .ariaLabelledBy ,
Original file line number Diff line number Diff line change @@ -22,12 +22,15 @@ export default defineComponent({
2222 {
2323 id: props .control .name ,
2424 name: props ?.control ?.name || ' ' ,
25+ class: [' form-control' ],
26+ value: props ?.control ?.value ,
2527 disabled: props ?.control ?.disabled ,
2628 placeholder: props ?.control ?.placeholder ,
2729 required: props .control .required ,
30+ readonly: props ?.control .readonly ,
31+ ariaLabel: props .control .ariaLabel ,
32+ ariaLabelledBy: props .control .ariaLabelledBy ,
2833 ariaRequired: props .control .required ,
29- class: [' form-control' ],
30- value: props ?.control ?.value ,
3134 onFocus ,
3235 onBlur ,
3336 onChange ,
Original file line number Diff line number Diff line change @@ -24,6 +24,7 @@ export default defineComponent({
2424 placeholder: props ?.control ?.placeholder ,
2525 required: props .control .required ,
2626 autocomplete: props .control .autocomplete ,
27+ readonly: props ?.control .readonly ,
2728 ariaLabel: props .control .ariaLabel ,
2829 ariaLabelledBy: props .control .ariaLabelledBy ,
2930 ariaRequired: props .control .required ,
Original file line number Diff line number Diff line change @@ -32,6 +32,7 @@ export default defineComponent({
3232 disabled: props .control .disabled ,
3333 placeholder: props .control .placeholder ,
3434 required: props .control .required ,
35+ readonly: props ?.control .readonly ,
3536 autocomplete: props .control .autocomplete ,
3637 ariaRequired: props .control .required ,
3738 ariaLabel: props .control .ariaLabel ,
Original file line number Diff line number Diff line change @@ -54,6 +54,7 @@ export interface InputBase {
5454 customStyles ?: string | string [ ] | BindingObject | BindingObject [ ] | unknown ;
5555 placeholder ?: string ;
5656 autocomplete ?: string ;
57+ readonly ?: boolean ;
5758 validations ?: FormValidation [ ] ;
5859}
5960
You can’t perform that action at this time.
0 commit comments