@stonecrop/aform 0.38.1 → 0.39.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -21,20 +21,20 @@
21
21
  color: var(--sc-input-active-label-color);
22
22
  }
23
23
 
24
- .aform_form-link-wrapper[data-v-07d20e9b] {
24
+ .aform_form-link-wrapper[data-v-a42cba74] {
25
25
  position: relative;
26
26
  }
27
- .input-group[data-v-07d20e9b] {
27
+ .input-group[data-v-a42cba74] {
28
28
  display: flex;
29
29
  align-items: stretch;
30
30
  }
31
- .aform_input-field[data-v-07d20e9b] {
31
+ .aform_input-field[data-v-a42cba74] {
32
32
  flex: 1;
33
33
  min-width: 0;
34
34
  }
35
35
 
36
36
  /* No top padding: the shared rule reserves it for a floating label, which embedded mode never renders. */
37
- .aform_form-element--embedded[data-v-07d20e9b] {
37
+ .aform_form-element--embedded[data-v-a42cba74] {
38
38
  min-width: 0;
39
39
  flex-grow: 0;
40
40
  padding-top: 0;
@@ -42,7 +42,7 @@
42
42
 
43
43
  /* Embedded mode: the host component's own container supplies the border, so this input goes
44
44
  borderless. Its vertical padding stays the standalone field's, so its text lines up with the host's. */
45
- .aform_input-field--embedded[data-v-07d20e9b] {
45
+ .aform_input-field--embedded[data-v-a42cba74] {
46
46
  outline: none;
47
47
  background: transparent;
48
48
  padding: 0.5rem 1ch;
@@ -51,7 +51,7 @@
51
51
  /* Only in embedded mode is the trigger deliberately narrower than its options (e.g. a currency
52
52
  symbol box): let the dropdown grow past it rather than truncate. Standalone pickers keep the
53
53
  dropdown flush with the input, so a long display text can't overhang a narrow form column. */
54
- .aform_form-element--embedded .autocomplete-results[data-v-07d20e9b] {
54
+ .aform_form-element--embedded .autocomplete-results[data-v-a42cba74] {
55
55
  min-width: 100%;
56
56
  width: max-content;
57
57
  }
@@ -59,7 +59,7 @@
59
59
  /* Give the button the same outline as the input, then slide it 2px left so the outlines
60
60
  overlap exactly at the join: input right outline sits at (input_right - 1px),
61
61
  button left outline also sits at (button_left + 1px) = (input_right - 2px + 1px) = same pixel. */
62
- .aform_form-btn[data-v-07d20e9b] {
62
+ .aform_form-btn[data-v-a42cba74] {
63
63
  appearance: none;
64
64
  border: none;
65
65
  outline: 1px solid var(--sc-input-border-color);
@@ -77,7 +77,7 @@
77
77
 
78
78
  /* Drawn rather than a text glyph, but set on the text's baseline at capital height: text sits
79
79
  above its box's centre, so an icon centred in the box reads low beside the input's text. */
80
- .aform_form-btn-icon[data-v-07d20e9b] {
80
+ .aform_form-btn-icon[data-v-a42cba74] {
81
81
  height: 0.716em;
82
82
  width: auto;
83
83
  vertical-align: baseline;
@@ -90,7 +90,7 @@
90
90
  }
91
91
 
92
92
  /* The glyph stays as the button's spoken name, hidden from sight. */
93
- .aform_form-btn-name[data-v-07d20e9b] {
93
+ .aform_form-btn-name[data-v-a42cba74] {
94
94
  position: absolute;
95
95
  width: 1px;
96
96
  height: 1px;
@@ -99,12 +99,13 @@
99
99
  clip: rect(0, 0, 0, 0);
100
100
  white-space: nowrap;
101
101
  }
102
- .aform_form-btn[data-v-07d20e9b]:focus,
103
- .input-group:focus-within .aform_form-btn[data-v-07d20e9b] {
102
+ .aform_form-btn[data-v-a42cba74]:focus,
103
+ .input-group:focus-within .aform_form-btn[data-v-a42cba74] {
104
104
  outline-color: var(--sc-input-active-border-color);
105
105
  }
106
- .autocomplete-results[data-v-07d20e9b] {
106
+ .autocomplete-results[data-v-a42cba74] {
107
107
  position: absolute;
108
+ box-sizing: border-box;
108
109
  width: 100%;
109
110
  z-index: 100;
110
111
  padding: 0;
@@ -114,46 +115,49 @@
114
115
  border-top: none;
115
116
  border-radius: 0 0 var(--sc-border-radius) var(--sc-border-radius);
116
117
  background: var(--sc-overlay-background);
118
+ box-shadow: var(--sc-overlay-shadow);
119
+ max-height: var(--sc-dropdown-max-height);
120
+ overflow-y: auto;
117
121
  }
118
- .autocomplete-result[data-v-07d20e9b] {
122
+ .autocomplete-result[data-v-a42cba74] {
119
123
  padding: 4px 6px;
120
124
  cursor: pointer;
121
- border-bottom: 0.5px solid var(--sc-input-border-color);
122
125
  }
123
- .autocomplete-result.is-active[data-v-07d20e9b],
124
- .autocomplete-result[data-v-07d20e9b]:hover {
126
+ .autocomplete-result.is-active[data-v-a42cba74],
127
+ .autocomplete-result[data-v-a42cba74]:hover {
125
128
  background-color: var(--sc-row-color-zebra-light);
126
129
  color: var(--sc-input-active-border-color);
127
130
  }
128
131
 
129
- .acurrency__row[data-v-7c503cec] {
132
+ .acurrency__row[data-v-140c66a7] {
130
133
  display: flex;
131
134
  gap: 1ch;
132
135
  }
133
- .acurrency__row--base[data-v-7c503cec] {
136
+ .acurrency__row--base[data-v-140c66a7] {
134
137
  margin-top: 1.5rem;
135
138
  }
136
- .acurrency__field[data-v-7c503cec] {
139
+ .acurrency__field[data-v-140c66a7] {
137
140
  position: relative;
138
141
  flex: 1;
139
142
  min-width: 0;
140
143
  }
141
- .acurrency__group[data-v-7c503cec] {
144
+ .acurrency__group[data-v-140c66a7] {
142
145
  display: flex;
143
146
  align-items: stretch;
147
+ box-sizing: border-box;
144
148
  width: 100%;
145
149
  background: var(--sc-input-field-background);
146
150
  border: 1px solid var(--sc-input-border-color);
147
151
  border-radius: var(--sc-border-radius);
148
152
  }
149
- .acurrency__group[data-v-7c503cec]:focus-within {
153
+ .acurrency__group[data-v-140c66a7]:focus-within {
150
154
  border-color: var(--sc-input-active-border-color);
151
155
  }
152
156
 
153
157
  /* Wraps just the amount input so its floating label (`left: 10px` of the nearest
154
158
  `position: relative` ancestor, per .aform_field-label) anchors above the amount box
155
159
  specifically, not the group's outer left edge — which is now the currency prefix. */
156
- .acurrency__amount-wrap[data-v-7c503cec] {
160
+ .acurrency__amount-wrap[data-v-140c66a7] {
157
161
  position: relative;
158
162
  flex: 1;
159
163
  min-width: 0;
@@ -161,15 +165,15 @@
161
165
 
162
166
  /* The amount label ("Total") is the primary label for the whole merged group — bumped up
163
167
  slightly from the shared .aform_field-label size so it reads as the group's main label. */
164
- .acurrency__amount-wrap .aform_field-label[data-v-7c503cec] {
168
+ .acurrency__amount-wrap .aform_field-label[data-v-140c66a7] {
165
169
  font-size: 0.85rem;
166
170
  }
167
171
 
168
172
  /* The label names the whole group, so focus on the currency picker darkens it too. */
169
- .acurrency__group:focus-within .acurrency__amount-wrap > .aform_field-label[data-v-7c503cec] {
173
+ .acurrency__group:focus-within .acurrency__amount-wrap > .aform_field-label[data-v-140c66a7] {
170
174
  color: var(--sc-input-active-label-color);
171
175
  }
172
- .acurrency__amount[data-v-7c503cec] {
176
+ .acurrency__amount[data-v-140c66a7] {
173
177
  width: 100%;
174
178
  box-sizing: border-box;
175
179
  border: none;
@@ -184,8 +188,8 @@
184
188
  appearance: textfield;
185
189
  -moz-appearance: textfield;
186
190
  }
187
- .acurrency__amount[data-v-7c503cec]::-webkit-outer-spin-button,
188
- .acurrency__amount[data-v-7c503cec]::-webkit-inner-spin-button {
191
+ .acurrency__amount[data-v-140c66a7]::-webkit-outer-spin-button,
192
+ .acurrency__amount[data-v-140c66a7]::-webkit-inner-spin-button {
189
193
  appearance: none;
190
194
  -webkit-appearance: none;
191
195
  margin: 0;
@@ -196,7 +200,7 @@
196
200
  picked, not the full name), tinted background, left-rounded to match the group's own
197
201
  corner so the tint doesn't overhang the border. The dropdown itself isn't bound by this
198
202
  width — see AFormLink's .autocomplete-results — so search results still show full names. */
199
- .acurrency__currency[data-v-7c503cec] {
203
+ .acurrency__currency[data-v-140c66a7] {
200
204
  position: relative;
201
205
  flex: 0 0 auto;
202
206
  min-width: 4.5rem;
@@ -204,7 +208,14 @@
204
208
  border-right: 1px solid var(--sc-input-border-color);
205
209
  border-radius: var(--sc-border-radius) 0 0 var(--sc-border-radius);
206
210
  }
207
- .acurrency__base-field[data-v-7c503cec] {
211
+
212
+ /* The picker's list hangs from the group's outer border to the picker's divider, so its side lines
213
+ continue theirs. `.acurrency__group` is there to outrank AFormLink's own embedded `min-width`. */
214
+ .acurrency__group .acurrency__currency[data-v-140c66a7] .autocomplete-results {
215
+ left: -1px;
216
+ min-width: calc(100% + 2px);
217
+ }
218
+ .acurrency__base-field[data-v-140c66a7] {
208
219
  width: 100%;
209
220
  box-sizing: border-box;
210
221
  font-size: 1rem;
@@ -215,13 +226,13 @@
215
226
  appearance: textfield;
216
227
  -moz-appearance: textfield;
217
228
  }
218
- .acurrency__base-field[data-v-7c503cec]:disabled {
229
+ .acurrency__base-field[data-v-140c66a7]:disabled {
219
230
  color: var(--sc-gray-50);
220
231
  }
221
232
 
222
233
  /* Base Amount and Exchange Rate are read-only — the number spinner offers nothing here. */
223
- .acurrency__base-field[data-v-7c503cec]::-webkit-outer-spin-button,
224
- .acurrency__base-field[data-v-7c503cec]::-webkit-inner-spin-button {
234
+ .acurrency__base-field[data-v-140c66a7]::-webkit-outer-spin-button,
235
+ .acurrency__base-field[data-v-140c66a7]::-webkit-inner-spin-button {
225
236
  appearance: none;
226
237
  -webkit-appearance: none;
227
238
  margin: 0;
@@ -427,14 +438,15 @@ p.aform_error[data-v-d0133599] {
427
438
  margin-top: 0.25rem;
428
439
  }
429
440
 
430
- .autocomplete[data-v-2275075e] {
441
+ .autocomplete[data-v-f395a95f] {
431
442
  position: relative;
432
443
  }
433
- .autocomplete-results[data-v-2275075e] {
444
+ .autocomplete-results[data-v-f395a95f] {
434
445
  position: absolute;
435
446
  left: 0;
436
447
  right: 0;
437
448
  z-index: 100;
449
+ box-sizing: border-box;
438
450
  padding: 0;
439
451
  margin: 0;
440
452
  color: var(--sc-input-active-border-color);
@@ -442,16 +454,18 @@ p.aform_error[data-v-d0133599] {
442
454
  border-radius: 0 0 var(--sc-border-radius) var(--sc-border-radius);
443
455
  border-top: none;
444
456
  background-color: var(--sc-overlay-background);
457
+ box-shadow: var(--sc-overlay-shadow);
445
458
  list-style: none;
459
+ max-height: var(--sc-dropdown-max-height);
460
+ overflow-y: auto;
446
461
  }
447
- .autocomplete-result[data-v-2275075e] {
462
+ .autocomplete-result[data-v-f395a95f] {
448
463
  text-align: left;
449
464
  padding: 4px 6px;
450
465
  cursor: pointer;
451
- border-bottom: 0.5px solid var(--sc-input-border-color);
452
466
  }
453
- .autocomplete-result.is-active[data-v-2275075e],
454
- .autocomplete-result[data-v-2275075e]:hover {
467
+ .autocomplete-result.is-active[data-v-f395a95f],
468
+ .autocomplete-result[data-v-f395a95f]:hover {
455
469
  background-color: var(--sc-row-color-zebra-light);
456
470
  color: var(--sc-input-active-border-color);
457
471
  }
@@ -826,7 +840,7 @@ p.aform_error {
826
840
  margin: 0;
827
841
  }
828
842
 
829
- .aform[data-v-dbfe4358] {
843
+ .aform[data-v-5055dffc] {
830
844
  display: flex;
831
845
  flex-wrap: wrap;
832
846
  gap: 1rem;
@@ -838,27 +852,27 @@ p.aform_error {
838
852
  max-width: 100%;
839
853
  }
840
854
  @media screen and (max-width: 400px) {
841
- .aform[data-v-dbfe4358] {
855
+ .aform[data-v-5055dffc] {
842
856
  flex-direction: column;
843
857
  }
844
858
  }
845
859
 
846
860
  /* Nested form section */
847
- .aform-nested-section[data-v-dbfe4358] {
861
+ .aform-nested-section[data-v-5055dffc] {
848
862
  width: 100%;
849
863
  padding: 0.5rem 0;
850
864
  }
851
- .aform-nested-label[data-v-dbfe4358] {
865
+ .aform-nested-label[data-v-5055dffc] {
852
866
  font-size: 0.9rem;
853
867
  font-weight: 600;
854
868
  margin: 0 0 0.5rem 0;
855
869
  color: var(--sc-input-label-color);
856
870
  }
857
- .aform-nested-section .aform[data-v-dbfe4358] {
871
+ .aform-nested-section .aform[data-v-5055dffc] {
858
872
  border-left-width: 2px;
859
873
  margin-left: 0.5rem;
860
874
  }
861
- .aform-table-expansion[data-v-dbfe4358] {
875
+ .aform-table-expansion[data-v-5055dffc] {
862
876
  margin-bottom: 0;
863
877
  border: none;
864
878
  border-left: none;
@@ -892,14 +906,17 @@ p.aform_error {
892
906
  transition: transform 250ms;
893
907
  }
894
908
 
895
- fieldset[data-v-162e7317] {
909
+ fieldset[data-v-8215ff87] {
910
+ /* Its padding and border sit inside the width, and no browser margin sits outside it: a fieldset
911
+ spans exactly the space it is given, so its border never crosses the form's. */
912
+ box-sizing: border-box;
896
913
  max-width: 100%;
897
914
  width: 100%;
898
- margin-right: 2ch;
915
+ margin: 0;
899
916
  border: 1px solid transparent;
900
917
  border-bottom: 1px solid var(--sc-gray-50);
901
918
  }
902
- legend[data-v-162e7317] {
919
+ legend[data-v-8215ff87] {
903
920
  width: 100%;
904
921
  height: 1.15rem;
905
922
  border: 1px solid transparent;
@@ -908,7 +925,7 @@ legend[data-v-162e7317] {
908
925
  font-weight: 600;
909
926
  user-select: none;
910
927
  }
911
- .collapse-button[data-v-162e7317] {
928
+ .collapse-button[data-v-8215ff87] {
912
929
  float: right;
913
930
  }
914
931
 
@@ -959,31 +976,32 @@ legend[data-v-162e7317] {
959
976
  background-color: var(--sc-gray-5);
960
977
  }
961
978
 
962
- .aquantity__row[data-v-b2c39a5c] {
979
+ .aquantity__row[data-v-05d1da97] {
963
980
  display: flex;
964
981
  gap: 1ch;
965
982
  }
966
- .aquantity__row--stock[data-v-b2c39a5c] {
983
+ .aquantity__row--stock[data-v-05d1da97] {
967
984
  margin-top: 1.5rem;
968
985
  }
969
- .aquantity__field[data-v-b2c39a5c] {
986
+ .aquantity__field[data-v-05d1da97] {
970
987
  position: relative;
971
988
  flex: 1;
972
989
  min-width: 0;
973
990
  }
974
- .aquantity__group[data-v-b2c39a5c] {
991
+ .aquantity__group[data-v-05d1da97] {
975
992
  position: relative;
976
993
  display: flex;
977
994
  align-items: stretch;
995
+ box-sizing: border-box;
978
996
  width: 100%;
979
997
  background: var(--sc-input-field-background);
980
998
  border: 1px solid var(--sc-input-border-color);
981
999
  border-radius: var(--sc-border-radius);
982
1000
  }
983
- .aquantity__group[data-v-b2c39a5c]:focus-within {
1001
+ .aquantity__group[data-v-05d1da97]:focus-within {
984
1002
  border-color: var(--sc-input-active-border-color);
985
1003
  }
986
- .aquantity__qty[data-v-b2c39a5c] {
1004
+ .aquantity__qty[data-v-05d1da97] {
987
1005
  flex: 1;
988
1006
  min-width: 0;
989
1007
  border: none;
@@ -997,18 +1015,18 @@ legend[data-v-162e7317] {
997
1015
  appearance: textfield;
998
1016
  -moz-appearance: textfield;
999
1017
  }
1000
- .aquantity__qty[data-v-b2c39a5c]::-webkit-outer-spin-button,
1001
- .aquantity__qty[data-v-b2c39a5c]::-webkit-inner-spin-button {
1018
+ .aquantity__qty[data-v-05d1da97]::-webkit-outer-spin-button,
1019
+ .aquantity__qty[data-v-05d1da97]::-webkit-inner-spin-button {
1002
1020
  appearance: none;
1003
1021
  -webkit-appearance: none;
1004
1022
  margin: 0;
1005
1023
  }
1006
- .aquantity__uom[data-v-b2c39a5c] {
1024
+ .aquantity__uom[data-v-05d1da97] {
1007
1025
  position: relative;
1008
1026
  flex: 0 0 auto;
1009
1027
  border-left: 1px solid var(--sc-input-border-color);
1010
1028
  }
1011
- .aquantity__uom-toggle[data-v-b2c39a5c] {
1029
+ .aquantity__uom-toggle[data-v-05d1da97] {
1012
1030
  display: flex;
1013
1031
  align-items: center;
1014
1032
  gap: 0.75ch;
@@ -1023,11 +1041,11 @@ legend[data-v-162e7317] {
1023
1041
  white-space: nowrap;
1024
1042
  cursor: pointer;
1025
1043
  }
1026
- .aquantity__uom-toggle[data-v-b2c39a5c]:disabled {
1044
+ .aquantity__uom-toggle[data-v-05d1da97]:disabled {
1027
1045
  cursor: not-allowed;
1028
1046
  color: var(--sc-gray-50);
1029
1047
  }
1030
- .aquantity__caret[data-v-b2c39a5c] {
1048
+ .aquantity__caret[data-v-05d1da97] {
1031
1049
  display: inline-block;
1032
1050
  width: 0;
1033
1051
  height: 0;
@@ -1035,29 +1053,37 @@ legend[data-v-162e7317] {
1035
1053
  border-right: 0.3em solid transparent;
1036
1054
  border-top: 0.3em solid currentColor;
1037
1055
  }
1038
- .aquantity__uom-menu[data-v-b2c39a5c] {
1056
+
1057
+ /* Hangs from the divider beside the toggle to the field's outer border, so its side lines continue
1058
+ theirs; a long unit name widens it to the left. */
1059
+ .aquantity__uom-menu[data-v-05d1da97] {
1039
1060
  position: absolute;
1040
1061
  top: 100%;
1041
- right: 0;
1062
+ right: -1px;
1042
1063
  z-index: 100;
1043
- min-width: 100%;
1044
- margin: 0.15rem 0 0 0;
1064
+ box-sizing: border-box;
1065
+ min-width: calc(100% + 2px);
1066
+ max-height: var(--sc-dropdown-max-height);
1067
+ overflow-y: auto;
1068
+ margin: 0;
1045
1069
  padding: 0.25rem 0;
1046
1070
  list-style: none;
1047
- background: var(--sc-input-field-background);
1071
+ background: var(--sc-overlay-background);
1048
1072
  border: 1px solid var(--sc-input-active-border-color);
1049
- border-radius: var(--sc-border-radius);
1073
+ border-top: none;
1074
+ border-radius: 0 0 var(--sc-border-radius) var(--sc-border-radius);
1075
+ box-shadow: var(--sc-overlay-shadow);
1050
1076
  }
1051
- .aquantity__uom-option[data-v-b2c39a5c] {
1077
+ .aquantity__uom-option[data-v-05d1da97] {
1052
1078
  padding: 0.4ch 1ch;
1053
1079
  white-space: nowrap;
1054
1080
  cursor: pointer;
1055
1081
  }
1056
- .aquantity__uom-option.is-active[data-v-b2c39a5c],
1057
- .aquantity__uom-option[data-v-b2c39a5c]:hover {
1082
+ .aquantity__uom-option.is-active[data-v-05d1da97],
1083
+ .aquantity__uom-option[data-v-05d1da97]:hover {
1058
1084
  background-color: var(--sc-row-color-zebra-light);
1059
1085
  }
1060
- .aquantity__stock-field[data-v-b2c39a5c] {
1086
+ .aquantity__stock-field[data-v-05d1da97] {
1061
1087
  width: 100%;
1062
1088
  font-size: 1rem;
1063
1089
  padding: 0.5rem 1ch;
@@ -1065,7 +1091,7 @@ legend[data-v-162e7317] {
1065
1091
  border-radius: var(--sc-border-radius);
1066
1092
  outline: none;
1067
1093
  }
1068
- .aquantity__stock-field[data-v-b2c39a5c]:disabled {
1094
+ .aquantity__stock-field[data-v-05d1da97]:disabled {
1069
1095
  color: var(--sc-gray-50);
1070
1096
  }
1071
1097
 
@@ -1 +1 @@
1
- {"version":3,"file":"AForm.vue.d.ts","sourceRoot":"","sources":["../../../src/components/AForm.vue"],"names":[],"mappings":"AAgWA,OAAO,KAAK,EAAE,aAAa,EAAiD,MAAM,UAAU,CAAA;AAC5F,OAAO,KAAK,EAAgB,eAAe,EAAE,MAAM,mBAAmB,CAAA;AAItE,KAAK,WAAW,GAAG;IAClB,MAAM,EAAE,aAAa,EAAE,CAAA;IACvB,IAAI,CAAC,EAAE,eAAe,CAAA;IACtB,mGAAmG;IACnG,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,CAAA;CACjC,CAAC;AAyIF,KAAK,gBAAgB,GAAG;IACxB,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;CAC3B,CAAC;AAKF,KAAK,iBAAiB,GAAG,WAAW,GAAG,gBAAgB,CAAC;AAuJxD,QAAA,MAAM,YAAY;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
1
+ {"version":3,"file":"AForm.vue.d.ts","sourceRoot":"","sources":["../../../src/components/AForm.vue"],"names":[],"mappings":"AA6XA,OAAO,KAAK,EAAE,aAAa,EAAiD,MAAM,UAAU,CAAA;AAC5F,OAAO,KAAK,EAAgB,eAAe,EAAE,MAAM,mBAAmB,CAAA;AAItE,KAAK,WAAW,GAAG;IAClB,MAAM,EAAE,aAAa,EAAE,CAAA;IACvB,IAAI,CAAC,EAAE,eAAe,CAAA;IACtB,mGAAmG;IACnG,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,CAAA;CACjC,CAAC;AA0JF,KAAK,gBAAgB,GAAG;IACxB,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;CAC3B,CAAC;AAKF,KAAK,iBAAiB,GAAG,WAAW,GAAG,gBAAgB,CAAC;AAwLxD,QAAA,MAAM,YAAY;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
@@ -1 +1 @@
1
- {"version":3,"file":"ACurrencyInput.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/form/ACurrencyInput.vue"],"names":[],"mappings":"AA4XA,OAAO,KAAK,EAAkB,cAAc,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAKjG,KAAK,WAAW,GAAG,cAAc,GAAG;IAClC,OAAO,CAAC,EAAE,eAAe,CAAA;IACzB,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,iBAAiB,CAAC,EAAE,MAAM,CAAA;CAC1B,CAAC;AA+LH,KAAK,gBAAgB,GAAG;IACxB,UAAU,CAAC,EAAE,aAAa,GAAG,IAAI,CAAC;CACjC,CAAC;AAKF,KAAK,iBAAiB,GAAG,WAAW,GAAG,gBAAgB,CAAC;AAyNxD,QAAA,MAAM,YAAY;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
1
+ {"version":3,"file":"ACurrencyInput.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/form/ACurrencyInput.vue"],"names":[],"mappings":"AAoYA,OAAO,KAAK,EAAkB,cAAc,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAKjG,KAAK,WAAW,GAAG,cAAc,GAAG;IAClC,OAAO,CAAC,EAAE,eAAe,CAAA;IACzB,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,iBAAiB,CAAC,EAAE,MAAM,CAAA;CAC1B,CAAC;AA+LH,KAAK,gBAAgB,GAAG;IACxB,UAAU,CAAC,EAAE,aAAa,GAAG,IAAI,CAAC;CACjC,CAAC;AAKF,KAAK,iBAAiB,GAAG,WAAW,GAAG,gBAAgB,CAAC;AA4NxD,QAAA,MAAM,YAAY;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
@@ -1 +1 @@
1
- {"version":3,"file":"ADropdown.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/form/ADropdown.vue"],"names":[],"mappings":"AAAA,OAoPO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAMrD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAA;AAKjD,KAAK,WAAW,GAAG,cAAc,GAAG;IAClC,OAAO,CAAC,EAAE,YAAY,CAAA;IACtB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,cAAc,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,MAAM,EAAE,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC,CAAA;CACjE,CAAC;AAuIH,KAAK,gBAAgB,GAAG;IACxB,UAAU,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAKF,KAAK,iBAAiB,GAAG,WAAW,GAAG,gBAAgB,CAAC;AAkKxD,QAAA,MAAM,YAAY;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
1
+ {"version":3,"file":"ADropdown.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/form/ADropdown.vue"],"names":[],"mappings":"AAAA,OAoQO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAOrD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAA;AAKjD,KAAK,WAAW,GAAG,cAAc,GAAG;IAClC,OAAO,CAAC,EAAE,YAAY,CAAA;IACtB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,cAAc,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,MAAM,EAAE,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC,CAAA;CACjE,CAAC;AA6IH,KAAK,gBAAgB,GAAG;IACxB,UAAU,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAKF,KAAK,iBAAiB,GAAG,WAAW,GAAG,gBAAgB,CAAC;AAqKxD,QAAA,MAAM,YAAY;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
@@ -4,19 +4,29 @@ type __VLS_Props = {
4
4
  schema: ResolvedField[];
5
5
  label?: string;
6
6
  collapsible?: boolean;
7
- data?: Record<string, any>;
8
7
  /** Rendering mode forwarded to the inner AForm */
9
8
  mode?: InteractionMode;
9
+ /** Inline validation errors keyed by fieldname, forwarded to the inner AForm. */
10
+ errors?: Record<string, string[]>;
10
11
  };
12
+ type __VLS_ModelProps = {
13
+ /** The record the fieldset's fields belong to: a fieldset is layout, so they are its own keys. */
14
+ 'data'?: Record<string, any>;
15
+ };
16
+ type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
11
17
  declare var __VLS_6: {
12
18
  collapsed: boolean;
13
19
  };
14
20
  type __VLS_Slots = {} & {
15
21
  default?: (props: typeof __VLS_6) => any;
16
22
  };
17
- declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
23
+ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {
18
24
  collapsed: import("vue").Ref<boolean, boolean>;
19
- }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
25
+ }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
26
+ "update:data": (value: Record<string, any>) => any;
27
+ }, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
28
+ "onUpdate:data"?: ((value: Record<string, any>) => any) | undefined;
29
+ }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
20
30
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
21
31
  declare const _default: typeof __VLS_export;
22
32
  export default _default;
@@ -1 +1 @@
1
- {"version":3,"file":"AFieldset.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/form/AFieldset.vue"],"names":[],"mappings":"AAAA,OA2EO,KAAK,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAA;AAKxD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAEhD,KAAK,WAAW,GAAG;IAClB,MAAM,EAAE,aAAa,EAAE,CAAA;IACvB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC1B,kDAAkD;IAClD,IAAI,CAAC,EAAE,eAAe,CAAA;CACtB,CAAC;AAkFF,QAAA,IAAI,OAAO;;CAAW,CAAE;AACxB,KAAK,WAAW,GAAG,EAAE,GACnB;IAAE,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,OAAO,KAAK,GAAG,CAAA;CAAE,CAAC;AAK/C,QAAA,MAAM,UAAU;;oPAGd,CAAC;AACH,QAAA,MAAM,YAAY,EAAS,eAAe,CAAC,OAAO,UAAU,EAAE,WAAW,CAAC,CAAC;wBACtD,OAAO,YAAY;AAAxC,wBAAyC;AACzC,KAAK,eAAe,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAChC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KACV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"AFieldset.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/form/AFieldset.vue"],"names":[],"mappings":"AAAA,OAgFO,KAAK,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAA;AAKxD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAEhD,KAAK,WAAW,GAAG;IAClB,MAAM,EAAE,aAAa,EAAE,CAAA;IACvB,KA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AA;IACtB,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,qBAAqB,CAAC,EAAE,MAAM,CAAA;CAC9B,CAAC;AAqJH,KAAK,gBAAgB,GAAG;IACxB,UAAU,CAAC,EAAE,aAAa,GAAG,IAAI,CAAC;CACjC,CAAC;AAKF,KAAK,iBAAiB,GAAG,WAAW,GAAG,gBAAgB,CAAC;AA6PxD,QAAA,MAAM,YAAY;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
1
+ {"version":3,"file":"AQuantityInput.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/form/AQuantityInput.vue"],"names":[],"mappings":"AA8YA,OAAO,KAAK,EAAE,cAAc,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAGjF,KAAK,WAAW,GAAG,cAAc,GAAG;IAClC,OAAO,CAAC,EAAE,eAAe,CAAA;IACzB,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,qBAAqB,CAAC,EAAE,MAAM,CAAA;CAC9B,CAAC;AA2JH,KAAK,gBAAgB,GAAG;IACxB,UAAU,CAAC,EAAE,aAAa,GAAG,IAAI,CAAC;CACjC,CAAC;AAKF,KAAK,iBAAiB,GAAG,WAAW,GAAG,gBAAgB,CAAC;AAgQxD,QAAA,MAAM,YAAY;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
@@ -0,0 +1,15 @@
1
+ import { type Ref } from 'vue';
2
+ type DropdownListState = {
3
+ isOpen: () => boolean;
4
+ /** Options arrive after a list opens when its search is async, and each arrival is measured again. */
5
+ optionCount: () => number;
6
+ activeIndex: () => number | null;
7
+ };
8
+ /**
9
+ * Keeps an open dropdown list in the window: its height is the smaller of `--sc-dropdown-max-height`
10
+ * (the stylesheet's `max-height`) and the room left below it, never under about four rows, and the
11
+ * option the arrow keys highlight is scrolled into sight.
12
+ */
13
+ export declare function fitDropdownList(list: Readonly<Ref<HTMLElement | null>>, state: DropdownListState): void;
14
+ export {};
15
+ //# sourceMappingURL=dropdownList.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dropdownList.d.ts","sourceRoot":"","sources":["../../../src/composables/dropdownList.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoC,KAAK,GAAG,EAAE,MAAM,KAAK,CAAA;AAOhE,KAAK,iBAAiB,GAAG;IACxB,MAAM,EAAE,MAAM,OAAO,CAAA;IACrB,sGAAsG;IACtG,WAAW,EAAE,MAAM,MAAM,CAAA;IACzB,WAAW,EAAE,MAAM,MAAM,GAAG,IAAI,CAAA;CAChC,CAAA;AAED;;;;GAIG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE,QAAQ,CAAC,GAAG,CAAC,WAAW,GAAG,IAAI,CAAC,CAAC,EAAE,KAAK,EAAE,iBAAiB,QAiDhG"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stonecrop/aform",
3
- "version": "0.38.1",
3
+ "version": "0.39.0",
4
4
  "description": "Schema-driven form components for Stonecrop",
5
5
  "keywords": [
6
6
  "components",
@@ -47,18 +47,18 @@
47
47
  "@vueuse/components": "^14.2.1",
48
48
  "@vueuse/core": "^14.2.1",
49
49
  "temporal-polyfill": "^1.0.5",
50
- "@stonecrop/atable": "0.38.1",
51
- "@stonecrop/schema": "0.38.1",
52
- "@stonecrop/themes": "0.38.1",
53
- "@stonecrop/utilities": "0.38.1"
50
+ "@stonecrop/atable": "0.39.0",
51
+ "@stonecrop/schema": "0.39.0",
52
+ "@stonecrop/utilities": "0.39.0",
53
+ "@stonecrop/themes": "0.39.0"
54
54
  },
55
55
  "devDependencies": {
56
56
  "@microsoft/api-extractor": "^7.58.7",
57
57
  "@types/node": "^24.12.4",
58
58
  "@vitejs/plugin-vue": "^6.0.6",
59
59
  "@vitest/browser-playwright": "^4.1.11",
60
- "@vitest/coverage-istanbul": "^4.1.5",
61
- "@vitest/ui": "^4.1.5",
60
+ "@vitest/coverage-istanbul": "^4.1.11",
61
+ "@vitest/ui": "^4.1.11",
62
62
  "@vue/test-utils": "^2.4.10",
63
63
  "jsdom": "^29.1.1",
64
64
  "oxlint": "1.67.0",
@@ -68,7 +68,7 @@
68
68
  "typescript": "^6.0.3",
69
69
  "vite": "^8.2.2",
70
70
  "vite-plugin-lib-inject-css": "^2.2.2",
71
- "vitest": "^4.1.5",
71
+ "vitest": "^4.1.11",
72
72
  "vue": "^3.5.33",
73
73
  "vue-component-meta": "^3.3.11",
74
74
  "vue-router": "^5.0.6",