semantic-forms 5.3.17 → 5.3.18

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.
@@ -6,7 +6,7 @@
6
6
  --semanticFormsFormSubBgColor: #f5f5f5;
7
7
  --semanticFormsTextColor: #000;
8
8
  --semanticFormsBorderColor: #c0c0c0;
9
- --semanticFormsFocusColor: #c0c0c0;
9
+ --semanticFormsFocusColor: #8c8c8c;
10
10
  --semanticFormsSubBorderColor: #c0c0c0;
11
11
  --semanticFormsPlaceholderColor: rgba(0, 0, 0, 0.75);
12
12
  --semanticFormsScrollbarColor: #c0c0c0;
@@ -34,6 +34,14 @@
34
34
  :where(form.semanticForms, table.semanticForms, .semanticFormsButton) {
35
35
  --semanticFormsSwitchOffColor: #c0c0c0;
36
36
  --semanticFormsSwitchThumbColor: #fff;
37
+ --semanticFormsAutofillColor: #2196f3;
38
+ }
39
+ @supports (color: AccentColor) {
40
+ :where(form.semanticForms, table.semanticForms, .semanticFormsButton) {
41
+ --semanticFormsAutofillColor: AccentColor;
42
+ }
43
+ }
44
+ :where(form.semanticForms, table.semanticForms, .semanticFormsButton) {
37
45
  --semanticFormsNestedFieldsetBgColor: oklch(from var(--semanticFormsFormSubBgColor) 0.3 c h / 0.05);
38
46
  --semanticFormsNestedFieldsetBorder: 1px rgba(0, 0, 0, .2) solid;
39
47
  --semanticFormsNestedInputBgColor: #fff;
@@ -95,7 +103,7 @@ table.semanticForms :where(fieldset, label, input, select, textarea, button, men
95
103
  --semanticFormsFormSubBgColor: #2f2f2f;
96
104
  --semanticFormsTextColor: #fff;
97
105
  --semanticFormsBorderColor: #656565;
98
- --semanticFormsFocusColor: #656565;
106
+ --semanticFormsFocusColor: #b0b0b0;
99
107
  --semanticFormsSubBorderColor: #3f3f3f;
100
108
  --semanticFormsPlaceholderColor: rgba(255, 255, 255, 0.85);
101
109
  --semanticFormsScrollbarColor: #373737;
@@ -112,6 +120,14 @@ table.semanticForms :where(fieldset, label, input, select, textarea, button, men
112
120
  :where(html:not(.light) body:not(.light) form.semanticForms:not(.light), html:not(.light) body:not(.light) table.semanticForms:not(.light), html:not(.light) body:not(.light) .semanticFormsButton:not(.light)) {
113
121
  --semanticFormsSwitchOffColor: #656565;
114
122
  --semanticFormsSwitchThumbColor: #fff;
123
+ --semanticFormsAutofillColor: #2196f3;
124
+ }
125
+ @supports (color: AccentColor) {
126
+ :where(html:not(.light) body:not(.light) form.semanticForms:not(.light), html:not(.light) body:not(.light) table.semanticForms:not(.light), html:not(.light) body:not(.light) .semanticFormsButton:not(.light)) {
127
+ --semanticFormsAutofillColor: AccentColor;
128
+ }
129
+ }
130
+ :where(html:not(.light) body:not(.light) form.semanticForms:not(.light), html:not(.light) body:not(.light) table.semanticForms:not(.light), html:not(.light) body:not(.light) .semanticFormsButton:not(.light)) {
115
131
  --semanticFormsNestedFieldsetBgColor: oklch(from var(--semanticFormsFormSubBgColor) 0.9 c h / 0.05);
116
132
  --semanticFormsNestedFieldsetBorder: 1px rgba(255, 255, 255, .1) solid;
117
133
  --semanticFormsNestedInputBgColor: rgba(255, 255, 255, .15);
@@ -137,7 +153,7 @@ table.semanticForms :where(fieldset, label, input, select, textarea, button, men
137
153
  --semanticFormsFormSubBgColor: #2f2f2f;
138
154
  --semanticFormsTextColor: #fff;
139
155
  --semanticFormsBorderColor: #656565;
140
- --semanticFormsFocusColor: #656565;
156
+ --semanticFormsFocusColor: #b0b0b0;
141
157
  --semanticFormsSubBorderColor: #3f3f3f;
142
158
  --semanticFormsPlaceholderColor: rgba(255, 255, 255, 0.85);
143
159
  --semanticFormsScrollbarColor: #373737;
@@ -154,6 +170,14 @@ table.semanticForms :where(fieldset, label, input, select, textarea, button, men
154
170
  :where(html:not(.light) body:not(.light) form.semanticForms.dark, html:not(.light) body:not(.light) table.semanticForms.dark, html:not(.light) body:not(.light) .semanticFormsButton.dark) {
155
171
  --semanticFormsSwitchOffColor: #656565;
156
172
  --semanticFormsSwitchThumbColor: #fff;
173
+ --semanticFormsAutofillColor: #2196f3;
174
+ }
175
+ @supports (color: AccentColor) {
176
+ :where(html:not(.light) body:not(.light) form.semanticForms.dark, html:not(.light) body:not(.light) table.semanticForms.dark, html:not(.light) body:not(.light) .semanticFormsButton.dark) {
177
+ --semanticFormsAutofillColor: AccentColor;
178
+ }
179
+ }
180
+ :where(html:not(.light) body:not(.light) form.semanticForms.dark, html:not(.light) body:not(.light) table.semanticForms.dark, html:not(.light) body:not(.light) .semanticFormsButton.dark) {
157
181
  --semanticFormsNestedFieldsetBgColor: oklch(from var(--semanticFormsFormSubBgColor) 0.9 c h / 0.05);
158
182
  --semanticFormsNestedFieldsetBorder: 1px rgba(255, 255, 255, .1) solid;
159
183
  --semanticFormsNestedInputBgColor: rgba(255, 255, 255, .15);
@@ -179,7 +203,7 @@ table.semanticForms :where(fieldset, label, input, select, textarea, button, men
179
203
  --semanticFormsFormSubBgColor: #2f2f2f;
180
204
  --semanticFormsTextColor: #fff;
181
205
  --semanticFormsBorderColor: #656565;
182
- --semanticFormsFocusColor: #656565;
206
+ --semanticFormsFocusColor: #b0b0b0;
183
207
  --semanticFormsSubBorderColor: #3f3f3f;
184
208
  --semanticFormsPlaceholderColor: rgba(255, 255, 255, 0.85);
185
209
  --semanticFormsScrollbarColor: #373737;
@@ -196,6 +220,14 @@ table.semanticForms :where(fieldset, label, input, select, textarea, button, men
196
220
  :where(form.semanticForms.dark, table.semanticForms.dark, .semanticFormsButton.dark) {
197
221
  --semanticFormsSwitchOffColor: #656565;
198
222
  --semanticFormsSwitchThumbColor: #fff;
223
+ --semanticFormsAutofillColor: #2196f3;
224
+ }
225
+ @supports (color: AccentColor) {
226
+ :where(form.semanticForms.dark, table.semanticForms.dark, .semanticFormsButton.dark) {
227
+ --semanticFormsAutofillColor: AccentColor;
228
+ }
229
+ }
230
+ :where(form.semanticForms.dark, table.semanticForms.dark, .semanticFormsButton.dark) {
199
231
  --semanticFormsNestedFieldsetBgColor: oklch(from var(--semanticFormsFormSubBgColor) 0.9 c h / 0.05);
200
232
  --semanticFormsNestedFieldsetBorder: 1px rgba(255, 255, 255, .1) solid;
201
233
  --semanticFormsNestedInputBgColor: rgba(255, 255, 255, .15);
@@ -228,6 +260,18 @@ table.semanticForms :where(fieldset, label, input, select, textarea, button, men
228
260
  --semanticFormsPageBgColor: #000;
229
261
  }
230
262
 
263
+ .semanticFormsVisuallyHidden {
264
+ position: absolute;
265
+ width: 1px;
266
+ height: 1px;
267
+ margin: -1px;
268
+ padding: 0;
269
+ border: 0;
270
+ overflow: hidden;
271
+ clip-path: inset(50%);
272
+ white-space: nowrap;
273
+ }
274
+
231
275
  .semanticForms input:where(:not([type=submit], [type=reset], [type=button], [type=image], [type=checkbox], [type=radio])),
232
276
  .semanticForms select {
233
277
  height: var(--semanticFormsInputHeight);
@@ -257,7 +301,15 @@ table.semanticForms :where(fieldset, label, input, select, textarea, button, men
257
301
  .semanticForms select:focus,
258
302
  .semanticForms textarea:focus {
259
303
  outline: none;
260
- box-shadow: inset 0 0 0 1px var(--semanticFormsFocusColor);
304
+ box-shadow: inset 0 0 0 2px var(--semanticFormsFocusColor);
305
+ }
306
+ @media (forced-colors: active) {
307
+ .semanticForms input:where(:not([type=submit], [type=reset], [type=button], [type=image], [type=checkbox], [type=radio])):focus,
308
+ .semanticForms select:focus,
309
+ .semanticForms textarea:focus {
310
+ outline: 2px solid Highlight;
311
+ outline-offset: -2px;
312
+ }
261
313
  }
262
314
  .semanticForms input:where(:not([type=submit], [type=reset], [type=button], [type=image], [type=checkbox], [type=radio])):where(:not([type=range], textarea, select)),
263
315
  .semanticForms select:where(:not([type=range], textarea, select)),
@@ -434,6 +486,18 @@ table.semanticForms :where(fieldset, label, input, select, textarea, button, men
434
486
  .semanticForms .button-link:active {
435
487
  transform: scale(0.97);
436
488
  }
489
+ @media (prefers-reduced-motion: reduce) {
490
+ .semanticForms input:where([type=submit], [type=reset], [type=button]),
491
+ .semanticForms button:where(:not(.clear, .show)),
492
+ .semanticForms .button-link {
493
+ transition: none;
494
+ }
495
+ .semanticForms input:where([type=submit], [type=reset], [type=button]):active,
496
+ .semanticForms button:where(:not(.clear, .show)):active,
497
+ .semanticForms .button-link:active {
498
+ transform: none;
499
+ }
500
+ }
437
501
  .semanticForms input:where([type=submit], [type=reset], [type=button], [type=image]),
438
502
  .semanticForms button:where(:not(.clear, .show)),
439
503
  .semanticForms .button-link {
@@ -522,6 +586,12 @@ table.semanticForms :where(fieldset, label, input, select, textarea, button, men
522
586
  outline: none;
523
587
  box-shadow: 0 0 0 2px var(--semanticFormsFocusColor);
524
588
  }
589
+ @media (forced-colors: active) {
590
+ .semanticForms input:where([type=checkbox][switch]):focus-visible {
591
+ outline: 2px solid Highlight;
592
+ outline-offset: 2px;
593
+ }
594
+ }
525
595
  .semanticForms input:where([type=checkbox][switch]):disabled {
526
596
  cursor: default;
527
597
  opacity: 0.5;
@@ -539,22 +609,25 @@ table.semanticForms :where(fieldset, label, input, select, textarea, button, men
539
609
  transition: none;
540
610
  }
541
611
  }
612
+ .semanticForms input:autofill,
613
+ .semanticForms textarea:autofill,
614
+ .semanticForms select:autofill {
615
+ box-shadow: inset 3px 0 0 var(--semanticFormsAutofillColor), inset 0 0 0 1000px var(--semanticFormsFormBgColor);
616
+ }
617
+ .semanticForms input:autofill:focus,
618
+ .semanticForms textarea:autofill:focus,
619
+ .semanticForms select:autofill:focus {
620
+ box-shadow: inset 0 0 0 2px var(--semanticFormsFocusColor), inset 3px 0 0 var(--semanticFormsAutofillColor), inset 0 0 0 1000px var(--semanticFormsFormBgColor);
621
+ }
542
622
  .semanticForms input:-webkit-autofill,
543
- .semanticForms input:-webkit-autofill:hover,
544
- .semanticForms input:-webkit-autofill:focus,
545
- .semanticForms input:-webkit-autofill:active,
546
623
  .semanticForms textarea:-webkit-autofill,
547
- .semanticForms textarea:-webkit-autofill:hover,
624
+ .semanticForms select:-webkit-autofill {
625
+ box-shadow: inset 3px 0 0 var(--semanticFormsAutofillColor), inset 0 0 0 1000px var(--semanticFormsFormBgColor);
626
+ }
627
+ .semanticForms input:-webkit-autofill:focus,
548
628
  .semanticForms textarea:-webkit-autofill:focus,
549
- .semanticForms textarea:-webkit-autofill:active,
550
- .semanticForms select:-webkit-autofill,
551
- .semanticForms select:-webkit-autofill:hover,
552
- .semanticForms select:-webkit-autofill:focus,
553
- .semanticForms select:-webkit-autofill:active {
554
- -webkit-box-shadow: 0 0 0 1000px var(--semanticFormsFormBgColor) inset;
555
- transition: background-color 5000s ease-in-out 0s, color 5000s ease-in-out 0s;
556
- transition-delay: 5000s;
557
- transition-property: background-color, color;
629
+ .semanticForms select:-webkit-autofill:focus {
630
+ box-shadow: inset 0 0 0 2px var(--semanticFormsFocusColor), inset 3px 0 0 var(--semanticFormsAutofillColor), inset 0 0 0 1000px var(--semanticFormsFormBgColor);
558
631
  }
559
632
  @supports (scrollbar-color: auto) {
560
633
  .semanticForms textarea {
@@ -596,6 +669,14 @@ table.semanticForms :where(fieldset, label, input, select, textarea, button, men
596
669
  .semanticFormsButton:where(button, input, a):active {
597
670
  transform: scale(0.97);
598
671
  }
672
+ @media (prefers-reduced-motion: reduce) {
673
+ .semanticFormsButton:where(button, input, a) {
674
+ transition: none;
675
+ }
676
+ .semanticFormsButton:where(button, input, a):active {
677
+ transform: none;
678
+ }
679
+ }
599
680
  .semanticFormsButton:where(button, input, a) {
600
681
  transition: filter 0.1s;
601
682
  }
@@ -709,6 +790,13 @@ table.semanticForms :where(fieldset, label, input, select, textarea, button, men
709
790
  pointer-events: none;
710
791
  transition: transform 250ms;
711
792
  cursor: text;
793
+ }
794
+ @media (prefers-reduced-motion: reduce) {
795
+ .semanticForms .floatLabelForm:not(:where(.customLayout, .customLayout *)) div dd:not(.singleCheckbox, .singleRadio, .checkboxes, .radios) label:first-of-type {
796
+ transition: none;
797
+ }
798
+ }
799
+ .semanticForms .floatLabelForm:not(:where(.customLayout, .customLayout *)) div dd:not(.singleCheckbox, .singleRadio, .checkboxes, .radios) label:first-of-type {
712
800
  flex: 1;
713
801
  white-space: nowrap;
714
802
  overflow: hidden;
@@ -1388,16 +1476,26 @@ form.semanticForms fieldset:has(dl:not(:where(.customLayout, .customLayout *)))
1388
1476
  .semanticForms .tabs.semanticFormsTabsActive button[role=tab]:hover:not([aria-selected=true]) {
1389
1477
  padding-bottom: 12px;
1390
1478
  }
1479
+ @media (prefers-reduced-motion: reduce) {
1480
+ .semanticForms .tabs.semanticFormsTabsActive button[role=tab] {
1481
+ transition: none;
1482
+ }
1483
+ .semanticForms .tabs.semanticFormsTabsActive button[role=tab]:hover:not([aria-selected=true]) {
1484
+ padding-bottom: 9px;
1485
+ }
1486
+ }
1391
1487
  .semanticForms .tabs.semanticFormsTabsActive button[role=tab][aria-selected=true] {
1392
1488
  background-image: none;
1393
1489
  background-color: var(--semanticFormsFormSubBgColor);
1394
- border-bottom-color: transparent;
1395
1490
  padding-bottom: 12px;
1396
1491
  }
1397
1492
  .semanticForms .tabs.semanticFormsTabsActive button[role=tab]:focus-visible {
1398
1493
  outline: none;
1399
1494
  box-shadow: inset 0 0 0 2px var(--semanticFormsFocusColor);
1400
1495
  }
1496
+ .semanticForms .tabs.semanticFormsTabsActive:not(.vertical) button[role=tab][aria-selected=true] {
1497
+ border-bottom-color: transparent;
1498
+ }
1401
1499
  .semanticForms .tabs.semanticFormsTabsActive > fieldset {
1402
1500
  margin: 0;
1403
1501
  border-top-left-radius: 0;
@@ -1406,6 +1504,65 @@ form.semanticForms fieldset:has(dl:not(:where(.customLayout, .customLayout *)))
1406
1504
  .semanticForms .tabs.semanticFormsTabsActive fieldset[hidden] {
1407
1505
  display: none;
1408
1506
  }
1507
+ .semanticForms .tabs.semanticFormsTabsActive.vertical {
1508
+ flex-direction: row;
1509
+ align-items: stretch;
1510
+ }
1511
+ .semanticForms .tabs.semanticFormsTabsActive.vertical .tabList {
1512
+ flex-direction: column;
1513
+ flex-wrap: nowrap;
1514
+ align-items: stretch;
1515
+ flex: none;
1516
+ max-width: 40%;
1517
+ margin-bottom: 0;
1518
+ margin-inline-end: -1px;
1519
+ }
1520
+ .semanticForms .tabs.semanticFormsTabsActive.vertical button[role=tab] {
1521
+ text-align: start;
1522
+ border-radius: 0;
1523
+ border-start-start-radius: var(--semanticFormsBorderRadius);
1524
+ border-end-start-radius: var(--semanticFormsBorderRadius);
1525
+ background-image: none;
1526
+ background-color: color-mix(in srgb, var(--semanticFormsButtonGradientLight), var(--semanticFormsButtonGradientDark));
1527
+ margin-inline-start: 3px;
1528
+ transition: margin-inline-start 120ms ease-out;
1529
+ }
1530
+ .semanticForms .tabs.semanticFormsTabsActive.vertical button[role=tab]:hover:not([aria-selected=true]) {
1531
+ padding-bottom: 9px;
1532
+ margin-inline-start: 0;
1533
+ }
1534
+ @media (prefers-reduced-motion: reduce) {
1535
+ .semanticForms .tabs.semanticFormsTabsActive.vertical button[role=tab] {
1536
+ transition: none;
1537
+ }
1538
+ .semanticForms .tabs.semanticFormsTabsActive.vertical button[role=tab]:hover:not([aria-selected=true]) {
1539
+ margin-inline-start: 3px;
1540
+ }
1541
+ }
1542
+ .semanticForms .tabs.semanticFormsTabsActive.vertical button[role=tab][aria-selected=true] {
1543
+ padding-bottom: 9px;
1544
+ margin-inline-start: 0;
1545
+ background-color: var(--semanticFormsFormSubBgColor);
1546
+ border-inline-end-width: 0;
1547
+ background-clip: padding-box;
1548
+ position: relative;
1549
+ z-index: 1;
1550
+ --semanticFormsTabJoin: 2px 0 0 -1px var(--semanticFormsFormSubBgColor);
1551
+ box-shadow: var(--semanticFormsTabJoin);
1552
+ }
1553
+ .semanticForms .tabs.semanticFormsTabsActive.vertical button[role=tab][aria-selected=true]:dir(rtl) {
1554
+ --semanticFormsTabJoin: -2px 0 0 -1px var(--semanticFormsFormSubBgColor);
1555
+ }
1556
+ .semanticForms .tabs.semanticFormsTabsActive.vertical button[role=tab][aria-selected=true]:focus-visible {
1557
+ box-shadow: inset 0 0 0 2px var(--semanticFormsFocusColor), var(--semanticFormsTabJoin);
1558
+ }
1559
+ .semanticForms .tabs.semanticFormsTabsActive.vertical > fieldset {
1560
+ flex: 1;
1561
+ min-width: 0;
1562
+ border-radius: var(--semanticFormsBorderRadius);
1563
+ border-start-start-radius: 0;
1564
+ border-end-start-radius: 0;
1565
+ }
1409
1566
  .semanticForms fieldset .tabs.semanticFormsTabsActive button[role=tab] {
1410
1567
  border: var(--semanticFormsNestedFieldsetBorder);
1411
1568
  }
@@ -1413,6 +1570,12 @@ form.semanticForms fieldset:has(dl:not(:where(.customLayout, .customLayout *)))
1413
1570
  background-color: var(--semanticFormsFormSubBgColor);
1414
1571
  background-image: linear-gradient(var(--semanticFormsNestedFieldsetBgColor), var(--semanticFormsNestedFieldsetBgColor));
1415
1572
  }
1573
+ .semanticForms fieldset .tabs.semanticFormsTabsActive.vertical button[role=tab][aria-selected=true] {
1574
+ --semanticFormsTabJoin: 2px 0 0 -1px var(--semanticFormsNestedFieldsetBgColor), 2px 0 0 -1px var(--semanticFormsFormSubBgColor);
1575
+ }
1576
+ .semanticForms fieldset .tabs.semanticFormsTabsActive.vertical button[role=tab][aria-selected=true]:dir(rtl) {
1577
+ --semanticFormsTabJoin: -2px 0 0 -1px var(--semanticFormsNestedFieldsetBgColor), -2px 0 0 -1px var(--semanticFormsFormSubBgColor);
1578
+ }
1416
1579
 
1417
1580
  form.semanticForms.lowFlow,
1418
1581
  form.semanticForms:not(.semanticFormsActive) {
@@ -1658,6 +1821,22 @@ form.semanticForms:not(.semanticFormsActive) dd:not(:where(.customLayout, .custo
1658
1821
  margin-top: 15px;
1659
1822
  margin-bottom: 15px;
1660
1823
  }
1824
+ @media (prefers-reduced-motion: reduce) {
1825
+ @supports (interpolate-size: allow-keywords) {
1826
+ .semanticForms details {
1827
+ transition: opacity 250ms ease-in, visibility 0ms ease-in 250ms;
1828
+ }
1829
+ .semanticForms details::details-content {
1830
+ transition: none;
1831
+ }
1832
+ }
1833
+ .semanticForms details summary {
1834
+ transition: none;
1835
+ }
1836
+ .semanticForms details summary::before {
1837
+ transition: none;
1838
+ }
1839
+ }
1661
1840
  .semanticForms details details,
1662
1841
  .semanticForms details fieldset {
1663
1842
  margin-top: 10px;
@@ -1 +1 @@
1
- {"version":3,"sourceRoot":"","sources":["../styles/globals.scss","../styles/inputs.scss","../styles/labels.scss","../styles/colspan.scss","../styles/tabs.scss","../styles/lowFlow.scss","../semanticForms.scss"],"names":[],"mappings":"AACA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EAEA;;AAEA;EA7BF;IA8BI;;;AA9BJ;EAiCE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EAEA;EAEA;;;AAGF;AAAA;EAEE;EACA;EACA;EACA;;AAEA;AAAA;EACE;EACA;EACA;;AAIF;EAdF;AAAA;IAeI;;;AAIF;AAAA;EACE;;AAIF;AAAA;EACE;;AAMF;AAAA;EACE;EACA;EACA;;;AAOJ;EACE;EACA;;;AAgDF;EACE;IA7CA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IAEA;;EAEA;IA8BA;MA7BE;;;EA6BF;IA1BA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IAGA;;EAEA;IACE;;;AAWJ;EAlDE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EAEA;;AAEA;EAmCF;IAlCI;;;AAkCJ;EA/BE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EAGA;;AAEA;EACE;;;AAeJ;EAtDE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EAEA;;AAEA;EAuCF;IAtCI;;;AAsCJ;EAnCE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;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A;AAAA;AAAA;AAAA;AAAA;EACE;;AAGF;AAAA;AAAA;AAAA;AAAA;EACE;EACA;;AAKF;AAAA;AAAA;EACE;;AAGF;AAAA;AAAA;EACE;EACA;;AAaN;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EAIA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;;AAGF;EACE;EACA;;AAGF;EACE;EACA;;AAIF;EAnCF;IAoCI;IACA;IACA;IACA;;;AAGF;EA1CF;IA2CI;;;AAKJ;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;EAYE;EACA;EACA;EACA;;AAIF;EACE;IACE;;EAEA;IACE;IACA;IACA;IACA;IACA;IACA;;EAIJ;IACE;;;;AAMN;EAjbE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;AA4ZJ;EAvZE;;AAEA;EACE;;AAoZJ;EAGE;;;ACnbA;AAAA;EAKE;EACA;EACA;EACA;EACA;EACA;;AAEA;AAAA;EACE;EACA;EACA;;AAGF;AAAA;EACE;EACA;EACA;EACA;;AAEA;AAAA;EACE;;AAQF;EACE;;AAEA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;EACA;;AAOF;EACE;EACA;;AAGF;EACE;EACA;EACA;EACA;;AASF;AAAA;AAAA;AAAA;AAAA;EAEE;EACA;EACA;;AAKJ;EACE;;AAOA;AAAA;AAAA;AAAA;AAAA;EAEE;;AAIJ;EAEE;;AAGF;AAAA;EAEE;;AAMF;EACE;EACA;EACA;EACA;EACA;EACA;EACA,aAlIa;EAmIb;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EAEA;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;;AAGF;EACE;EACA;EACA;EACA;;AAEA;EAC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;EACA;EACA;;AAKN;AAAA;EACE;EACA;;AAEA;AAAA;EACE;EACA;;AAIJ;AAAA;EACE;EACA;EACA;;AAEA;AAAA;EACE;EACA;;AAIJ;AAAA;EACE;EACA;;AAEA;AAAA;EACE;EACA;;AAIJ;AAAA;EACE;;AAEA;AAAA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;;AAKA;AAAA;EACE;EACA;;AASF;AAAA;AAAA;EACE;;AAKN;AAAA;AAAA;AAAA;EAEE;;AAGF;AAAA;EACE;EACA;;AAGA;AAAA;AAAA;EAEE;;AAGE;AAAA;AAAA;EACE;;AAGF;AAAA;AAAA;EACE;EACA;EACA;;AAKJ;AAAA;AAAA;EACE;EACA;;AAKJ;AAAA;AAAA;AAAA;AAAA;AAAA;EAGE;;AAIF;AAAA;EACE;EACA;EACA;EACA;;AAIF;AAAA;AAAA;AAAA;AAAA;AAAA;EAGE;;;ACzJJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAGA;EACE;EACA;EACA;;AASF;AAAA;AAAA;EAGE;;AAIJ;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;;AAGF;EAnBF;IAoBI;;EAEA;IACE;IACA;IACA;IACA;;;AAIJ;EACE;EACA;EACA;EACA;EACA;EAEA;EACA;EACA;;AAEA;EAEE;;AAGF;EAEE;EACA;EACA;EACA;EACA;EAEA;EAEA;EACA;EACA;EACA;;AAIJ;EACE;;AAEA;EACE;EACA;EACA;;AAGF;EACE;IACE;;;AAKF;EACE;;AAIJ;EACE;EACA;;AAKN;AAAA;EAEE;EACA;EACA;;AAGF;EACE;;AAGF;EACE;;AAIF;EACE;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;;AAEA;EACE;EACA;;AAEA;EACE;;AAEA;EAEE;EACA;EACA;;AAOJ;EACE;;AAIJ;EACE;EACA;EACA;EACA;EACA;;AAGA;EAEE;EACA;EACA;EACA;EACA;;AAGA;EACE;;AAIF;EACE;;AAIF;EACE;EACA;EACA;EACA;;AAIJ;EACE;;AAKA;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;;AAKJ;EACE;EACA;EACA;;AAKJ;EACE;;AAEA;EACE;;AAKJ;EACE;EACA;;AAEA;EACE;;AAIF;EACE;EACA;;AAIF;AAAA;AAAA;EAGE;EACA;EACA;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;;AAGF;AAAA;EAEE;EACA;;AASR;EACE;EACA;EACA;;AAIF;EACE;EACA;EACA;EACA;;AAIJ;AAAA;EAEE;EACA;EACA;EACA;EACA;;AAEA;AAAA;EACE;EACA;;AAIJ;EACE;EACA;;AAGF;EACE;EACA;;AAGF;EACE;EACA;;;AAIJ;AAAA;EAEE;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;AAAA;EACE;;AAGF;AAAA;EACE;EACA;;AAGF;AAAA;EACE;;AAGF;AAAA;EACE;;AAGF;AAAA;AAAA;EACE;EACA;EACA;;AAGF;AAAA;AAAA;EACE;;AAKA;AAAA;AAAA;AAAA;AAAA;EACE;;AAKJ;AAAA;EACE;;AAIF;AAAA;EACE","file":"semantic-forms.css"}
1
+ {"version":3,"sourceRoot":"","sources":["../styles/globals.scss","../styles/inputs.scss","../styles/labels.scss","../styles/colspan.scss","../styles/tabs.scss","../styles/lowFlow.scss","../semanticForms.scss"],"names":[],"mappings":"AACA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EAEA;;AAEA;EA9BF;IA+BI;;;AA/BJ;EAkCE;EACA;EAEA;;AAEA;EAvCF;IAwCI;;;AAxCJ;EA2CE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EAEA;EAEA;;;AAGF;AAAA;EAEE;EACA;EACA;EACA;;AAEA;AAAA;EACE;EACA;EACA;;AAIF;EAdF;AAAA;IAeI;;;AAIF;AAAA;EACE;;AAIF;AAAA;EACE;;AAMF;AAAA;EACE;EACA;EACA;;;AAOJ;EACE;EACA;;;AAwDF;EACE;IArDA;IACA;IACA;IACA;IACA;IAEA;IACA;IACA;IACA;IACA;IACA;IACA;IAEA;;EAEA;IAqCA;MApCE;;;EAoCF;IAjCA;IACA;IAEA;;EAEA;IA4BA;MA3BE;;;EA2BF;IAxBA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IAGA;;EAEA;IACE;;;AAWJ;EA1DE;EACA;EACA;EACA;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;EACA;EAEA;;AAEA;EA0CF;IAzCI;;;AAyCJ;EAtCE;EACA;EAEA;;AAEA;EAiCF;IAhCI;;;AAgCJ;EA7BE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EAGA;;AAEA;EACE;;;AAeJ;EA9DE;EACA;EACA;EACA;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;EACA;EAEA;;AAEA;EA8CF;IA7CI;;;AA6CJ;EA1CE;EACA;EAEA;;AAEA;EAqCF;IApCI;;;AAoCJ;EAjCE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EAGA;;AAEA;EACE;;;AAoBJ;EACE;;;AAGF;EACE;IACE;;;AAIJ;EACE;;;AAKF;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;ACrJA;AAAA;EAEE;;AAGF;EACE;EACA;EACA;EACA;;AAMA;AAAA;EACE;;AAIJ;AAAA;AAAA;EAGE;EACA;EACA;EACA;EACA;EACA;EACA;;AAKA;AAAA;AAAA;EACE;EACA;;AAGA;EALF;AAAA;AAAA;IAMI;IACA;;;AASJ;AAAA;AAAA;EACE;;AAQO;EACP;;;AAIO;EACP;;;AAGF;AAAA;AAAA;EACE;EACA;EACA;EACA;;AAIE;AAAA;AAAA;AAAA;AAAA;EACE;;AAKJ;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CF;IAyCI;IACA;IACA;IACA;;;AAGF;EA/CF;IAgDI;;;AAWJ;AAAA;AAAA;EAGE;;AAEA;AAAA;AAAA;EACE;;AAIJ;AAAA;AAAA;EAGE;;AAEA;AAAA;AAAA;EACE;;AAKJ;EACE;IACE;;EAEA;IACE;IACA;IACA;IACA;IACA;IACA;;EAIJ;IACE;;;;AAMN;EA7cE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;;AAIF;EAobF;IAnbI;;EAEA;IACE;;;AAgbN;EA1aE;;AAEA;EACE;;AAuaJ;EAGE;;;AC/cA;AAAA;EAKE;EACA;EACA;EACA;EACA;EACA;;AAEA;AAAA;EACE;EACA;EACA;;AAGF;AAAA;EACE;EACA;EACA;EACA;;AAEA;AAAA;EACE;;AAQF;EACE;;AAEA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;EACA;;AAOF;EACE;EACA;;AAGF;EACE;EACA;EACA;EACA;;AASF;AAAA;AAAA;AAAA;AAAA;EAEE;EACA;EACA;;AAKJ;EACE;;AAOA;AAAA;AAAA;AAAA;AAAA;EAEE;;AAIJ;EAEE;;AAGF;AAAA;EAEE;;AAMF;EACE;EACA;EACA;EACA;EACA;EACA;EACA,aAlIa;EAmIb;EACA;EACA;EACA;EACA;;AAGA;EAfF;IAgBI;;;AAhBJ;EAkBE;EACA;EACA;EACA;EACA;EAEA;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;;AAGF;EACE;EACA;EACA;EACA;;AAEA;EACE;;AAQJ;EACE;;AAGF;EAEE;;AAEA;EACE;;AAMF;EACE;;AAMN;EACE;EACA;EACA;EACA;;AAGF;AAAA;AAAA;EAGE;;AAGF;AAAA;EAEE;;AAGA;AAAA;EACE;EACA;;AAGF;AAAA;EACE;EACA;;AAGF;AAAA;EACE;EAC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F;EACE;;AAGF;EACE;;AAIF;EACE;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;;AAEA;EACE;EACA;;AAEA;EACE;;AAEA;EAEE;EACA;EACA;;AAOJ;EACE;;AAIJ;EACE;EACA;EACA;EACA;EACA;;AAGA;EAEE;EACA;EACA;EACA;EACA;;AAGA;EACE;;AAIF;EACE;;AAIF;EACE;EACA;EACA;EACA;;AAIJ;EACE;;AAKA;EACE;EACA;EACA;EACA;EACA;;AAEA;EACE;EACA;EACA;;AAKJ;EACE;EACA;EACA;;AAKJ;EACE;;AAEA;EACE;;AAKJ;EACE;EACA;;AAEA;EACE;;AAIF;EACE;EACA;;AAIF;AAAA;AAAA;EAGE;EACA;EACA;EACA;EAEA;EACA;EACA;EACA;EACA;EACA;;AAGF;AAAA;EAEE;EACA;;AASR;EACE;EACA;EACA;;AAIF;EACE;EACA;EACA;EACA;;AAIJ;AAAA;EAEE;EACA;EACA;EACA;EACA;;AAEA;AAAA;EACE;EACA;;AAIJ;EACE;EACA;;AAGF;EACE;EACA;;AAGF;EACE;EACA;;;AAIJ;AAAA;EAEE;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;AAAA;EACE;;AAGF;AAAA;EACE;EACA;;AAGF;AAAA;EACE;;AAGF;AAAA;EACE;;AAGF;AAAA;AAAA;EACE;EACA;EACA;;AAGF;AAAA;AAAA;EACE;;AAKA;AAAA;AAAA;AAAA;AAAA;EACE;;AAKJ;AAAA;EACE;;AAIF;AAAA;EACE","file":"semantic-forms.css"}
@@ -45,6 +45,18 @@ const waiting=new Map;let observer;const setInkOffset=(form,label)=>{if(!window.
45
45
  /***/866(module,__unused_webpack_exports,__webpack_require__){const{insertAfter}=__webpack_require__(584);const icons={passwordShow:'<svg fill="none" height="256" viewBox="0 0 24 24" width="256" xmlns="http://www.w3.org/2000/svg"><g stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"><path d="m1 12s4-8 11-8 11 8 11 8"/><path d="m1 12s4 8 11 8 11-8 11-8"/><circle cx="12" cy="12" r="3"/></g></svg>',passwordHide:'<svg fill="none" height="256" viewBox="0 0 24 24" width="256" xmlns="http://www.w3.org/2000/svg"><g stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"><path d="m2 2 20 20"/><path d="m6.71277 6.7226c-3.04798 2.07267-4.71277 5.2774-4.71277 5.2774s3.63636 7 10 7c2.0503 0 3.8174-.7266 5.2711-1.7116m-6.2711-12.23018c.3254-.03809.6588-.05822 1-.05822 6.3636 0 10 7 10 7s-.6918 1.3317-2 2.8335"/><path d="m14 14.2362c-.5308.475-1.2316.7639-2 .7639-1.6569 0-3-1.3431-3-3 0-.8237.33193-1.5698.86932-2.11192"/></g></svg>',helpIcon:'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="16" height="16" viewBox="0 0 16 16" version="1.1" style="overflow:visible;"><rect width="16" height="16" fill="none"/><path fill="currentColor" d="M8,10.5c-0.552,0-1,0.448-1,1c0,0.552,0.448,1,1,1c0.552,0,1-0.448,1-1C9,10.948,8.552,10.5,8,10.5z M8,0 C3.582,0,0,3.582,0,8c0,4.418,3.582,8,8,8s8-3.582,8-8C16,3.582,12.418,0,8,0z M12.243,12.243C11.109,13.376,9.603,14,8,14 s-3.109-0.624-4.243-1.757C2.624,11.109,2,9.603,2,8s0.624-3.109,1.757-4.243C4.891,2.624,6.397,2,8,2s3.109,0.624,4.243,1.757 C13.376,4.891,14,6.397,14,8C14,9.603,13.376,11.109,12.243,12.243z M7.927,3.755c-2.248,0-2.76,1.695-2.802,2.906h1.571 c0.028-0.256,0.101-1.418,1.221-1.418c0.672,0,1.206,0.406,1.206,1.175c0,0.695-0.724,1.155-1.303,1.711 C7.241,8.685,7.168,9.325,7.168,9.824V10c0.146,0,1.615,0,1.615,0V9.824c0-1.256,1.967-1.594,1.967-3.541 C10.75,5.059,9.874,3.755,7.927,3.755z"/></svg>'};const lookups={nodeName:["TEXTAREA","SELECT"],inputType:["checkbox","color","date","datetime-local","email","file","image","month","number","password","radio","range","search","tel","text","time","url","week"]};let lastFocusedInput;let lastClearFieldPressed;
46
46
  // browsers that implement the switch attribute expose it on the input prototype, render the control as a switch and report the switch role themselves, so nothing below is needed there
47
47
  const nativeSwitchSupport="switch"in window.HTMLInputElement.prototype;
48
+ // the stylesheet outlines a field on :user-invalid, which is the browser saying the visitor has had their turn with the field and what they left behind does not pass. aria-invalid has to say the same thing, or the outline is a message only someone looking at the screen receives
49
+
50
+ // it is read back from that selector rather than worked out again from blur events, which is how it is usually done and gets it wrong: tabbing straight through an empty required field is not a mistake the visitor has made yet, and :user-invalid already knows that
51
+ const supportsUserInvalid=(()=>{try{return window.CSS.supports("selector(:user-invalid)")}catch{return false}})();
52
+ // while setInvalid has marked a field, its message owns aria-invalid and this leaves the attribute alone
53
+ const syncAriaInvalid=input=>{if(!supportsUserInvalid||input.classList.contains("invalid"))return;if(input.matches(":user-invalid"))input.setAttribute("aria-invalid","true");else input.removeAttribute("aria-invalid")};
54
+ // blur and the invalid event are when the browser's answer can start being yes; input and change are when the visitor puts it right again
55
+ const trackUserInvalid=input=>{if(!supportsUserInvalid)return;const sync=()=>syncAriaInvalid(input);for(const name of["blur","input","change","invalid"])input.addEventListener(name,sync)};
56
+ // puts a field's help text where a screen reader will read it, which a title attribute does not do for a group of checkboxes or radios, and points the field at it
57
+
58
+ // the text is not drawn on screen: it stands in for the title the help icon carries, which only a mouse hovering the icon can reach
59
+ let helpTextCount=0;const describe=(inputs,text)=>{const host=inputs[0]?.closest("dd");if(!host)return;const note=document.createElement("span");note.className="semanticFormsVisuallyHidden";note.id=`semanticFormsHelpText_${++helpTextCount}`;note.textContent=text;host.append(note);for(const input of inputs){const describedBy=(input.getAttribute("aria-describedby")||"").split(" ").filter(Boolean);if(!describedBy.includes(note.id))input.setAttribute("aria-describedby",[...describedBy,note.id].join(" "))}};
48
60
  // lets a polyfilled switch be toggled by dragging its thumb, which is what the native control does. a pointer that never travels far enough is left alone so it still lands as a click.
49
61
  const enableSwitchDragging=input=>{input.addEventListener("pointerdown",event=>{if(input.disabled)return;const startX=event.clientX;const rightToLeft=window.getComputedStyle(input).direction==="rtl";
50
62
  // half the track is the distance the thumb travels between the two positions
@@ -65,6 +77,8 @@ const newInput=document.createElement("textarea");for(const attribute of input.a
65
77
  input.addEventListener("keypress",e=>{if(e.key!=="Enter"||e.key==="Enter"&&e.shiftKey)return;e.preventDefault();form.requestSubmit()});return input};
66
78
  // the behavior of the control itself, as opposed to the labels and buttons placed around it: switches and textareas. this is all a field in a customLayout element gets, and every other field gets it too
67
79
  const enhanceControl=(input,type,form)=>{
80
+ // what a screen reader is told about the field matches what the stylesheet draws on it
81
+ trackUserInvalid(input);
68
82
  // a checkbox with the switch attribute is a switch; the stylesheet draws one in every browser, and where the attribute is not implemented natively the role and dragging are supplied here
69
83
  if(type==="checkbox"&&input.hasAttribute("switch")&&!nativeSwitchSupport){input.setAttribute("role","switch");enableSwitchDragging(input)}
70
84
  // add listener to shift clear button when scrollbar present
@@ -109,13 +123,13 @@ const tree=input.getRootNode();const label=input.parentNode.parentNode.id&&(type
109
123
  // an input outside a <dd> is reported by the checks further down, so tolerate it here
110
124
  const isWrapped=input.closest("dd")?.parentElement.nodeName==="DIV";
111
125
  // #region create labels
112
- const newLabel=document.createElement("label");newLabel.className="floatLabelFormAnimatedLabel";if(type==="checkbox"||type==="radio"){const div=isWrapped?input.closest("dd").parentElement:document.createElement("div");const dt=label.closest("dt");const dd=input.closest("dd");if(!dt||!dd){console.error(`semantic-forms: Found an input (${input.id||input.getAttribute("name")}) that is not inside a <dd> element.`);return}if(dd.firstChild.nodeName!=="LABEL"){if(type==="checkbox"&&input.parentNode.nodeName==="DD"){newLabel.setAttribute("for",input.id);input.parentNode.classList.add("singleCheckbox");newLabel.className="";label.setAttribute("hidden","hidden");insertAfter(newLabel,input)}if(type==="radio"&&input.parentNode.nodeName==="DD"){newLabel.setAttribute("for",input.id);input.parentNode.classList.add("singleRadio");newLabel.className="";label.setAttribute("hidden","hidden");insertAfter(newLabel,input)}newLabel.innerHTML=label.innerHTML;if(label.hasAttribute("title")&&label.getAttribute("data-show-help-icon")!==null&&!label.querySelector("span.help")){const text=label.getAttribute("title");appendBadge(label,"help",text,icons.helpIcon);appendBadge(newLabel,"help",text,icons.helpIcon)}if(dd.querySelector(":required")&&label.getAttribute("data-no-asterisk")===null&&!label.querySelector("span.required")){const text=label.getAttribute("data-asterisk-text")||"This field is required.";appendBadge(label,"required",text,"*");appendBadge(newLabel,"required",text,"*")}if(!dd.querySelector("label"))dd.append(newLabel)}
126
+ const newLabel=document.createElement("label");newLabel.className="floatLabelFormAnimatedLabel";if(type==="checkbox"||type==="radio"){const div=isWrapped?input.closest("dd").parentElement:document.createElement("div");const dt=label.closest("dt");const dd=input.closest("dd");if(!dt||!dd){console.error(`semantic-forms: Found an input (${input.id||input.getAttribute("name")}) that is not inside a <dd> element.`);return}if(dd.firstChild.nodeName!=="LABEL"){if(type==="checkbox"&&input.parentNode.nodeName==="DD"){newLabel.setAttribute("for",input.id);input.parentNode.classList.add("singleCheckbox");newLabel.className="";label.setAttribute("hidden","hidden");insertAfter(newLabel,input)}if(type==="radio"&&input.parentNode.nodeName==="DD"){newLabel.setAttribute("for",input.id);input.parentNode.classList.add("singleRadio");newLabel.className="";label.setAttribute("hidden","hidden");insertAfter(newLabel,input)}newLabel.innerHTML=label.innerHTML;if(label.hasAttribute("title")&&label.getAttribute("data-show-help-icon")!==null&&!label.querySelector("span.help")){const text=label.getAttribute("title");appendBadge(label,"help",text,icons.helpIcon);appendBadge(newLabel,"help",text,icons.helpIcon);describe(dd.querySelectorAll("input"),text)}if(dd.querySelector(":required")&&label.getAttribute("data-no-asterisk")===null&&!label.querySelector("span.required")){const text=label.getAttribute("data-asterisk-text")||"This field is required.";appendBadge(label,"required",text,"*");appendBadge(newLabel,"required",text,"*")}if(!dd.querySelector("label"))dd.append(newLabel)}
113
127
  // if the user did not wrap the input in a div, do it for them
114
128
  if(!isWrapped){
115
129
  // the wrapper goes where the <dt> was, so the field keeps its place in the markup. a div the author wrote is already in the right place and is deliberately left where it is: moving it would push the field past anything the enhancer does not touch, such as a <dd> holding only a button
116
130
  dt.before(div);div.append(dt,dd);
117
131
  // determine visibility of newly created <div>
118
- if(dt.style.display==="none"&&dd.style.display==="none")div.style.display="none"}}else{newLabel.setAttribute("for",input.id);newLabel.innerHTML=label.innerHTML;if(input.hasAttribute("title")&&label.getAttribute("data-show-help-icon")!==null&&!label.querySelector("span.help"))appendBadge(newLabel,"help",input.getAttribute("title"),icons.helpIcon);if(input.hasAttribute("required")&&label.getAttribute("data-no-asterisk")===null&&!label.querySelector("span.required"))appendBadge(newLabel,"required",label.getAttribute("data-asterisk-text")||"This field is required.","*");label.setAttribute("hidden","hidden");insertAfter(newLabel,input)}
132
+ if(dt.style.display==="none"&&dd.style.display==="none")div.style.display="none"}}else{newLabel.setAttribute("for",input.id);newLabel.innerHTML=label.innerHTML;if(input.hasAttribute("title")&&label.getAttribute("data-show-help-icon")!==null&&!label.querySelector("span.help")){appendBadge(newLabel,"help",input.getAttribute("title"),icons.helpIcon);describe([input],input.getAttribute("title"))}if(input.hasAttribute("required")&&label.getAttribute("data-no-asterisk")===null&&!label.querySelector("span.required"))appendBadge(newLabel,"required",label.getAttribute("data-asterisk-text")||"This field is required.","*");label.setAttribute("hidden","hidden");insertAfter(newLabel,input)}
119
133
  // #endregion
120
134
  // #region standard inputs
121
135
  input=enhanceAutoGrow(input,form);if(type!=="checkbox"&&type!=="radio"){if(!input.getAttribute("placeholder"))input.setAttribute("placeholder"," ");const div=isWrapped?input.closest("dd").parentElement:document.createElement("div");const dt=label.closest("dt");const dd=input.closest("dd");if(!dt||!dd){console.error(`semantic-forms: Found an input (${input.id||input.getAttribute("name")}) that does not have a corresponding ${!dt?"<dt>":"<dd>"} element.`);return}
@@ -152,7 +166,9 @@ const displayRangeValue=(input,label)=>{const format=()=>(input.getAttribute("da
152
166
  // marks a field invalid, which the stylesheet outlines, with a message saying why, which screen readers read along with the field. options.messageIn is the element to put the message in; by default it goes after the field, where the stylesheet shows it
153
167
 
154
168
  // calling it again replaces the message, and clearInvalid undoes it
155
- const setInvalid=(input,message,options={})=>{input.classList.add("invalid");input.setAttribute("aria-invalid","true");const id=`${input.id||"semanticFormsField"}SemanticFormsInvalid`;let text=input.getRootNode().getElementById?.(id)||document.getElementById(id);if(!text){text=document.createElement("p");text.id=id;text.className="semanticFormsInvalidText";if(options.messageIn)options.messageIn.append(text);else input.parentNode.append(text)}text.textContent=message;const describedBy=(input.getAttribute("aria-describedby")||"").split(" ").filter(token=>token&&token!==id);input.setAttribute("aria-describedby",[...describedBy,id].join(" "))};const clearInvalid=input=>{input.classList.remove("invalid");input.removeAttribute("aria-invalid");const id=`${input.id||"semanticFormsField"}SemanticFormsInvalid`;const text=input.getRootNode().getElementById?.(id)||document.getElementById(id);text?.remove();const describedBy=(input.getAttribute("aria-describedby")||"").split(" ").filter(token=>token&&token!==id);if(describedBy.length)input.setAttribute("aria-describedby",describedBy.join(" "));else input.removeAttribute("aria-describedby")};const handleUndoRedo=event=>{
169
+ const setInvalid=(input,message,options={})=>{input.classList.add("invalid");input.setAttribute("aria-invalid","true");const id=`${input.id||"semanticFormsField"}SemanticFormsInvalid`;let text=input.getRootNode().getElementById?.(id)||document.getElementById(id);if(!text){text=document.createElement("p");text.id=id;text.className="semanticFormsInvalidText";if(options.messageIn)options.messageIn.append(text);else input.parentNode.append(text)}text.textContent=message;const describedBy=(input.getAttribute("aria-describedby")||"").split(" ").filter(token=>token&&token!==id);input.setAttribute("aria-describedby",[...describedBy,id].join(" "))};const clearInvalid=input=>{input.classList.remove("invalid");input.removeAttribute("aria-invalid");const id=`${input.id||"semanticFormsField"}SemanticFormsInvalid`;const text=input.getRootNode().getElementById?.(id)||document.getElementById(id);text?.remove();const describedBy=(input.getAttribute("aria-describedby")||"").split(" ").filter(token=>token&&token!==id);if(describedBy.length)input.setAttribute("aria-describedby",describedBy.join(" "));else input.removeAttribute("aria-describedby");
170
+ // the field may still be one the browser considers invalid, in which case the stylesheet is still outlining it and aria-invalid goes back to saying so
171
+ syncAriaInvalid(input)};const handleUndoRedo=event=>{
156
172
  // handle undo/redo
157
173
  if((event.ctrlKey||event.metaKey)&&event.key==="z"&&!event.shiftKey){
158
174
  // undo clearing a field
@@ -203,18 +219,20 @@ if(input.getAttribute("title"))input.setAttribute("title",input.getAttribute("ti
203
219
 
204
220
  // the tab that opens first is the one whose fieldset carries `data-selected`, or the first fieldset when none do
205
221
 
222
+ // adding the `vertical` class to the group puts the tabs in a column beside the panels, and the up and down arrow keys move between them in place of left and right
223
+
206
224
  // form: form element to search for tab groups
207
225
  const enhanceTabs=form=>{for(const group of form.querySelectorAll(".tabs:not(.semanticFormsTabsActive)")){const panels=Array.from(group.children).filter(child=>child.nodeName==="FIELDSET");
208
226
  // one fieldset is not a set of tabs, and no fieldsets means the class is on the wrong element
209
- if(panels.length<2){if(panels.length===0)console.error("semantic-forms: Found a .tabs element with no <fieldset> children. Each tab needs to be a <fieldset> with a <legend> naming it.",group);continue}group.classList.add("semanticFormsTabsActive");const groupId=++tabGroupCount;const tabList=document.createElement("div");const tabs=[];tabList.classList.add("tabList");tabList.setAttribute("role","tablist");
227
+ if(panels.length<2){if(panels.length===0)console.error("semantic-forms: Found a .tabs element with no <fieldset> children. Each tab needs to be a <fieldset> with a <legend> naming it.",group);continue}group.classList.add("semanticFormsTabsActive");const groupId=++tabGroupCount;const vertical=group.classList.contains("vertical");const tabList=document.createElement("div");const tabs=[];tabList.classList.add("tabList");tabList.setAttribute("role","tablist");tabList.setAttribute("aria-orientation",vertical?"vertical":"horizontal");
210
228
  // shows one panel and marks its tab as the selected one
211
229
  const selectTab=(index,moveFocus)=>{for(const[i,panel]of panels.entries())panel.hidden=i!==index;for(const[i,tab]of tabs.entries()){const selected=i===index;tab.setAttribute("aria-selected",selected?"true":"false");
212
230
  // only the selected tab is in the tab order; the arrow keys reach the others
213
231
  tab.tabIndex=selected?0:-1}if(moveFocus)tabs[index].focus()};for(const[index,panel]of panels.entries()){const legend=panel.querySelector("legend");const tab=document.createElement("button");tab.type="button";tab.setAttribute("role","tab");tab.id=`semanticFormsTab_${groupId}_${index}`;tab.textContent=legend?legend.textContent:`Tab ${index+1}`;if(!panel.id)panel.id=`semanticFormsTabPanel_${groupId}_${index}`;panel.setAttribute("role","tabpanel");panel.setAttribute("aria-labelledby",tab.id);tab.setAttribute("aria-controls",panel.id);
214
232
  // the tab now names the panel, so the legend would be read out twice
215
233
  if(legend)legend.hidden=true;tab.addEventListener("click",()=>selectTab(index));tabs.push(tab);tabList.append(tab)}
216
- // the arrow keys move between tabs, which is what a tablist is expected to do
217
- tabList.addEventListener("keydown",event=>{const current=tabs.indexOf(document.activeElement);if(current===-1)return;const keys={ArrowRight:(current+1)%tabs.length,ArrowLeft:(current-1+tabs.length)%tabs.length,Home:0,End:tabs.length-1};if(!(event.key in keys))return;event.preventDefault();selectTab(keys[event.key],true)});
234
+ // the arrow keys along the strip move between tabs, which is what a tablist is expected to do
235
+ const nextKey=vertical?"ArrowDown":"ArrowRight";const previousKey=vertical?"ArrowUp":"ArrowLeft";tabList.addEventListener("keydown",event=>{const current=tabs.indexOf(document.activeElement);if(current===-1)return;const keys={[nextKey]:(current+1)%tabs.length,[previousKey]:(current-1+tabs.length)%tabs.length,Home:0,End:tabs.length-1};if(!(event.key in keys))return;event.preventDefault();selectTab(keys[event.key],true)});
218
236
  // the panel carrying [data-selected] is the one that opens, defaulting to the first. without javascript every panel is on the page at once, so the attribute only means anything once the tabs have been built
219
237
  const marked=panels.filter(panel=>panel.hasAttribute("data-selected"));if(marked.length>1)console.error('semantic-forms: Found more than one <fieldset> with a "data-selected" attribute in a tab group. Only the first one will be selected.',group);group.prepend(tabList);selectTab(marked.length?panels.indexOf(marked[0]):0)}};module.exports={enhanceTabs}
220
238
  /***/},