@italia/radio 1.0.0-beta.6 → 1.0.0-beta.8

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.
package/dist/src/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  export { ItRadio } from './it-radio.js';
2
2
  export { ItRadioGroup } from './it-radio-group.js';
3
- import '../index-CXf6SDTu.js';
3
+ import '../index-DGrVJFtp.js';
4
4
  import 'lit/directive.js';
5
5
  import 'lit';
6
6
  import 'lit/decorators.js';
@@ -1,4 +1,4 @@
1
- import { _ as __decorate, a as __metadata, F as FormControl, b as FormControlController } from '../index-CXf6SDTu.js';
1
+ import { _ as __decorate, a as __metadata, F as FormControl, b as FormControlController } from '../index-DGrVJFtp.js';
2
2
  import { css, html } from 'lit';
3
3
  import { property, queryAssignedElements, customElement } from 'lit/decorators.js';
4
4
  import 'lit/directive.js';
@@ -525,6 +525,7 @@ progress {
525
525
  --bsi-form-control-label-color: var(--bsi-color-text-base);
526
526
  --bsi-form-control-text-color: var(--bsi-color-text-secondary);
527
527
  --bsi-form-control-font-size: var(--bsi-body-font-size);
528
+ --bsi-form-select-indicator: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='hsl%280, 0%, 32%%29' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
528
529
  --bsi-form-group-spacing-y: var(--bsi-spacing-m);
529
530
  --bsi-form-checkbox-border-color: var(--bsi-color-border-secondary);
530
531
  --bsi-form-checkbox-border-radius: var(--bsi-radius-smooth);
@@ -551,6 +552,7 @@ select {
551
552
  background-color: var(--bsi-form-control-background-color);
552
553
  color: var(--bsi-form-control-text-color);
553
554
  font-size: var(--bsi-form-control-font-size);
555
+ line-height: var(--bsi-font-leading-2);
554
556
  }
555
557
  input.disabled, input:disabled,
556
558
  textarea.disabled,
@@ -563,48 +565,44 @@ select:disabled {
563
565
  color: var(--bsi-color-text-disabled);
564
566
  }
565
567
 
568
+ input,
569
+ select {
570
+ padding-block: var(--bsi-spacing-3xs);
571
+ }
572
+
566
573
  /* stylelint-disable-next-line no-duplicate-selectors */
567
574
  input:focus,
568
575
  textarea:focus {
569
- outline: 3px solid transparent;
576
+ outline: var(--bsi-focus-outer-width) solid transparent;
570
577
  outline-offset: 3px;
571
- box-shadow: 0 0 0 2px var(--bsi-color-border-inverse), 0 0 0 5px var(--bsi-color-outline-focus) !important;
578
+ box-shadow: 0 0 0 var(--bsi-focus-inner-width) var(--bsi-focus-inner-color), 0 0 0 calc(var(--bsi-focus-inner-width) + var(--bsi-focus-outer-width)) var(--bsi-focus-outer-color) !important;
572
579
  }
573
580
 
574
581
  input::file-selector-button {
575
- margin: -0.375rem -0.75rem;
576
- padding: 0.375rem 0.75rem;
577
- border-width: 0;
578
- border-style: solid;
582
+ margin: 0;
583
+ padding: 0;
584
+ padding-inline-end: var(--bsi-spacing-m);
585
+ border: 0;
579
586
  border-radius: 0;
580
- border-color: inherit;
581
- color: hsl(0, 0%, 10%);
587
+ color: var(--bsi-color-text-base);
588
+ background-color: transparent;
582
589
  pointer-events: none;
583
- margin-inline-end: 0.75rem;
584
- border-inline-end-width: 0;
585
- background-color: hsl(0, 0%, 100%);
586
- transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
587
- }
588
- @media (prefers-reduced-motion: reduce) {
589
- input::file-selector-button {
590
- transition: none;
591
- }
592
- }
593
- input:hover:not(:disabled):not([readonly])::file-selector-button {
594
- background-color: rgb(242.25, 242.25, 242.25);
595
590
  }
596
591
  input[type=file] {
597
592
  overflow: hidden;
593
+ padding-block: max(0px, (var(--bsi-form-control-height) - 1lh - 2px) / 2);
598
594
  }
599
595
  input[type=file]:not(:disabled):not([readonly]) {
600
596
  cursor: pointer;
601
597
  }
602
598
  input::-webkit-date-and-time-value {
603
- height: 1.5em;
599
+ height: 1lh;
600
+ padding-block: max(0px, (var(--bsi-form-control-height) - 2px - 2 * var(--bsi-spacing-3xs) - 1lh) / 2);
601
+ text-align: start;
604
602
  }
605
603
 
606
604
  select {
607
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='hsl%280, 0%, 32%%29' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
605
+ background-image: var(--bsi-form-select-indicator, url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='hsl%280, 0%, 32%%29' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e"));
608
606
  background-repeat: no-repeat;
609
607
  background-position: right var(--bsi-form-control-spacing) center;
610
608
  background-size: 16px 12px;
@@ -613,7 +611,7 @@ select {
613
611
  select:focus {
614
612
  border-color: hsl(210, 17%, 44%);
615
613
  outline: 0;
616
- box-shadow: 0 0 0 0.25rem rgba(0, 102, 204, 0.25);
614
+ box-shadow: 0 0 0 0.25rem rgba(0%, 40%, 80%, 0.25);
617
615
  }
618
616
  select[multiple], select[size]:not([size="1"]) {
619
617
  padding-right: 0.75rem;
@@ -775,9 +773,9 @@ input::-webkit-datetime-edit {
775
773
  }
776
774
  .form-check [type=checkbox]:focus + label,
777
775
  .form-check [type=radio]:focus + label {
778
- border-color: hsl(0, 0%, 0%) !important;
779
- box-shadow: 0 0 0 2px var(--bsi-color-border-inverse), 0 0 0 5px var(--bsi-color-outline-focus) !important;
780
- outline: 3px solid transparent !important;
776
+ border-color: var(--bsi-focus-outer-color) !important;
777
+ box-shadow: 0 0 0 var(--bsi-focus-inner-width) var(--bsi-focus-inner-color), 0 0 0 calc(var(--bsi-focus-inner-width) + var(--bsi-focus-outer-width)) var(--bsi-focus-outer-color) !important;
778
+ outline: var(--bsi-focus-outer-width) solid transparent !important;
781
779
  outline-offset: 3px !important;
782
780
  }
783
781
  .form-check [type=checkbox]:focus[data-focus-mouse=true] + label,
@@ -798,12 +796,14 @@ input::-webkit-datetime-edit {
798
796
  }
799
797
  .form-check input[type=checkbox] + label::after {
800
798
  top: 0;
799
+ top: max(0px, (1lh - 20px) / 2);
801
800
  width: 20px;
802
801
  height: 20px;
803
802
  border-radius: var(--bsi-form-checkbox-border-radius);
804
803
  }
805
804
  .form-check input[type=checkbox]:checked + label::before {
806
805
  top: 3px;
806
+ top: calc(3px + max(0px, (1lh - 20px) / 2));
807
807
  left: 3px;
808
808
  width: 6px;
809
809
  height: 12px;
@@ -827,6 +827,7 @@ input::-webkit-datetime-edit {
827
827
  }
828
828
  .form-check input[type=checkbox]:not(:checked) + label::before {
829
829
  top: 10px;
830
+ top: calc(10px + max(0px, (1lh - 20px) / 2));
830
831
  left: 6px;
831
832
  width: 0;
832
833
  height: 0;
@@ -850,6 +851,7 @@ input::-webkit-datetime-edit {
850
851
  .form-check input[type=radio] + label::after, .form-check input[type=radio] + label::before {
851
852
  position: absolute;
852
853
  top: 0;
854
+ top: max(0px, (1lh - 20px) / 2);
853
855
  left: 0;
854
856
  z-index: 0;
855
857
  content: "";
@@ -860,6 +862,14 @@ input::-webkit-datetime-edit {
860
862
  border-radius: var(--bsi-radius-rounded);
861
863
  transition: all var(--bsi-transition-instant) ease-out;
862
864
  }
865
+ .form-check input[type=radio] + label::after {
866
+ top: 4px;
867
+ top: calc(4px + max(0px, (1lh - 20px) / 2));
868
+ left: 4px;
869
+ width: 12px;
870
+ height: 12px;
871
+ border-width: 0;
872
+ }
863
873
  .form-check input[type=radio]:not(:checked) + label::after, .form-check input[type=radio]:not(:checked) + label::before {
864
874
  border-color: var(--bsi-form-checkbox-border-color);
865
875
  }
@@ -871,7 +881,7 @@ input::-webkit-datetime-edit {
871
881
  z-index: 0;
872
882
  border-color: var(--bsi-form-checked-color);
873
883
  background-color: var(--bsi-form-checked-color);
874
- transform: scale(0.64);
884
+ transform: none;
875
885
  }
876
886
  .form-check input[type=radio]:checked + label::before {
877
887
  border-color: var(--bsi-form-checked-color);
@@ -920,12 +930,16 @@ input::-webkit-datetime-edit {
920
930
  .form-check.form-check-group input[type=radio]:checked + label::before {
921
931
  right: 0;
922
932
  }
933
+ .form-check.form-check-group input[type=radio] + label::after {
934
+ right: 4px;
935
+ }
923
936
  .form-check.form-check-group input.semi-checked:not(:checked) + label::before {
924
937
  right: 4px;
925
938
  left: auto;
926
939
  }
927
940
  .form-check input.semi-checked:not(:checked) + label::before {
928
941
  top: 12px;
942
+ top: calc(12px + max(0px, (1lh - 20px) / 2));
929
943
  left: 4px;
930
944
  width: 12px;
931
945
  height: 2px;
@@ -996,163 +1010,12 @@ input::-webkit-datetime-edit {
996
1010
  --bsi-form-control-spacing: var(--bsi-spacing-xxs) var(--bsi-spacing-3xs);
997
1011
  --bsi-form-control-font-size: var(--bsi-label-font-size);
998
1012
  }
999
- .form-control-sm::file-selector-button {
1000
- padding: 0.25rem 0.5rem;
1001
- margin: -0.25rem -0.5rem;
1002
- margin-inline-end: 0.5rem;
1003
- }
1004
1013
 
1005
1014
  .form-control-lg {
1006
1015
  --bsi-form-control-font-size: var(--bsi-lead-font-size);
1007
1016
  }
1008
- .form-control-lg::file-selector-button {
1009
- padding: 0.5rem 1rem;
1010
- margin: -0.5rem -1rem;
1011
- margin-inline-end: 1rem;
1012
- }
1013
-
1014
- textarea.form-control {
1015
- min-height: 2.5rem;
1016
- border: 1px solid hsl(210, 17%, 44%);
1017
- }
1018
- textarea.form-control-sm {
1019
- min-height: calc(1.5em + 0.5rem);
1020
- }
1021
- textarea.form-control-lg {
1022
- min-height: calc(1.5em + 1rem);
1023
- }
1024
-
1025
- .form-control-color {
1026
- width: 3rem;
1027
- height: 2.5rem;
1028
- padding: 0.375rem;
1029
- }
1030
- .form-control-color:not(:disabled):not([readonly]) {
1031
- cursor: pointer;
1032
- }
1033
- .form-control-color::-moz-color-swatch {
1034
- border: 0 !important;
1035
- border-radius: 0;
1036
- }
1037
- .form-control-color::-webkit-color-swatch {
1038
- border-radius: 0;
1039
- }
1040
- .form-control-color.form-control-sm {
1041
- height: calc(1.5em + 0.5rem);
1042
- }
1043
- .form-control-color.form-control-lg {
1044
- height: calc(1.5em + 1rem);
1045
- }
1046
-
1047
- .form-check-reverse {
1048
- padding-right: 1.5em;
1049
- padding-left: 0;
1050
- text-align: right;
1051
- }
1052
- .form-check-reverse .form-check-input {
1053
- float: right;
1054
- margin-right: -1.5em;
1055
- margin-left: 0;
1056
- }
1057
-
1058
- .form-check-input {
1059
- width: 1em;
1060
- height: 1em;
1061
- margin-top: 0.25em;
1062
- vertical-align: top;
1063
- background-color: hsl(0, 0%, 100%);
1064
- background-repeat: no-repeat;
1065
- background-position: center;
1066
- background-size: contain;
1067
- border: 1px solid rgba(0, 0, 0, 0.25);
1068
- appearance: none;
1069
- print-color-adjust: exact;
1070
- }
1071
- .form-check-input[type=checkbox] {
1072
- border-radius: 0.25em;
1073
- }
1074
- .form-check-input[type=radio] {
1075
- border-radius: 50%;
1076
- }
1077
- .form-check-input:active {
1078
- filter: brightness(90%);
1079
- }
1080
- .form-check-input:focus {
1081
- border-color: hsl(210, 17%, 44%);
1082
- outline: 0;
1083
- box-shadow: 0 0 0 0.25rem rgba(0, 102, 204, 0.25);
1084
- }
1085
- .form-check-input:checked {
1086
- background-color: hsl(210, 100%, 40%);
1087
- border-color: hsl(210, 100%, 40%);
1088
- }
1089
- .form-check-input:checked[type=checkbox] {
1090
- background-image: escape-svg(url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'><path fill='none' stroke='hsl(0, 0%, 100%)' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='m6 10 3 3 6-6'/></svg>"));
1091
- }
1092
- .form-check-input:checked[type=radio] {
1093
- background-image: escape-svg(url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'><circle r='2' fill='hsl(0, 0%, 100%)'/></svg>"));
1094
- }
1095
- .form-check-input[type=checkbox]:indeterminate {
1096
- background-color: hsl(210, 100%, 40%);
1097
- border-color: hsl(210, 100%, 40%);
1098
- background-image: escape-svg(url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'><path fill='none' stroke='hsl(0, 0%, 100%)' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='M6 10h8'/></svg>"));
1099
- }
1100
- .form-check-input:disabled {
1101
- pointer-events: none;
1102
- filter: none;
1103
- opacity: 0.5;
1104
- }
1105
- .form-check-input[disabled] ~ .form-check-label, .form-check-input:disabled ~ .form-check-label {
1106
- cursor: default;
1107
- opacity: 0.5;
1108
- }
1109
-
1110
- .form-switch {
1111
- padding-left: 2.5em;
1112
- }
1113
- .form-switch .form-check-input {
1114
- width: 2em;
1115
- margin-left: -2.5em;
1116
- background-image: escape-svg(url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'><circle r='3' fill='rgba(0, 0, 0, 0.25)'/></svg>"));
1117
- background-position: left center;
1118
- border-radius: 2em;
1119
- transition: background-position 0.15s ease-in-out;
1120
- }
1121
- @media (prefers-reduced-motion: reduce) {
1122
- .form-switch .form-check-input {
1123
- transition: none;
1124
- }
1125
- }
1126
- .form-switch .form-check-input:focus {
1127
- background-image: escape-svg(url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'><circle r='3' fill='hsl(210, 17%, 44%)'/></svg>"));
1128
- }
1129
- .form-switch .form-check-input:checked {
1130
- background-position: right center;
1131
- background-image: escape-svg(url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'><circle r='3' fill='hsl(0, 0%, 100%)'/></svg>"));
1132
- }
1133
- .form-switch.form-check-reverse {
1134
- padding-right: 2.5em;
1135
- padding-left: 0;
1136
- }
1137
- .form-switch.form-check-reverse .form-check-input {
1138
- margin-right: -2.5em;
1139
- margin-left: 0;
1140
- }
1141
-
1142
- .form-check-inline {
1143
- display: inline-block;
1144
- margin-right: 1rem;
1145
- }
1146
-
1147
- .btn-check {
1148
- position: absolute;
1149
- clip: rect(0, 0, 0, 0);
1150
- pointer-events: none;
1151
- }
1152
- .btn-check[disabled] + .btn, .btn-check:disabled + .btn {
1153
- pointer-events: none;
1154
- filter: none;
1155
- opacity: 0.65;
1017
+ .form-control-lg, .form-control-lg + .password-icon {
1018
+ --bsi-form-control-height: 3rem;
1156
1019
  }
1157
1020
 
1158
1021
  .form-feedback {
@@ -1161,21 +1024,26 @@ textarea.form-control-lg {
1161
1024
  font-size: 0.75rem;
1162
1025
  }
1163
1026
 
1164
- .input-group-text:has(~ [data-focus-mouse=true]:not(.btn)),
1165
- [data-focus-mouse=true]:not(.btn) ~ .input-group-text,
1166
- button:has(~ [data-focus-mouse=true]:not(.btn)),
1167
- [data-focus-mouse=true]:not(.btn) + button {
1027
+ .input-group .input-group-text:has(~ [data-focus-mouse=true]:not(.btn)),
1028
+ .input-group [data-focus-mouse=true]:not(.btn) ~ .input-group-text,
1029
+ .input-group button:has(~ [data-focus-mouse=true]:not(.btn)),
1030
+ .input-group [data-focus-mouse=true]:not(.btn) + button {
1168
1031
  border-color: inherit !important;
1169
1032
  box-shadow: none !important;
1170
1033
  outline: none !important;
1171
1034
  }
1172
-
1173
- .input-group-text:has(~ .is-invalid),
1174
- .is-invalid ~ .input-group-text,
1175
- button:has(~ .is-invalid),
1176
- .is-invalid + button {
1035
+ .input-group .input-group-text:has(~ .is-invalid),
1036
+ .input-group .is-invalid ~ .input-group-text,
1037
+ .input-group button:has(~ .is-invalid),
1038
+ .input-group .is-invalid + button {
1177
1039
  border-color: var(--bsi-color-border-danger) !important;
1178
1040
  }
1041
+ .input-group .input-group-text:has(~ .is-valid),
1042
+ .input-group .is-valid ~ .input-group-text,
1043
+ .input-group button:has(~ .is-valid),
1044
+ .input-group .is-valid + button {
1045
+ border-color: var(--bsi-color-border-success);
1046
+ }
1179
1047
 
1180
1048
  .sr-only-justvalidate-bi {
1181
1049
  display: none;
@@ -1190,17 +1058,20 @@ button:has(~ .is-invalid),
1190
1058
  padding-right: calc(1.5em + 0.75rem + var(--bsi-form-control-spacing) + 1rem) !important;
1191
1059
  }
1192
1060
 
1193
- .was-validated &:valid,
1061
+ .was-validated .form-control:valid,
1062
+ .was-validated select:valid,
1194
1063
  .is-valid {
1195
1064
  border-color: var(--bsi-color-border-success) !important;
1196
1065
  background-image: url('data:image/svg+xml,<svg width="24" height="24" viewBox="0 0 24 24" fill="%23008055" xmlns="http://www.w3.org/2000/svg"><path d="M9.6,16.9L4,11.4l0.8-0.7l4.8,4.8l8.5-8.4l0.7,0.7L9.6,16.9z" /></svg>');
1197
1066
  }
1198
- .was-validated &:valid ~ .warning-feedback,
1067
+ .was-validated .form-control:valid ~ .warning-feedback,
1068
+ .was-validated select:valid ~ .warning-feedback,
1199
1069
  .is-valid ~ .warning-feedback {
1200
1070
  display: block;
1201
1071
  }
1202
1072
 
1203
- .was-validated &:invalid,
1073
+ .was-validated .form-control:invalid,
1074
+ .was-validated select:invalid,
1204
1075
  .is-invalid {
1205
1076
  border-color: var(--bsi-color-border-danger) !important;
1206
1077
  background-image: url('data:image/svg+xml,<svg width="24" fill="%23cc334d" height="24" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12.7,12l6.7,6.6l-0.8,0.8L12,12.7l-6.6,6.7l-0.8-0.8l6.7-6.6L4.6,5.4l0.8-0.8l6.6,6.7l6.6-6.7l0.8,0.8L12.7,12z" /></svg>');
@@ -1211,13 +1082,6 @@ button:has(~ .is-invalid),
1211
1082
  background-image: url('data:image/svg+xml,<svg width="24" height="24" fill="%23995c00" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12.5,17h-1V2h1V17z M12.5,20h-1v2h1V20z" /></svg>');
1212
1083
  }
1213
1084
 
1214
- .input-group-text:has(~ .is-valid),
1215
- .is-valid ~ .input-group-text,
1216
- button:has(~ .is-valid),
1217
- .is-valid + button {
1218
- border-color: var(--bsi-color-border-success);
1219
- }
1220
-
1221
1085
  .is-valid + .input-group-text.align-buttons,
1222
1086
  .is-invalid + .input-group-text.align-buttons {
1223
1087
  right: 30px;
@@ -1237,7 +1101,7 @@ textarea.form-control {
1237
1101
 
1238
1102
  ::slotted([slot=label]) {
1239
1103
  display: block;
1240
- padding: 0 var(--bsi-form-input-spacing-x);
1104
+ padding: 0;
1241
1105
  margin-bottom: var(--bsi-spacing-s);
1242
1106
  background-color: rgba(0, 0, 0, 0);
1243
1107
  color: var(--bsi-form-control-text-color);
@@ -1253,7 +1117,7 @@ textarea.form-control {
1253
1117
  display: flex;
1254
1118
  flex-wrap: wrap;
1255
1119
  align-items: center;
1256
- gap: var(--bsi-spacing-s);
1120
+ row-gap: var(--bsi-spacing-s);
1257
1121
  }`;
1258
1122
 
1259
1123
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"it-radio-group.js","sources":["../../../globals/dist/src/controllers/roving-tabindex-controller.js","../../../src/it-radio-group.ts"],"sourcesContent":["/**\n * Roving Tabindex Controller\n *\n * Implements the ARIA roving tabindex pattern for keyboard navigation.\n * See: https://www.w3.org/WAI/ARIA/apg/practices/keyboard-interface/#kbd_roving_tabindex\n *\n * Usage:\n * ```ts\n * private rovingTabindex = new RovingTabindexController(this, {\n * getItems: () => Array.from(this.querySelectorAll('my-item')),\n * onSelect: (item) => this.selectItem(item),\n * });\n * ```\n */\nexport class RovingTabindexController {\n constructor(host, config) {\n this.host = host;\n this.config = {\n wrap: true,\n direction: 'both',\n selectOnFocus: false,\n selectOnHomeEnd: false,\n skipItem: (item) => item.hasAttribute('disabled') || item.disabled === true,\n ...config,\n };\n host.addController(this);\n }\n // eslint-disable-next-line class-methods-use-this\n hostConnected() {\n // Controller is ready when host connects\n }\n // eslint-disable-next-line class-methods-use-this\n hostDisconnected() {\n // Cleanup if needed\n }\n /**\n * Update tabindex values for all items\n * @param activeIndex - Index of the item that should be tabbable (default: 0 or first non-disabled)\n */\n updateTabindices(activeIndex) {\n const items = this.config.getItems();\n if (!items || items.length === 0) {\n return;\n }\n // Find the active index\n let targetIndex = activeIndex ?? 0;\n // If no active index specified, use first non-disabled item\n if (activeIndex === undefined) {\n targetIndex = items.findIndex((item) => !this.config.skipItem(item));\n if (targetIndex === -1) {\n targetIndex = 0; // Fallback to first item if all disabled\n }\n }\n // Set tabindex for all items\n items.forEach((item, index) => {\n const itemElement = item;\n if (this.config.skipItem(itemElement)) {\n // eslint-disable-next-line no-param-reassign\n itemElement.tabIndex = -1;\n }\n else {\n // eslint-disable-next-line no-param-reassign\n itemElement.tabIndex = index === targetIndex ? 0 : -1;\n }\n });\n }\n /**\n * Handle keyboard navigation\n * @param currentItem - The currently focused item\n * @param event - The keyboard event\n * @returns true if the event was handled, false otherwise\n */\n handleKeydown(currentItem, event) {\n const direction = typeof this.config.direction === 'function' ? this.config.direction() : this.config.direction;\n const { key } = event;\n // Determine if this key should be handled based on direction\n const isVertical = key === 'ArrowUp' || key === 'ArrowDown';\n const isHorizontal = key === 'ArrowLeft' || key === 'ArrowRight';\n const isHome = key === 'Home';\n const isEnd = key === 'End';\n const shouldHandle = isHome ||\n isEnd ||\n (direction === 'both' && (isVertical || isHorizontal)) ||\n (direction === 'vertical' && isVertical) ||\n (direction === 'horizontal' && isHorizontal);\n if (!shouldHandle) {\n return false;\n }\n // Prevent default behavior (page scrolling)\n event.preventDefault();\n const items = this.config.getItems();\n const currentIndex = items.indexOf(currentItem);\n if (currentIndex === -1) {\n return false;\n }\n let nextIndex = currentIndex;\n // Handle Home/End keys\n if (isHome) {\n nextIndex = 0;\n }\n else if (isEnd) {\n nextIndex = items.length - 1;\n }\n else {\n // Handle arrow keys\n const isNext = key === 'ArrowDown' || key === 'ArrowRight';\n const isPrev = key === 'ArrowUp' || key === 'ArrowLeft';\n if (isNext) {\n nextIndex = this.getNextIndex(items, currentIndex, 1);\n }\n else if (isPrev) {\n nextIndex = this.getNextIndex(items, currentIndex, -1);\n }\n }\n // Skip disabled items — Home always searches forward, End always searches backward\n // eslint-disable-next-line no-nested-ternary\n const searchDirection = isHome ? 1 : isEnd ? -1 : nextIndex > currentIndex ? 1 : -1;\n nextIndex = this.findNextValidIndex(items, nextIndex, searchDirection);\n if (nextIndex !== -1 && nextIndex !== currentIndex) {\n const nextItem = items[nextIndex];\n // Update tabindices\n this.updateTabindices(nextIndex);\n // Focus the next item\n nextItem.focus();\n // Optionally select/activate the item.\n // Select when `selectOnFocus` is enabled, or when Home/End keys\n // were used and the consumer explicitly opted in via `selectOnHomeEnd`.\n const shouldSelect = this.config.selectOnFocus === true || ((isHome || isEnd) && this.config.selectOnHomeEnd === true);\n if (shouldSelect && this.config.onSelect) {\n this.config.onSelect(nextItem, event);\n }\n return true;\n }\n return false;\n }\n /**\n * Get the next index based on direction\n */\n getNextIndex(items, currentIndex, direction) {\n const { wrap } = this.config;\n let nextIndex = currentIndex + direction;\n if (wrap) {\n // Wrap around\n if (nextIndex < 0) {\n nextIndex = items.length - 1;\n }\n else if (nextIndex >= items.length) {\n nextIndex = 0;\n }\n }\n else {\n // Clamp to bounds\n nextIndex = Math.max(0, Math.min(items.length - 1, nextIndex));\n }\n return nextIndex;\n }\n /**\n * Find the next valid (non-disabled) index\n */\n findNextValidIndex(items, startIndex, direction) {\n const maxAttempts = items.length;\n let attempts = 0;\n let index = startIndex;\n while (attempts < maxAttempts) {\n if (!this.config.skipItem(items[index])) {\n return index;\n }\n index = this.getNextIndex(items, index, direction);\n attempts += 1;\n }\n // All items are disabled\n return -1;\n }\n /**\n * Set focus to a specific item\n */\n focusItem(item) {\n const items = this.config.getItems();\n const index = items.indexOf(item);\n if (index !== -1) {\n this.updateTabindices(index);\n item.focus();\n }\n }\n /**\n * Set focus to the first non-disabled item\n */\n focusFirst() {\n const items = this.config.getItems();\n const firstValidIndex = this.findNextValidIndex(items, 0, 1);\n if (firstValidIndex !== -1) {\n this.focusItem(items[firstValidIndex]);\n }\n }\n /**\n * Set focus to the last non-disabled item\n */\n focusLast() {\n const items = this.config.getItems();\n const lastValidIndex = this.findNextValidIndex(items, items.length - 1, -1);\n if (lastValidIndex !== -1) {\n this.focusItem(items[lastValidIndex]);\n }\n }\n}\n//# sourceMappingURL=roving-tabindex-controller.js.map","import { html, PropertyValues } from 'lit';\nimport { customElement, property, queryAssignedElements } from 'lit/decorators.js';\nimport { FormControl, FormControlController, RovingTabindexController } from '@italia/globals';\nimport type { ItRadio } from '@italia/radio';\nimport styles from './radio-group.scss';\n\n/**\n * Radio group component - manages a collection of radio buttons\n *\n * @element it-radio-group\n * @slot - Contains the `<it-radio>` elements\n *\n */\n@customElement('it-radio-group')\nexport class ItRadioGroup extends FormControl {\n static styles = styles;\n\n static formAssociated = true;\n\n /**\n * The name of the radio group, used for form submission\n */\n @property({ type: String })\n name = '';\n\n /**\n * The currently selected value\n */\n @property({ type: String, reflect: true })\n value = '';\n\n /**\n * Whether the radio group is disabled\n */\n @property({ type: Boolean, reflect: true })\n disabled = false;\n\n /**\n * Whether a selection is required\n */\n @property({ type: Boolean, reflect: true })\n required = false;\n\n /**\n * Optional prop for visual styling of grouped radios (borders between radios)\n */\n @property({ type: Boolean, reflect: true })\n grouped = false;\n\n /**\n * Whether the radios are displayed inline (horizontally) or stacked (vertically)\n */\n @property({ type: Boolean, reflect: true })\n inline = false;\n\n /**\n * Get all slotted radio buttons\n */\n @queryAssignedElements()\n protected _radios!: ItRadio[];\n\n @queryAssignedElements({ slot: 'label' })\n private _label!: HTMLElement[];\n\n /**\n * Roving tabindex controller for keyboard navigation\n */\n protected rovingTabindex = new RovingTabindexController<ItRadio>(this, {\n getItems: () => this._radios,\n onSelect: (radio, event) => this.selectRadio(radio, event),\n direction: 'both',\n selectOnFocus: true,\n });\n\n /**\n * Form control integration\n */\n private _formController = new FormControlController(this as any, {\n value: () => this.value,\n // disabled: () => this.disabled,\n setValue: (control: FormControl, value: unknown) => {\n const radioGroup = control as ItRadioGroup;\n radioGroup.value = value as string;\n },\n });\n\n /**\n * Override: Custom validity check for radio group\n */\n override get validity(): ValidityState {\n // Fallback: create a custom ValidityState-like object\n const valid = !this.required || !!this.value;\n return {\n valid,\n valueMissing: this.required && !this.value,\n typeMismatch: false,\n patternMismatch: false,\n tooLong: false,\n tooShort: false,\n rangeUnderflow: false,\n rangeOverflow: false,\n stepMismatch: false,\n badInput: false,\n customError: false,\n } as ValidityState;\n }\n\n /**\n * Override: Check validity for radio group\n */\n override checkValidity(): boolean {\n if (this.required && !this.value) {\n return false;\n }\n return true;\n }\n\n /**\n * Override: Report validity for radio group\n */\n override reportValidity(): boolean {\n const isValid = this.checkValidity();\n this.handleValidationMessages();\n this._updateInvalidState();\n return isValid;\n }\n\n /** Sets a custom validation message. Pass an empty string to restore validity. */\n public override setCustomValidity(message: string) {\n // Only trigger validation state if message is non-empty (actual error)\n // Empty message during init or after correction should not trigger invalid state initially\n\n this.validationMessage = message;\n this.formControlController.updateValidity();\n // Update aria-invalid on group and children immediately\n this._updateInvalidState();\n }\n\n protected override handleValidationMessages() {\n const _v = this.validity;\n if (!this.customValidation) {\n if (_v.valueMissing) {\n this.setCustomValidity(this.$t('validityRequired'));\n } else this.setCustomValidity('');\n }\n }\n\n private _updateInvalidState() {\n // Only show aria-invalid if validation has been triggered (ARIA best practice)\n\n const invalid = this.checkValidity() === false || !!this.validationMessage;\n if (invalid) this.setAttribute('aria-invalid', 'true');\n else this.removeAttribute('aria-invalid');\n this._radios?.forEach((r) => {\n if (invalid) r.setAttribute('aria-invalid', 'true');\n else r.removeAttribute('aria-invalid');\n });\n\n // Update validation message in light DOM\n this._updateValidationMessage();\n }\n\n /**\n * Update validation message in light DOM (for aria-describedby cross-boundary support)\n */\n private _updateValidationMessage() {\n const validityMessage = this.validationMessage;\n const messageId = `invalid-feedback-${this._id}`;\n\n // Find or create validation message element in light DOM\n let messageEl = this.querySelector(`[slot=\"validation-message\"]`);\n\n if (validityMessage && validityMessage.length > 0) {\n // Create message element if it doesn't exist\n if (!messageEl) {\n messageEl = document.createElement('div');\n messageEl.setAttribute('slot', 'validation-message');\n this.appendChild(messageEl);\n }\n\n // Update message content and attributes\n messageEl.id = messageId;\n messageEl.className = 'form-feedback text-danger';\n messageEl.setAttribute('role', 'alert');\n messageEl.removeAttribute('hidden');\n\n const labelText = this._label?.[0]?.textContent || '';\n messageEl.innerHTML = `<span class=\"visually-hidden\">${labelText}: </span>${validityMessage}`;\n\n // Update aria-describedby on host\n const existingDescribedBy = this._ariaAttributes['aria-describedby'] || '';\n const ariaDescribedBy = existingDescribedBy ? `${existingDescribedBy} ${messageId}` : messageId;\n this.setAttribute('aria-describedby', ariaDescribedBy);\n } else {\n // Remove message element if validation passed\n if (messageEl) {\n messageEl.remove();\n }\n\n // Update aria-describedby (remove message id)\n const existingDescribedBy = this._ariaAttributes['aria-describedby'] || '';\n if (existingDescribedBy) {\n this.setAttribute('aria-describedby', existingDescribedBy);\n } else {\n this.removeAttribute('aria-describedby');\n }\n }\n }\n\n connectedCallback() {\n super.connectedCallback?.();\n this._handleReady();\n this.setAttribute('role', 'radiogroup');\n }\n\n firstUpdated() {\n const checkedRadio = this.querySelector<ItRadio>('it-radio[checked]');\n if (checkedRadio) {\n this.value = checkedRadio.value;\n }\n this.updateRadios();\n }\n\n private async updateRadios() {\n if (!this.hasUpdated) {\n // Initial validation has to happen after the initial render to allow\n // the buttons to be queries from the rendered <slot> element\n await this.updateComplete;\n }\n const radios = this.querySelectorAll<ItRadio>('it-radio');\n // eslint-disable-next-line no-return-assign, no-param-reassign\n radios.forEach((r) => {\n // eslint-disable-next-line no-param-reassign\n r.checked = r.value === this.value;\n });\n }\n\n disconnectedCallback() {\n super.disconnectedCallback?.();\n }\n\n /**\n * Sync group value from checked radio (initialization)\n */\n private _syncValueFromRadios() {\n if (!this._radios) {\n return;\n }\n\n // Find the first checked radio\n const checkedRadio = this._radios.find((r) => r.checked);\n if (checkedRadio) {\n // Sync the group value from the checked radio\n this.value = checkedRadio.value;\n }\n }\n\n /**\n * PUBLIC API: Called by radio buttons to select themselves\n */\n selectRadio(radio: ItRadio, event: KeyboardEvent | PointerEvent | MouseEvent): void {\n if (radio.disabled || this.disabled) {\n return;\n }\n\n this.value = radio.value;\n\n // Uncheck other radios using their public API\n this._radios.forEach((r) => {\n if (r !== radio) {\n // eslint-disable-next-line no-param-reassign\n r.checked = false;\n } else {\n // eslint-disable-next-line no-param-reassign\n r.checked = true;\n }\n });\n\n // If validation was already triggered, update state after selection\n if (this.formControlController.submittedOnce) {\n // For native validation, clear error if now valid\n if (!this.customValidation) {\n this.handleValidationMessages();\n this._updateInvalidState();\n }\n // For custom validation (JustValidate), the external validator will call setCustomValidity\n // but we still update the state based on current validationMessage\n else {\n this._updateInvalidState();\n }\n }\n\n if (event.type === 'click' || event.type === 'pointerdown') {\n this._handleClick(event);\n } else {\n this._handleChange(event);\n }\n }\n\n /**\n * PUBLIC API: Handle keyboard navigation from radio buttons\n */\n handleRadioKeyDown(radio: ItRadio, event: KeyboardEvent): void {\n // Delegate to roving tabindex controller\n const handled = this.rovingTabindex.handleKeydown(radio, event);\n if (handled) this._handleFocus(event);\n else this._handleBlur(event);\n }\n\n /**\n * Synchronize radio button states with group state\n */\n protected _updateRadiosState() {\n if (!this._radios || this._radios.length === 0) {\n return;\n }\n\n this._radios.forEach((radio) => {\n // Set checked state based on value\n // eslint-disable-next-line no-param-reassign\n radio.checked = radio.value === this.value;\n\n // Sync disabled state from group to radios\n // Note: We don't override individual radio's disabled state\n // If the group is disabled, all radios should be disabled\n // But individual radios can be disabled independently\n if (this.disabled) {\n // eslint-disable-next-line no-param-reassign\n radio.disabled = true;\n }\n });\n\n // Update tabindex using roving tabindex controller\n // Priority: checked and enabled > first enabled > 0\n let tabbableIndex = 0;\n\n // First, try to find a checked radio that is not disabled\n const checkedEnabledIndex = this._radios.findIndex((r) => r.checked && !r.disabled);\n if (checkedEnabledIndex >= 0) {\n tabbableIndex = checkedEnabledIndex;\n } else {\n // If no checked enabled radio, find the first enabled radio\n const firstEnabledIndex = this._radios.findIndex((r) => !r.disabled);\n if (firstEnabledIndex >= 0) {\n tabbableIndex = firstEnabledIndex;\n }\n // If all radios are disabled, tabbableIndex stays 0 (but controller will set all to -1)\n }\n\n this.rovingTabindex.updateTabindices(tabbableIndex);\n }\n\n /**\n * Sync group state (name, grouped, inline, required) to child radios\n * This replaces the need for requestUpdate() calls\n */\n private _syncGroupStateToRadios() {\n if (!this._radios || this._radios.length === 0) {\n return;\n }\n\n const groupState = {\n name: this.name,\n grouped: this.grouped,\n inline: this.inline,\n required: this.required,\n };\n\n this._radios.forEach((radio) => {\n radio.syncFromGroup(groupState);\n });\n }\n\n updated(changed: PropertyValues) {\n super.updated(changed);\n\n // Update radios when value or name changes\n if (changed.has('value')) {\n this._updateRadiosState();\n this.dispatchEvent(new Event('it-change', { bubbles: true }));\n // Re-validate after value change (for native validation) only if validation was already triggered\n if (!this.customValidation && this.formControlController.submittedOnce) {\n this.handleValidationMessages();\n this._updateInvalidState();\n }\n }\n\n // If validation message changed, update aria-invalid on group and children\n // Skip on initial render: Lit reports all properties as \"changed\" on first update,\n // which would mark a required-but-empty group invalid before validation is triggered.\n if (changed.has('validationMessage') && this.formControlController.submittedOnce) {\n this._updateInvalidState();\n }\n\n // If relevant group properties changed, sync to child radios\n const relevant = ['grouped', 'inline', 'name', 'required', 'disabled'];\n const hasChanged = Array.from(changed.keys()).some((k) => relevant.includes(String(k)));\n if (hasChanged && this._radios?.length) {\n this._syncGroupStateToRadios();\n }\n }\n\n /**\n * Handle slot changes (when radios are added/removed)\n */\n protected _handleSlotChange = () => {\n this._syncValueFromRadios();\n this._updateRadiosState();\n // Sync group state to newly added radios\n this._syncGroupStateToRadios();\n };\n\n protected _handleLabelSlotChange = () => {\n const labelId = this.generateId('it-radio-group-label');\n this._label[0]?.setAttribute('id', labelId);\n this.setAttribute('aria-labelledby', labelId);\n };\n\n /**\n * Render the component\n */\n render() {\n const groupWrapperClasses = this.composeClass(\n 'it-radio-group',\n 'it-form__control',\n this.inline && !this.grouped ? 'it-radio-group-inline' : '',\n this.grouped && !this.inline ? 'it-radio-group-stacked' : '',\n );\n\n return html`<slot name=\"label\" @slotchange=${this._handleLabelSlotChange}></slot>\n <div class=${groupWrapperClasses}>\n <slot @slotchange=${this._handleSlotChange}></slot>\n </div>\n <slot name=\"validation-message\"></slot>`;\n }\n}\n\n// Declare custom element\ndeclare global {\n interface HTMLElementTagNameMap {\n 'it-radio-group': ItRadioGroup;\n }\n}\n"],"names":[],"mappings":";;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,MAAM,wBAAwB,CAAC;AACtC,IAAI,WAAW,CAAC,IAAI,EAAE,MAAM,EAAE;AAC9B,QAAQ,IAAI,CAAC,IAAI,GAAG,IAAI;AACxB,QAAQ,IAAI,CAAC,MAAM,GAAG;AACtB,YAAY,IAAI,EAAE,IAAI;AACtB,YAAY,SAAS,EAAE,MAAM;AAC7B,YAAY,aAAa,EAAE,KAAK;AAChC,YAAY,eAAe,EAAE,KAAK;AAClC,YAAY,QAAQ,EAAE,CAAC,IAAI,KAAK,IAAI,CAAC,YAAY,CAAC,UAAU,CAAC,IAAI,IAAI,CAAC,QAAQ,KAAK,IAAI;AACvF,YAAY,GAAG,MAAM;AACrB,SAAS;AACT,QAAQ,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC;AAChC,IAAI;AACJ;AACA,IAAI,aAAa,GAAG;AACpB;AACA,IAAI;AACJ;AACA,IAAI,gBAAgB,GAAG;AACvB;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA,IAAI,gBAAgB,CAAC,WAAW,EAAE;AAClC,QAAQ,MAAM,KAAK,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,EAAE;AAC5C,QAAQ,IAAI,CAAC,KAAK,IAAI,KAAK,CAAC,MAAM,KAAK,CAAC,EAAE;AAC1C,YAAY;AACZ,QAAQ;AACR;AACA,QAAQ,IAAI,WAAW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,IAAI,EAAE,CAAC;;AAC1B,CAAA,EAAA,YAAA,CAAA,SAAA,EAAA,UAAA,EAAA,MAAA,CAAA;AAMjB,UAAA,CAAA;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;;AAC3B,CAAA,EAAA,YAAA,CAAA,SAAA,EAAA,SAAA,EAAA,MAAA,CAAA;AAMhB,UAAA,CAAA;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;;AAC5B,CAAA,EAAA,YAAA,CAAA,SAAA,EAAA,QAAA,EAAA,MAAA,CAAA;AAML,UAAA,CAAA;AADT,IAAA,qBAAqB,EAAE;;AACM,CAAA,EAAA,YAAA,CAAA,SAAA,EAAA,SAAA,EAAA,MAAA,CAAA;AAGtB,UAAA,CAAA;AADP,IAAA,qBAAqB,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;;AACV,CAAA,EAAA,YAAA,CAAA,SAAA,EAAA,QAAA,EAAA,MAAA,CAAA;AAhDpB,YAAY,GAAA,UAAA,CAAA;IADxB,aAAa,CAAC,gBAAgB;AAClB,CAAA,EAAA,YAAY,CAqaxB;;;;"}
1
+ {"version":3,"file":"it-radio-group.js","sources":["../../../globals/dist/src/controllers/roving-tabindex-controller.js","../../../src/it-radio-group.ts"],"sourcesContent":["/**\n * Roving Tabindex Controller\n *\n * Implements the ARIA roving tabindex pattern for keyboard navigation.\n * See: https://www.w3.org/WAI/ARIA/apg/practices/keyboard-interface/#kbd_roving_tabindex\n *\n * Usage:\n * ```ts\n * private rovingTabindex = new RovingTabindexController(this, {\n * getItems: () => Array.from(this.querySelectorAll('my-item')),\n * onSelect: (item) => this.selectItem(item),\n * });\n * ```\n */\nexport class RovingTabindexController {\n constructor(host, config) {\n this.host = host;\n this.config = {\n wrap: true,\n direction: 'both',\n selectOnFocus: false,\n selectOnHomeEnd: false,\n skipItem: (item) => item.hasAttribute('disabled') || item.disabled === true,\n ...config,\n };\n host.addController(this);\n }\n // eslint-disable-next-line class-methods-use-this\n hostConnected() {\n // Controller is ready when host connects\n }\n // eslint-disable-next-line class-methods-use-this\n hostDisconnected() {\n // Cleanup if needed\n }\n /**\n * Update tabindex values for all items\n * @param activeIndex - Index of the item that should be tabbable (default: 0 or first non-disabled)\n */\n updateTabindices(activeIndex) {\n const items = this.config.getItems();\n if (!items || items.length === 0) {\n return;\n }\n // Find the active index\n let targetIndex = activeIndex ?? 0;\n // If no active index specified, use first non-disabled item\n if (activeIndex === undefined) {\n targetIndex = items.findIndex((item) => !this.config.skipItem(item));\n if (targetIndex === -1) {\n targetIndex = 0; // Fallback to first item if all disabled\n }\n }\n // Set tabindex for all items\n items.forEach((item, index) => {\n const itemElement = item;\n if (this.config.skipItem(itemElement)) {\n // eslint-disable-next-line no-param-reassign\n itemElement.tabIndex = -1;\n }\n else {\n // eslint-disable-next-line no-param-reassign\n itemElement.tabIndex = index === targetIndex ? 0 : -1;\n }\n });\n }\n /**\n * Handle keyboard navigation\n * @param currentItem - The currently focused item\n * @param event - The keyboard event\n * @returns true if the event was handled, false otherwise\n */\n handleKeydown(currentItem, event) {\n const direction = typeof this.config.direction === 'function' ? this.config.direction() : this.config.direction;\n const { key } = event;\n // Determine if this key should be handled based on direction\n const isVertical = key === 'ArrowUp' || key === 'ArrowDown';\n const isHorizontal = key === 'ArrowLeft' || key === 'ArrowRight';\n const isHome = key === 'Home';\n const isEnd = key === 'End';\n const shouldHandle = isHome ||\n isEnd ||\n (direction === 'both' && (isVertical || isHorizontal)) ||\n (direction === 'vertical' && isVertical) ||\n (direction === 'horizontal' && isHorizontal);\n if (!shouldHandle) {\n return false;\n }\n // Prevent default behavior (page scrolling)\n event.preventDefault();\n const items = this.config.getItems();\n const currentIndex = items.indexOf(currentItem);\n if (currentIndex === -1) {\n return false;\n }\n let nextIndex = currentIndex;\n // Handle Home/End keys\n if (isHome) {\n nextIndex = 0;\n }\n else if (isEnd) {\n nextIndex = items.length - 1;\n }\n else {\n // Handle arrow keys\n const isNext = key === 'ArrowDown' || key === 'ArrowRight';\n const isPrev = key === 'ArrowUp' || key === 'ArrowLeft';\n if (isNext) {\n nextIndex = this.getNextIndex(items, currentIndex, 1);\n }\n else if (isPrev) {\n nextIndex = this.getNextIndex(items, currentIndex, -1);\n }\n }\n // Skip disabled items — Home always searches forward, End always searches backward\n // eslint-disable-next-line no-nested-ternary\n const searchDirection = isHome ? 1 : isEnd ? -1 : nextIndex > currentIndex ? 1 : -1;\n nextIndex = this.findNextValidIndex(items, nextIndex, searchDirection);\n if (nextIndex !== -1 && nextIndex !== currentIndex) {\n const nextItem = items[nextIndex];\n // Update tabindices\n this.updateTabindices(nextIndex);\n // Focus the next item\n nextItem.focus();\n // Optionally select/activate the item.\n // Select when `selectOnFocus` is enabled, or when Home/End keys\n // were used and the consumer explicitly opted in via `selectOnHomeEnd`.\n const shouldSelect = this.config.selectOnFocus === true || ((isHome || isEnd) && this.config.selectOnHomeEnd === true);\n if (shouldSelect && this.config.onSelect) {\n this.config.onSelect(nextItem, event);\n }\n return true;\n }\n return false;\n }\n /**\n * Get the next index based on direction\n */\n getNextIndex(items, currentIndex, direction) {\n const { wrap } = this.config;\n let nextIndex = currentIndex + direction;\n if (wrap) {\n // Wrap around\n if (nextIndex < 0) {\n nextIndex = items.length - 1;\n }\n else if (nextIndex >= items.length) {\n nextIndex = 0;\n }\n }\n else {\n // Clamp to bounds\n nextIndex = Math.max(0, Math.min(items.length - 1, nextIndex));\n }\n return nextIndex;\n }\n /**\n * Find the next valid (non-disabled) index\n */\n findNextValidIndex(items, startIndex, direction) {\n const maxAttempts = items.length;\n let attempts = 0;\n let index = startIndex;\n while (attempts < maxAttempts) {\n if (!this.config.skipItem(items[index])) {\n return index;\n }\n index = this.getNextIndex(items, index, direction);\n attempts += 1;\n }\n // All items are disabled\n return -1;\n }\n /**\n * Set focus to a specific item\n */\n focusItem(item) {\n const items = this.config.getItems();\n const index = items.indexOf(item);\n if (index !== -1) {\n this.updateTabindices(index);\n item.focus();\n }\n }\n /**\n * Set focus to the first non-disabled item\n */\n focusFirst() {\n const items = this.config.getItems();\n const firstValidIndex = this.findNextValidIndex(items, 0, 1);\n if (firstValidIndex !== -1) {\n this.focusItem(items[firstValidIndex]);\n }\n }\n /**\n * Set focus to the last non-disabled item\n */\n focusLast() {\n const items = this.config.getItems();\n const lastValidIndex = this.findNextValidIndex(items, items.length - 1, -1);\n if (lastValidIndex !== -1) {\n this.focusItem(items[lastValidIndex]);\n }\n }\n}\n//# sourceMappingURL=roving-tabindex-controller.js.map","import { html, PropertyValues } from 'lit';\nimport { customElement, property, queryAssignedElements } from 'lit/decorators.js';\nimport { FormControl, FormControlController, RovingTabindexController } from '@italia/globals';\nimport type { ItRadio } from '@italia/radio';\nimport styles from './radio-group.scss';\n\n/**\n * Radio group component - manages a collection of radio buttons\n *\n * @element it-radio-group\n * @slot - Contains the `<it-radio>` elements\n *\n */\n@customElement('it-radio-group')\nexport class ItRadioGroup extends FormControl {\n static styles = styles;\n\n static formAssociated = true;\n\n /**\n * The name of the radio group, used for form submission\n */\n @property({ type: String })\n name = '';\n\n /**\n * The currently selected value\n */\n @property({ type: String, reflect: true })\n value = '';\n\n /**\n * Whether the radio group is disabled\n */\n @property({ type: Boolean, reflect: true })\n disabled = false;\n\n /**\n * Whether a selection is required\n */\n @property({ type: Boolean, reflect: true })\n required = false;\n\n /**\n * Optional prop for visual styling of grouped radios (borders between radios)\n */\n @property({ type: Boolean, reflect: true })\n grouped = false;\n\n /**\n * Whether the radios are displayed inline (horizontally) or stacked (vertically)\n */\n @property({ type: Boolean, reflect: true })\n inline = false;\n\n /**\n * Get all slotted radio buttons\n */\n @queryAssignedElements()\n protected _radios!: ItRadio[];\n\n @queryAssignedElements({ slot: 'label' })\n private _label!: HTMLElement[];\n\n /**\n * Roving tabindex controller for keyboard navigation\n */\n protected rovingTabindex = new RovingTabindexController<ItRadio>(this, {\n getItems: () => this._radios,\n onSelect: (radio, event) => this.selectRadio(radio, event),\n direction: 'both',\n selectOnFocus: true,\n });\n\n /**\n * Form control integration\n */\n private _formController = new FormControlController(this as any, {\n value: () => this.value,\n // disabled: () => this.disabled,\n setValue: (control: FormControl, value: unknown) => {\n const radioGroup = control as ItRadioGroup;\n radioGroup.value = value as string;\n },\n });\n\n /**\n * Override: Custom validity check for radio group\n */\n override get validity(): ValidityState {\n // Fallback: create a custom ValidityState-like object\n const valid = !this.required || !!this.value;\n return {\n valid,\n valueMissing: this.required && !this.value,\n typeMismatch: false,\n patternMismatch: false,\n tooLong: false,\n tooShort: false,\n rangeUnderflow: false,\n rangeOverflow: false,\n stepMismatch: false,\n badInput: false,\n customError: false,\n } as ValidityState;\n }\n\n /**\n * Override: Check validity for radio group\n */\n override checkValidity(): boolean {\n if (this.required && !this.value) {\n return false;\n }\n return true;\n }\n\n /**\n * Override: Report validity for radio group\n */\n override reportValidity(): boolean {\n const isValid = this.checkValidity();\n this.handleValidationMessages();\n this._updateInvalidState();\n return isValid;\n }\n\n /** Sets a custom validation message. Pass an empty string to restore validity. */\n public override setCustomValidity(message: string) {\n // Only trigger validation state if message is non-empty (actual error)\n // Empty message during init or after correction should not trigger invalid state initially\n\n this.validationMessage = message;\n this.formControlController.updateValidity();\n // Update aria-invalid on group and children immediately\n this._updateInvalidState();\n }\n\n protected override handleValidationMessages() {\n const _v = this.validity;\n if (!this.customValidation) {\n if (_v.valueMissing) {\n this.setCustomValidity(this.$t('validityRequired'));\n } else this.setCustomValidity('');\n }\n }\n\n private _updateInvalidState() {\n // Only show aria-invalid if validation has been triggered (ARIA best practice)\n\n const invalid = this.checkValidity() === false || !!this.validationMessage;\n if (invalid) this.setAttribute('aria-invalid', 'true');\n else this.removeAttribute('aria-invalid');\n this._radios?.forEach((r) => {\n if (invalid) r.setAttribute('aria-invalid', 'true');\n else r.removeAttribute('aria-invalid');\n });\n\n // Update validation message in light DOM\n this._updateValidationMessage();\n }\n\n /**\n * Update validation message in light DOM (for aria-describedby cross-boundary support)\n */\n private _updateValidationMessage() {\n const validityMessage = this.validationMessage;\n const messageId = `invalid-feedback-${this._id}`;\n\n // Find or create validation message element in light DOM\n let messageEl = this.querySelector(`[slot=\"validation-message\"]`);\n\n if (validityMessage && validityMessage.length > 0) {\n // Create message element if it doesn't exist\n if (!messageEl) {\n messageEl = document.createElement('div');\n messageEl.setAttribute('slot', 'validation-message');\n this.appendChild(messageEl);\n }\n\n // Update message content and attributes\n messageEl.id = messageId;\n messageEl.className = 'form-feedback text-danger';\n messageEl.setAttribute('role', 'alert');\n messageEl.removeAttribute('hidden');\n\n const labelText = this._label?.[0]?.textContent || '';\n messageEl.innerHTML = `<span class=\"visually-hidden\">${labelText}: </span>${validityMessage}`;\n\n // Update aria-describedby on host\n const existingDescribedBy = this._ariaAttributes['aria-describedby'] || '';\n const ariaDescribedBy = existingDescribedBy ? `${existingDescribedBy} ${messageId}` : messageId;\n this.setAttribute('aria-describedby', ariaDescribedBy);\n } else {\n // Remove message element if validation passed\n if (messageEl) {\n messageEl.remove();\n }\n\n // Update aria-describedby (remove message id)\n const existingDescribedBy = this._ariaAttributes['aria-describedby'] || '';\n if (existingDescribedBy) {\n this.setAttribute('aria-describedby', existingDescribedBy);\n } else {\n this.removeAttribute('aria-describedby');\n }\n }\n }\n\n connectedCallback() {\n super.connectedCallback?.();\n this._handleReady();\n this.setAttribute('role', 'radiogroup');\n }\n\n firstUpdated() {\n const checkedRadio = this.querySelector<ItRadio>('it-radio[checked]');\n if (checkedRadio) {\n this.value = checkedRadio.value;\n }\n this.updateRadios();\n }\n\n private async updateRadios() {\n if (!this.hasUpdated) {\n // Initial validation has to happen after the initial render to allow\n // the buttons to be queries from the rendered <slot> element\n await this.updateComplete;\n }\n const radios = this.querySelectorAll<ItRadio>('it-radio');\n // eslint-disable-next-line no-return-assign, no-param-reassign\n radios.forEach((r) => {\n // eslint-disable-next-line no-param-reassign\n r.checked = r.value === this.value;\n });\n }\n\n disconnectedCallback() {\n super.disconnectedCallback?.();\n }\n\n /**\n * Sync group value from checked radio (initialization)\n */\n private _syncValueFromRadios() {\n if (!this._radios) {\n return;\n }\n\n // Find the first checked radio\n const checkedRadio = this._radios.find((r) => r.checked);\n if (checkedRadio) {\n // Sync the group value from the checked radio\n this.value = checkedRadio.value;\n }\n }\n\n /**\n * PUBLIC API: Called by radio buttons to select themselves\n */\n selectRadio(radio: ItRadio, event: KeyboardEvent | PointerEvent | MouseEvent): void {\n if (radio.disabled || this.disabled) {\n return;\n }\n\n this.value = radio.value;\n\n // Uncheck other radios using their public API\n this._radios.forEach((r) => {\n if (r !== radio) {\n // eslint-disable-next-line no-param-reassign\n r.checked = false;\n } else {\n // eslint-disable-next-line no-param-reassign\n r.checked = true;\n }\n });\n\n // If validation was already triggered, update state after selection\n if (this.formControlController.submittedOnce) {\n // For native validation, clear error if now valid\n if (!this.customValidation) {\n this.handleValidationMessages();\n this._updateInvalidState();\n }\n // For custom validation (JustValidate), the external validator will call setCustomValidity\n // but we still update the state based on current validationMessage\n else {\n this._updateInvalidState();\n }\n }\n\n if (event.type === 'click' || event.type === 'pointerdown') {\n this._handleClick(event);\n } else {\n this._handleChange(event);\n }\n }\n\n /**\n * PUBLIC API: Handle keyboard navigation from radio buttons\n */\n handleRadioKeyDown(radio: ItRadio, event: KeyboardEvent): void {\n // Delegate to roving tabindex controller\n const handled = this.rovingTabindex.handleKeydown(radio, event);\n if (handled) this._handleFocus(event);\n else this._handleBlur(event);\n }\n\n /**\n * Synchronize radio button states with group state\n */\n protected _updateRadiosState() {\n if (!this._radios || this._radios.length === 0) {\n return;\n }\n\n this._radios.forEach((radio) => {\n // Set checked state based on value\n // eslint-disable-next-line no-param-reassign\n radio.checked = radio.value === this.value;\n\n // Sync disabled state from group to radios\n // Note: We don't override individual radio's disabled state\n // If the group is disabled, all radios should be disabled\n // But individual radios can be disabled independently\n if (this.disabled) {\n // eslint-disable-next-line no-param-reassign\n radio.disabled = true;\n }\n });\n\n // Update tabindex using roving tabindex controller\n // Priority: checked and enabled > first enabled > 0\n let tabbableIndex = 0;\n\n // First, try to find a checked radio that is not disabled\n const checkedEnabledIndex = this._radios.findIndex((r) => r.checked && !r.disabled);\n if (checkedEnabledIndex >= 0) {\n tabbableIndex = checkedEnabledIndex;\n } else {\n // If no checked enabled radio, find the first enabled radio\n const firstEnabledIndex = this._radios.findIndex((r) => !r.disabled);\n if (firstEnabledIndex >= 0) {\n tabbableIndex = firstEnabledIndex;\n }\n // If all radios are disabled, tabbableIndex stays 0 (but controller will set all to -1)\n }\n\n this.rovingTabindex.updateTabindices(tabbableIndex);\n }\n\n /**\n * Sync group state (name, grouped, inline, required) to child radios\n * This replaces the need for requestUpdate() calls\n */\n private _syncGroupStateToRadios() {\n if (!this._radios || this._radios.length === 0) {\n return;\n }\n\n const groupState = {\n name: this.name,\n grouped: this.grouped,\n inline: this.inline,\n required: this.required,\n };\n\n this._radios.forEach((radio) => {\n radio.syncFromGroup(groupState);\n });\n }\n\n updated(changed: PropertyValues) {\n super.updated(changed);\n\n // Update radios when value or name changes\n if (changed.has('value')) {\n this._updateRadiosState();\n this.dispatchEvent(new Event('it-change', { bubbles: true }));\n // Re-validate after value change (for native validation) only if validation was already triggered\n if (!this.customValidation && this.formControlController.submittedOnce) {\n this.handleValidationMessages();\n this._updateInvalidState();\n }\n }\n\n // If validation message changed, update aria-invalid on group and children\n // Skip on initial render: Lit reports all properties as \"changed\" on first update,\n // which would mark a required-but-empty group invalid before validation is triggered.\n if (changed.has('validationMessage') && this.formControlController.submittedOnce) {\n this._updateInvalidState();\n }\n\n // If relevant group properties changed, sync to child radios\n const relevant = ['grouped', 'inline', 'name', 'required', 'disabled'];\n const hasChanged = Array.from(changed.keys()).some((k) => relevant.includes(String(k)));\n if (hasChanged && this._radios?.length) {\n this._syncGroupStateToRadios();\n }\n }\n\n /**\n * Handle slot changes (when radios are added/removed)\n */\n protected _handleSlotChange = () => {\n this._syncValueFromRadios();\n this._updateRadiosState();\n // Sync group state to newly added radios\n this._syncGroupStateToRadios();\n };\n\n protected _handleLabelSlotChange = () => {\n const labelId = this.generateId('it-radio-group-label');\n this._label[0]?.setAttribute('id', labelId);\n this.setAttribute('aria-labelledby', labelId);\n };\n\n /**\n * Render the component\n */\n render() {\n const groupWrapperClasses = this.composeClass(\n 'it-radio-group',\n 'it-form__control',\n this.inline && !this.grouped ? 'it-radio-group-inline' : '',\n this.grouped && !this.inline ? 'it-radio-group-stacked' : '',\n );\n\n return html`<slot name=\"label\" @slotchange=${this._handleLabelSlotChange}></slot>\n <div class=${groupWrapperClasses}>\n <slot @slotchange=${this._handleSlotChange}></slot>\n </div>\n <slot name=\"validation-message\"></slot>`;\n }\n}\n\n// Declare custom element\ndeclare global {\n interface HTMLElementTagNameMap {\n 'it-radio-group': ItRadioGroup;\n }\n}\n"],"names":[],"mappings":";;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,MAAM,wBAAwB,CAAC;AACtC,IAAI,WAAW,CAAC,IAAI,EAAE,MAAM,EAAE;AAC9B,QAAQ,IAAI,CAAC,IAAI,GAAG,IAAI;AACxB,QAAQ,IAAI,CAAC,MAAM,GAAG;AACtB,YAAY,IAAI,EAAE,IAAI;AACtB,YAAY,SAAS,EAAE,MAAM;AAC7B,YAAY,aAAa,EAAE,KAAK;AAChC,YAAY,eAAe,EAAE,KAAK;AAClC,YAAY,QAAQ,EAAE,CAAC,IAAI,KAAK,IAAI,CAAC,YAAY,CAAC,UAAU,CAAC,IAAI,IAAI,CAAC,QAAQ,KAAK,IAAI;AACvF,YAAY,GAAG,MAAM;AACrB,SAAS;AACT,QAAQ,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC;AAChC,IAAI;AACJ;AACA,IAAI,aAAa,GAAG;AACpB;AACA,IAAI;AACJ;AACA,IAAI,gBAAgB,GAAG;AACvB;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA,IAAI,gBAAgB,CAAC,WAAW,EAAE;A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AI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;;AAC1B,CAAA,EAAA,YAAA,CAAA,SAAA,EAAA,UAAA,EAAA,MAAA,CAAA;AAMjB,UAAA,CAAA;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;;AAC3B,CAAA,EAAA,YAAA,CAAA,SAAA,EAAA,SAAA,EAAA,MAAA,CAAA;AAMhB,UAAA,CAAA;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;;AAC5B,CAAA,EAAA,YAAA,CAAA,SAAA,EAAA,QAAA,EAAA,MAAA,CAAA;AAML,UAAA,CAAA;AADT,IAAA,qBAAqB,EAAE;;AACM,CAAA,EAAA,YAAA,CAAA,SAAA,EAAA,SAAA,EAAA,MAAA,CAAA;AAGtB,UAAA,CAAA;AADP,IAAA,qBAAqB,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;;AACV,CAAA,EAAA,YAAA,CAAA,SAAA,EAAA,QAAA,EAAA,MAAA,CAAA;AAhDpB,YAAY,GAAA,UAAA,CAAA;IADxB,aAAa,CAAC,gBAAgB;AAClB,CAAA,EAAA,YAAY,CAqaxB;;"}
@@ -1,4 +1,4 @@
1
- import { _ as __decorate, a as __metadata, B as BaseComponent } from '../index-CXf6SDTu.js';
1
+ import { _ as __decorate, a as __metadata, B as BaseComponent } from '../index-DGrVJFtp.js';
2
2
  import { css, html } from 'lit';
3
3
  import { property, state, queryAssignedElements, customElement } from 'lit/decorators.js';
4
4
  import { when } from 'lit/directives/when.js';
@@ -322,6 +322,7 @@ progress {
322
322
  --bsi-form-control-label-color: var(--bsi-color-text-base);
323
323
  --bsi-form-control-text-color: var(--bsi-color-text-secondary);
324
324
  --bsi-form-control-font-size: var(--bsi-body-font-size);
325
+ --bsi-form-select-indicator: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='hsl%280, 0%, 32%%29' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
325
326
  --bsi-form-group-spacing-y: var(--bsi-spacing-m);
326
327
  --bsi-form-checkbox-border-color: var(--bsi-color-border-secondary);
327
328
  --bsi-form-checkbox-border-radius: var(--bsi-radius-smooth);
@@ -348,6 +349,7 @@ select {
348
349
  background-color: var(--bsi-form-control-background-color);
349
350
  color: var(--bsi-form-control-text-color);
350
351
  font-size: var(--bsi-form-control-font-size);
352
+ line-height: var(--bsi-font-leading-2);
351
353
  }
352
354
  input.disabled, input:disabled,
353
355
  textarea.disabled,
@@ -360,48 +362,44 @@ select:disabled {
360
362
  color: var(--bsi-color-text-disabled);
361
363
  }
362
364
 
365
+ input,
366
+ select {
367
+ padding-block: var(--bsi-spacing-3xs);
368
+ }
369
+
363
370
  /* stylelint-disable-next-line no-duplicate-selectors */
364
371
  input:focus,
365
372
  textarea:focus {
366
- outline: 3px solid transparent;
373
+ outline: var(--bsi-focus-outer-width) solid transparent;
367
374
  outline-offset: 3px;
368
- box-shadow: 0 0 0 2px var(--bsi-color-border-inverse), 0 0 0 5px var(--bsi-color-outline-focus) !important;
375
+ box-shadow: 0 0 0 var(--bsi-focus-inner-width) var(--bsi-focus-inner-color), 0 0 0 calc(var(--bsi-focus-inner-width) + var(--bsi-focus-outer-width)) var(--bsi-focus-outer-color) !important;
369
376
  }
370
377
 
371
378
  input::file-selector-button {
372
- margin: -0.375rem -0.75rem;
373
- padding: 0.375rem 0.75rem;
374
- border-width: 0;
375
- border-style: solid;
379
+ margin: 0;
380
+ padding: 0;
381
+ padding-inline-end: var(--bsi-spacing-m);
382
+ border: 0;
376
383
  border-radius: 0;
377
- border-color: inherit;
378
- color: hsl(0, 0%, 10%);
384
+ color: var(--bsi-color-text-base);
385
+ background-color: transparent;
379
386
  pointer-events: none;
380
- margin-inline-end: 0.75rem;
381
- border-inline-end-width: 0;
382
- background-color: hsl(0, 0%, 100%);
383
- transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
384
- }
385
- @media (prefers-reduced-motion: reduce) {
386
- input::file-selector-button {
387
- transition: none;
388
- }
389
- }
390
- input:hover:not(:disabled):not([readonly])::file-selector-button {
391
- background-color: rgb(242.25, 242.25, 242.25);
392
387
  }
393
388
  input[type=file] {
394
389
  overflow: hidden;
390
+ padding-block: max(0px, (var(--bsi-form-control-height) - 1lh - 2px) / 2);
395
391
  }
396
392
  input[type=file]:not(:disabled):not([readonly]) {
397
393
  cursor: pointer;
398
394
  }
399
395
  input::-webkit-date-and-time-value {
400
- height: 1.5em;
396
+ height: 1lh;
397
+ padding-block: max(0px, (var(--bsi-form-control-height) - 2px - 2 * var(--bsi-spacing-3xs) - 1lh) / 2);
398
+ text-align: start;
401
399
  }
402
400
 
403
401
  select {
404
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='hsl%280, 0%, 32%%29' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
402
+ background-image: var(--bsi-form-select-indicator, url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='hsl%280, 0%, 32%%29' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e"));
405
403
  background-repeat: no-repeat;
406
404
  background-position: right var(--bsi-form-control-spacing) center;
407
405
  background-size: 16px 12px;
@@ -410,7 +408,7 @@ select {
410
408
  select:focus {
411
409
  border-color: hsl(210, 17%, 44%);
412
410
  outline: 0;
413
- box-shadow: 0 0 0 0.25rem rgba(0, 102, 204, 0.25);
411
+ box-shadow: 0 0 0 0.25rem rgba(0%, 40%, 80%, 0.25);
414
412
  }
415
413
  select[multiple], select[size]:not([size="1"]) {
416
414
  padding-right: 0.75rem;
@@ -572,9 +570,9 @@ input::-webkit-datetime-edit {
572
570
  }
573
571
  .form-check [type=checkbox]:focus + label,
574
572
  .form-check [type=radio]:focus + label {
575
- border-color: hsl(0, 0%, 0%) !important;
576
- box-shadow: 0 0 0 2px var(--bsi-color-border-inverse), 0 0 0 5px var(--bsi-color-outline-focus) !important;
577
- outline: 3px solid transparent !important;
573
+ border-color: var(--bsi-focus-outer-color) !important;
574
+ box-shadow: 0 0 0 var(--bsi-focus-inner-width) var(--bsi-focus-inner-color), 0 0 0 calc(var(--bsi-focus-inner-width) + var(--bsi-focus-outer-width)) var(--bsi-focus-outer-color) !important;
575
+ outline: var(--bsi-focus-outer-width) solid transparent !important;
578
576
  outline-offset: 3px !important;
579
577
  }
580
578
  .form-check [type=checkbox]:focus[data-focus-mouse=true] + label,
@@ -595,12 +593,14 @@ input::-webkit-datetime-edit {
595
593
  }
596
594
  .form-check input[type=checkbox] + label::after {
597
595
  top: 0;
596
+ top: max(0px, (1lh - 20px) / 2);
598
597
  width: 20px;
599
598
  height: 20px;
600
599
  border-radius: var(--bsi-form-checkbox-border-radius);
601
600
  }
602
601
  .form-check input[type=checkbox]:checked + label::before {
603
602
  top: 3px;
603
+ top: calc(3px + max(0px, (1lh - 20px) / 2));
604
604
  left: 3px;
605
605
  width: 6px;
606
606
  height: 12px;
@@ -624,6 +624,7 @@ input::-webkit-datetime-edit {
624
624
  }
625
625
  .form-check input[type=checkbox]:not(:checked) + label::before {
626
626
  top: 10px;
627
+ top: calc(10px + max(0px, (1lh - 20px) / 2));
627
628
  left: 6px;
628
629
  width: 0;
629
630
  height: 0;
@@ -647,6 +648,7 @@ input::-webkit-datetime-edit {
647
648
  .form-check input[type=radio] + label::after, .form-check input[type=radio] + label::before {
648
649
  position: absolute;
649
650
  top: 0;
651
+ top: max(0px, (1lh - 20px) / 2);
650
652
  left: 0;
651
653
  z-index: 0;
652
654
  content: "";
@@ -657,6 +659,14 @@ input::-webkit-datetime-edit {
657
659
  border-radius: var(--bsi-radius-rounded);
658
660
  transition: all var(--bsi-transition-instant) ease-out;
659
661
  }
662
+ .form-check input[type=radio] + label::after {
663
+ top: 4px;
664
+ top: calc(4px + max(0px, (1lh - 20px) / 2));
665
+ left: 4px;
666
+ width: 12px;
667
+ height: 12px;
668
+ border-width: 0;
669
+ }
660
670
  .form-check input[type=radio]:not(:checked) + label::after, .form-check input[type=radio]:not(:checked) + label::before {
661
671
  border-color: var(--bsi-form-checkbox-border-color);
662
672
  }
@@ -668,7 +678,7 @@ input::-webkit-datetime-edit {
668
678
  z-index: 0;
669
679
  border-color: var(--bsi-form-checked-color);
670
680
  background-color: var(--bsi-form-checked-color);
671
- transform: scale(0.64);
681
+ transform: none;
672
682
  }
673
683
  .form-check input[type=radio]:checked + label::before {
674
684
  border-color: var(--bsi-form-checked-color);
@@ -717,12 +727,16 @@ input::-webkit-datetime-edit {
717
727
  .form-check.form-check-group input[type=radio]:checked + label::before {
718
728
  right: 0;
719
729
  }
730
+ .form-check.form-check-group input[type=radio] + label::after {
731
+ right: 4px;
732
+ }
720
733
  .form-check.form-check-group input.semi-checked:not(:checked) + label::before {
721
734
  right: 4px;
722
735
  left: auto;
723
736
  }
724
737
  .form-check input.semi-checked:not(:checked) + label::before {
725
738
  top: 12px;
739
+ top: calc(12px + max(0px, (1lh - 20px) / 2));
726
740
  left: 4px;
727
741
  width: 12px;
728
742
  height: 2px;
@@ -793,163 +807,12 @@ input::-webkit-datetime-edit {
793
807
  --bsi-form-control-spacing: var(--bsi-spacing-xxs) var(--bsi-spacing-3xs);
794
808
  --bsi-form-control-font-size: var(--bsi-label-font-size);
795
809
  }
796
- .form-control-sm::file-selector-button {
797
- padding: 0.25rem 0.5rem;
798
- margin: -0.25rem -0.5rem;
799
- margin-inline-end: 0.5rem;
800
- }
801
810
 
802
811
  .form-control-lg {
803
812
  --bsi-form-control-font-size: var(--bsi-lead-font-size);
804
813
  }
805
- .form-control-lg::file-selector-button {
806
- padding: 0.5rem 1rem;
807
- margin: -0.5rem -1rem;
808
- margin-inline-end: 1rem;
809
- }
810
-
811
- textarea.form-control {
812
- min-height: 2.5rem;
813
- border: 1px solid hsl(210, 17%, 44%);
814
- }
815
- textarea.form-control-sm {
816
- min-height: calc(1.5em + 0.5rem);
817
- }
818
- textarea.form-control-lg {
819
- min-height: calc(1.5em + 1rem);
820
- }
821
-
822
- .form-control-color {
823
- width: 3rem;
824
- height: 2.5rem;
825
- padding: 0.375rem;
826
- }
827
- .form-control-color:not(:disabled):not([readonly]) {
828
- cursor: pointer;
829
- }
830
- .form-control-color::-moz-color-swatch {
831
- border: 0 !important;
832
- border-radius: 0;
833
- }
834
- .form-control-color::-webkit-color-swatch {
835
- border-radius: 0;
836
- }
837
- .form-control-color.form-control-sm {
838
- height: calc(1.5em + 0.5rem);
839
- }
840
- .form-control-color.form-control-lg {
841
- height: calc(1.5em + 1rem);
842
- }
843
-
844
- .form-check-reverse {
845
- padding-right: 1.5em;
846
- padding-left: 0;
847
- text-align: right;
848
- }
849
- .form-check-reverse .form-check-input {
850
- float: right;
851
- margin-right: -1.5em;
852
- margin-left: 0;
853
- }
854
-
855
- .form-check-input {
856
- width: 1em;
857
- height: 1em;
858
- margin-top: 0.25em;
859
- vertical-align: top;
860
- background-color: hsl(0, 0%, 100%);
861
- background-repeat: no-repeat;
862
- background-position: center;
863
- background-size: contain;
864
- border: 1px solid rgba(0, 0, 0, 0.25);
865
- appearance: none;
866
- print-color-adjust: exact;
867
- }
868
- .form-check-input[type=checkbox] {
869
- border-radius: 0.25em;
870
- }
871
- .form-check-input[type=radio] {
872
- border-radius: 50%;
873
- }
874
- .form-check-input:active {
875
- filter: brightness(90%);
876
- }
877
- .form-check-input:focus {
878
- border-color: hsl(210, 17%, 44%);
879
- outline: 0;
880
- box-shadow: 0 0 0 0.25rem rgba(0, 102, 204, 0.25);
881
- }
882
- .form-check-input:checked {
883
- background-color: hsl(210, 100%, 40%);
884
- border-color: hsl(210, 100%, 40%);
885
- }
886
- .form-check-input:checked[type=checkbox] {
887
- background-image: escape-svg(url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'><path fill='none' stroke='hsl(0, 0%, 100%)' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='m6 10 3 3 6-6'/></svg>"));
888
- }
889
- .form-check-input:checked[type=radio] {
890
- background-image: escape-svg(url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'><circle r='2' fill='hsl(0, 0%, 100%)'/></svg>"));
891
- }
892
- .form-check-input[type=checkbox]:indeterminate {
893
- background-color: hsl(210, 100%, 40%);
894
- border-color: hsl(210, 100%, 40%);
895
- background-image: escape-svg(url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'><path fill='none' stroke='hsl(0, 0%, 100%)' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='M6 10h8'/></svg>"));
896
- }
897
- .form-check-input:disabled {
898
- pointer-events: none;
899
- filter: none;
900
- opacity: 0.5;
901
- }
902
- .form-check-input[disabled] ~ .form-check-label, .form-check-input:disabled ~ .form-check-label {
903
- cursor: default;
904
- opacity: 0.5;
905
- }
906
-
907
- .form-switch {
908
- padding-left: 2.5em;
909
- }
910
- .form-switch .form-check-input {
911
- width: 2em;
912
- margin-left: -2.5em;
913
- background-image: escape-svg(url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'><circle r='3' fill='rgba(0, 0, 0, 0.25)'/></svg>"));
914
- background-position: left center;
915
- border-radius: 2em;
916
- transition: background-position 0.15s ease-in-out;
917
- }
918
- @media (prefers-reduced-motion: reduce) {
919
- .form-switch .form-check-input {
920
- transition: none;
921
- }
922
- }
923
- .form-switch .form-check-input:focus {
924
- background-image: escape-svg(url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'><circle r='3' fill='hsl(210, 17%, 44%)'/></svg>"));
925
- }
926
- .form-switch .form-check-input:checked {
927
- background-position: right center;
928
- background-image: escape-svg(url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'><circle r='3' fill='hsl(0, 0%, 100%)'/></svg>"));
929
- }
930
- .form-switch.form-check-reverse {
931
- padding-right: 2.5em;
932
- padding-left: 0;
933
- }
934
- .form-switch.form-check-reverse .form-check-input {
935
- margin-right: -2.5em;
936
- margin-left: 0;
937
- }
938
-
939
- .form-check-inline {
940
- display: inline-block;
941
- margin-right: 1rem;
942
- }
943
-
944
- .btn-check {
945
- position: absolute;
946
- clip: rect(0, 0, 0, 0);
947
- pointer-events: none;
948
- }
949
- .btn-check[disabled] + .btn, .btn-check:disabled + .btn {
950
- pointer-events: none;
951
- filter: none;
952
- opacity: 0.65;
814
+ .form-control-lg, .form-control-lg + .password-icon {
815
+ --bsi-form-control-height: 3rem;
953
816
  }
954
817
 
955
818
  .form-feedback {
@@ -958,21 +821,26 @@ textarea.form-control-lg {
958
821
  font-size: 0.75rem;
959
822
  }
960
823
 
961
- .input-group-text:has(~ [data-focus-mouse=true]:not(.btn)),
962
- [data-focus-mouse=true]:not(.btn) ~ .input-group-text,
963
- button:has(~ [data-focus-mouse=true]:not(.btn)),
964
- [data-focus-mouse=true]:not(.btn) + button {
824
+ .input-group .input-group-text:has(~ [data-focus-mouse=true]:not(.btn)),
825
+ .input-group [data-focus-mouse=true]:not(.btn) ~ .input-group-text,
826
+ .input-group button:has(~ [data-focus-mouse=true]:not(.btn)),
827
+ .input-group [data-focus-mouse=true]:not(.btn) + button {
965
828
  border-color: inherit !important;
966
829
  box-shadow: none !important;
967
830
  outline: none !important;
968
831
  }
969
-
970
- .input-group-text:has(~ .is-invalid),
971
- .is-invalid ~ .input-group-text,
972
- button:has(~ .is-invalid),
973
- .is-invalid + button {
832
+ .input-group .input-group-text:has(~ .is-invalid),
833
+ .input-group .is-invalid ~ .input-group-text,
834
+ .input-group button:has(~ .is-invalid),
835
+ .input-group .is-invalid + button {
974
836
  border-color: var(--bsi-color-border-danger) !important;
975
837
  }
838
+ .input-group .input-group-text:has(~ .is-valid),
839
+ .input-group .is-valid ~ .input-group-text,
840
+ .input-group button:has(~ .is-valid),
841
+ .input-group .is-valid + button {
842
+ border-color: var(--bsi-color-border-success);
843
+ }
976
844
 
977
845
  .sr-only-justvalidate-bi {
978
846
  display: none;
@@ -987,17 +855,20 @@ button:has(~ .is-invalid),
987
855
  padding-right: calc(1.5em + 0.75rem + var(--bsi-form-control-spacing) + 1rem) !important;
988
856
  }
989
857
 
990
- .was-validated &:valid,
858
+ .was-validated .form-control:valid,
859
+ .was-validated select:valid,
991
860
  .is-valid {
992
861
  border-color: var(--bsi-color-border-success) !important;
993
862
  background-image: url('data:image/svg+xml,<svg width="24" height="24" viewBox="0 0 24 24" fill="%23008055" xmlns="http://www.w3.org/2000/svg"><path d="M9.6,16.9L4,11.4l0.8-0.7l4.8,4.8l8.5-8.4l0.7,0.7L9.6,16.9z" /></svg>');
994
863
  }
995
- .was-validated &:valid ~ .warning-feedback,
864
+ .was-validated .form-control:valid ~ .warning-feedback,
865
+ .was-validated select:valid ~ .warning-feedback,
996
866
  .is-valid ~ .warning-feedback {
997
867
  display: block;
998
868
  }
999
869
 
1000
- .was-validated &:invalid,
870
+ .was-validated .form-control:invalid,
871
+ .was-validated select:invalid,
1001
872
  .is-invalid {
1002
873
  border-color: var(--bsi-color-border-danger) !important;
1003
874
  background-image: url('data:image/svg+xml,<svg width="24" fill="%23cc334d" height="24" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12.7,12l6.7,6.6l-0.8,0.8L12,12.7l-6.6,6.7l-0.8-0.8l6.7-6.6L4.6,5.4l0.8-0.8l6.6,6.7l6.6-6.7l0.8,0.8L12.7,12z" /></svg>');
@@ -1008,13 +879,6 @@ button:has(~ .is-invalid),
1008
879
  background-image: url('data:image/svg+xml,<svg width="24" height="24" fill="%23995c00" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12.5,17h-1V2h1V17z M12.5,20h-1v2h1V20z" /></svg>');
1009
880
  }
1010
881
 
1011
- .input-group-text:has(~ .is-valid),
1012
- .is-valid ~ .input-group-text,
1013
- button:has(~ .is-valid),
1014
- .is-valid + button {
1015
- border-color: var(--bsi-color-border-success);
1016
- }
1017
-
1018
882
  .is-valid + .input-group-text.align-buttons,
1019
883
  .is-invalid + .input-group-text.align-buttons {
1020
884
  right: 30px;
@@ -1045,7 +909,7 @@ textarea.form-control {
1045
909
  - host contiene il focus (qualunque elemento figlio sia focalizzato)
1046
910
  - fallback: anche quando host ha semplicemente :focus (utile per alcuni casi) */
1047
911
  :host(:focus-visible) .radio-control {
1048
- box-shadow: 0 0 0 2px hsl(0, 0%, 100%), 0 0 0 5px hsl(0, 0%, 0%) !important;
912
+ box-shadow: 0 0 0 var(--bsi-focus-inner-width) var(--bsi-focus-inner-color), 0 0 0 calc(var(--bsi-focus-inner-width) + var(--bsi-focus-outer-width)) var(--bsi-focus-outer-color) !important;
1049
913
  /* assicurati che il controllo non abbia outline propio che interferisca */
1050
914
  outline: none;
1051
915
  }
@@ -1054,7 +918,6 @@ textarea.form-control {
1054
918
  display: flex;
1055
919
  width: fit-content;
1056
920
  align-items: center;
1057
- padding: var(--bsi-form-input-padding-y) var(--bsi-form-input-padding-x);
1058
921
  cursor: pointer;
1059
922
  }
1060
923
 
@@ -1062,7 +925,7 @@ textarea.form-control {
1062
925
  display: block;
1063
926
  width: 100%;
1064
927
  color: var(--it-radio-label-color, var(--bsi-form-control-label-color));
1065
- font-size: var(--bsi-label-sm);
928
+ font-size: var(--bsi-label-font-size);
1066
929
  font-weight: var(--bsi-font-weight-solid);
1067
930
  }
1068
931
  @media (min-width: 576px) {
@@ -1113,10 +976,10 @@ textarea.form-control {
1113
976
  #button::after {
1114
977
  position: absolute;
1115
978
  z-index: -1;
1116
- top: 0;
1117
- left: 0;
1118
- width: 20px;
1119
- height: 20px;
979
+ top: 4px;
980
+ left: 4px;
981
+ width: 12px;
982
+ height: 12px;
1120
983
  border-width: 0;
1121
984
  border-style: solid;
1122
985
  border-color: transparent;
@@ -1143,10 +1006,9 @@ textarea.form-control {
1143
1006
  }
1144
1007
  :host([aria-checked=true]) #button::after {
1145
1008
  z-index: 0;
1146
- border-width: 2px;
1147
1009
  border-color: var(--bsi-form-checked-color);
1148
1010
  background-color: var(--bsi-form-checked-color);
1149
- transform: scale(0.64);
1011
+ transform: none;
1150
1012
  }
1151
1013
 
1152
1014
  :host([aria-disabled=true]) .radio-control {
@@ -1354,7 +1216,7 @@ let ItRadio = class ItRadio extends BaseComponent {
1354
1216
  // #input = container, #button = visual circle
1355
1217
  const inputRender = html `
1356
1218
  <div id="input" part="input"></div>
1357
- <span id="button" part="button" class="form-check-input"></span>
1219
+ <span id="button" part="button"></span>
1358
1220
  `;
1359
1221
  return inputRender;
1360
1222
  }
@@ -1 +1 @@
1
- {"version":3,"file":"it-radio.js","sources":["../../../src/it-radio.ts"],"sourcesContent":["import { BaseComponent } from '@italia/globals';\nimport { html } from 'lit';\nimport { customElement, property, queryAssignedElements, state } from 'lit/decorators.js';\nimport { when } from 'lit/directives/when.js';\nimport { ifDefined } from 'lit/directives/if-defined.js';\nimport { type ItRadioGroup } from '@italia/radio';\n\nimport styles from './radio.scss';\n\n@customElement('it-radio')\nexport class ItRadio extends BaseComponent {\n static styles = styles;\n\n /** The radio's value attribute */\n @property({ type: String, reflect: true })\n value = '';\n\n /** Whether the radio is disabled */\n @property({ type: Boolean, reflect: true })\n disabled = false;\n\n /** Draws the radio in a checked state. */\n @property({ type: Boolean, reflect: true })\n checked = false;\n\n /** The input's help text. */\n @property({ type: String, attribute: 'support-text' })\n supportText = '';\n\n /**\n * Internal reactive state synced from group\n * These replace the old getters that read from this.group\n */\n @state()\n private _name = '';\n\n @state()\n private _grouped = false;\n\n @state()\n private _required = false;\n\n @state()\n private _inline = false;\n\n @queryAssignedElements({ slot: 'label' })\n labelElements!: HTMLElement[];\n\n get label(): string {\n if (this.labelElements.length > 0) {\n return this.labelElements[0].innerText.trim();\n }\n return '';\n }\n\n get group(): ItRadioGroup | null {\n return this.closest('it-radio-group');\n }\n\n // Public getters now read from internal state (reactive)\n get name(): string {\n return this._name || this.group?.name || '';\n }\n\n get grouped(): boolean {\n return this._grouped;\n }\n\n get required(): boolean {\n return this._required;\n }\n\n get inline(): boolean {\n return this._inline;\n }\n\n get invalid(): boolean {\n // Read aria-invalid explicitly from the group: only the string \"true\" should be considered invalid\n const aria = this.group?.getAttribute ? this.group.getAttribute('aria-invalid') : null;\n return aria === 'true';\n }\n\n /**\n * PUBLIC API: Called by group to sync state\n * This replaces the need for requestUpdate() calls\n */\n syncFromGroup(groupState: { name?: string; grouped?: boolean; required?: boolean; inline?: boolean }): void {\n if (groupState.name !== undefined) this._name = groupState.name;\n if (groupState.grouped !== undefined) this._grouped = groupState.grouped;\n if (groupState.required !== undefined) this._required = groupState.required;\n if (groupState.inline !== undefined) this._inline = groupState.inline;\n }\n /**\n * Activate the radio via the group's public API\n */\n\n private activate(event: KeyboardEvent | PointerEvent | MouseEvent): void {\n if (this.checked || this.disabled) {\n return;\n }\n\n // Use the group's public API if available\n if (this.group) {\n this.group.selectRadio(this, event);\n } else {\n // Fallback if no group (shouldn't happen in normal usage)\n this.checked = true;\n }\n }\n\n /**\n * Handle keyup for Space key\n */\n private handleKeyup = (event: KeyboardEvent): void => {\n if (event.code === 'Space') {\n event.preventDefault();\n this.activate(event);\n }\n };\n\n /**\n * Handle keydown - delegate arrow keys to the group\n */\n private handleKeydown = (event: KeyboardEvent): void => {\n // Prevent Space from scrolling the page\n if (event.code === 'Space') {\n event.preventDefault();\n return;\n }\n\n // Let Tab and Shift+Tab work normally for navigation\n if (event.key === 'Tab') {\n this.group?.handleRadioKeyDown(this, event);\n return;\n }\n\n // Only prevent default for arrow keys (to prevent page scrolling)\n if (['ArrowUp', 'ArrowDown', 'ArrowLeft', 'ArrowRight'].includes(event.key)) {\n event.preventDefault();\n }\n\n // Delegate keyboard navigation to the group's public API\n this.group?.handleRadioKeyDown(this, event);\n };\n\n /**\n * Handle click on the host\n */\n private handleClick = (event: PointerEvent | MouseEvent): void => {\n this.activate(event);\n };\n\n override connectedCallback() {\n super.connectedCallback?.();\n\n // Set role on host for screen reader context\n this.setAttribute('role', 'radio');\n\n // Set initial tabindex if not already set (roving tabindex will be managed by group)\n if (!this.hasAttribute('tabindex')) {\n this.tabIndex = 0;\n }\n\n // Add event listeners on host\n this.addEventListener('click', this.handleClick);\n this.addEventListener('keydown', this.handleKeydown, { capture: true });\n this.addEventListener('keyup', this.handleKeyup, { capture: true });\n }\n\n override disconnectedCallback() {\n super.disconnectedCallback?.();\n this.removeEventListener('click', this.handleClick);\n this.removeEventListener('keydown', this.handleKeydown, { capture: true });\n this.removeEventListener('keyup', this.handleKeyup, { capture: true });\n }\n\n override updated(changedProperties: Map<string | number | symbol, unknown>) {\n super.updated?.(changedProperties);\n\n // Update ARIA attributes on host\n if (changedProperties.has('checked')) {\n this.setAttribute('aria-checked', this.checked ? 'true' : 'false');\n }\n\n if (changedProperties.has('disabled')) {\n if (this.disabled) {\n this.setAttribute('aria-disabled', 'true');\n } else {\n this.removeAttribute('aria-disabled');\n }\n }\n\n // Sync name attribute from internal state\n if (changedProperties.has('_name')) {\n if (this._name) {\n this.setAttribute('name', this._name);\n } else {\n this.removeAttribute('name');\n }\n }\n\n // Sync aria-required from internal state\n if (changedProperties.has('_required')) {\n if (this._required) {\n this.setAttribute('aria-required', 'true');\n } else {\n this.removeAttribute('aria-required');\n }\n }\n\n // logger\n if (!this.label) {\n this.logger.warn(`Label is required to ensure accessibility. Please, define a label for <it-radio/> .`);\n }\n }\n\n /**\n * Render internal structure (like Spectrum)\n * Just visual elements, no role/aria/events here (they're on the host)\n * Protected to allow subclasses (like it-rating-item) to override\n */\n // eslint-disable-next-line class-methods-use-this\n protected _renderInput() {\n // Render visual elements like Spectrum does\n // #input = container, #button = visual circle\n const inputRender = html`\n <div id=\"input\" part=\"input\"></div>\n <span id=\"button\" part=\"button\" class=\"form-check-input\"></span>\n `;\n\n return inputRender;\n }\n\n // Render the UI as a function of component state\n override render() {\n const supportTextId = `${this._id}-support-text`;\n\n const supportTextRender = html` ${when(\n this.supportText,\n () =>\n html`<slot name=\"helpText\"><small class=\"form-text\" id=\"${supportTextId}\">${this.supportText}</small></slot>`,\n )}`;\n\n const wrapperClasses = this.composeClass(\n 'form-check',\n this.inline && !this.grouped ? 'form-check-inline' : '',\n this.grouped && !this.inline ? 'form-check-group' : '',\n );\n const ariaDescribedBy = this.composeClass(\n this.supportText?.length > 0 ? supportTextId : '',\n this._ariaAttributes['aria-describedby']?.length > 0 ? this._ariaAttributes['aria-describedby'] : '',\n );\n const controlClasses = this.composeClass('radio-control', this.grouped ? 'radio-control-grouped' : '');\n const labelClasses = this.composeClass('radio-control-label', this.disabled ? 'disabled' : '');\n\n return html`\n <div class=\"${wrapperClasses}\" part=\"input-wrapper\" aria-describedby=\"${ifDefined(ariaDescribedBy || undefined)}\">\n <div id=\"radio-control\" part=\"radio-control\" class=\"${controlClasses}\">\n ${this._renderInput()}\n <span part=\"label\" class=\"${labelClasses}\"><slot name=\"label\">${this.label}</slot></span>\n </div>\n ${supportTextRender}\n </div>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'it-radio': ItRadio;\n }\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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aAAa,CAAC,UAAU;AACZ,CAAA,EAAA,OAAO,CA+PnB;;;;"}
1
+ {"version":3,"file":"it-radio.js","sources":["../../../src/it-radio.ts"],"sourcesContent":["import { BaseComponent } from '@italia/globals';\nimport { html } from 'lit';\nimport { customElement, property, queryAssignedElements, state } from 'lit/decorators.js';\nimport { when } from 'lit/directives/when.js';\nimport { ifDefined } from 'lit/directives/if-defined.js';\nimport { type ItRadioGroup } from '@italia/radio';\n\nimport styles from './radio.scss';\n\n@customElement('it-radio')\nexport class ItRadio extends BaseComponent {\n static styles = styles;\n\n /** The radio's value attribute */\n @property({ type: String, reflect: true })\n value = '';\n\n /** Whether the radio is disabled */\n @property({ type: Boolean, reflect: true })\n disabled = false;\n\n /** Draws the radio in a checked state. */\n @property({ type: Boolean, reflect: true })\n checked = false;\n\n /** The input's help text. */\n @property({ type: String, attribute: 'support-text' })\n supportText = '';\n\n /**\n * Internal reactive state synced from group\n * These replace the old getters that read from this.group\n */\n @state()\n private _name = '';\n\n @state()\n private _grouped = false;\n\n @state()\n private _required = false;\n\n @state()\n private _inline = false;\n\n @queryAssignedElements({ slot: 'label' })\n labelElements!: HTMLElement[];\n\n get label(): string {\n if (this.labelElements.length > 0) {\n return this.labelElements[0].innerText.trim();\n }\n return '';\n }\n\n get group(): ItRadioGroup | null {\n return this.closest('it-radio-group');\n }\n\n // Public getters now read from internal state (reactive)\n get name(): string {\n return this._name || this.group?.name || '';\n }\n\n get grouped(): boolean {\n return this._grouped;\n }\n\n get required(): boolean {\n return this._required;\n }\n\n get inline(): boolean {\n return this._inline;\n }\n\n get invalid(): boolean {\n // Read aria-invalid explicitly from the group: only the string \"true\" should be considered invalid\n const aria = this.group?.getAttribute ? this.group.getAttribute('aria-invalid') : null;\n return aria === 'true';\n }\n\n /**\n * PUBLIC API: Called by group to sync state\n * This replaces the need for requestUpdate() calls\n */\n syncFromGroup(groupState: { name?: string; grouped?: boolean; required?: boolean; inline?: boolean }): void {\n if (groupState.name !== undefined) this._name = groupState.name;\n if (groupState.grouped !== undefined) this._grouped = groupState.grouped;\n if (groupState.required !== undefined) this._required = groupState.required;\n if (groupState.inline !== undefined) this._inline = groupState.inline;\n }\n /**\n * Activate the radio via the group's public API\n */\n\n private activate(event: KeyboardEvent | PointerEvent | MouseEvent): void {\n if (this.checked || this.disabled) {\n return;\n }\n\n // Use the group's public API if available\n if (this.group) {\n this.group.selectRadio(this, event);\n } else {\n // Fallback if no group (shouldn't happen in normal usage)\n this.checked = true;\n }\n }\n\n /**\n * Handle keyup for Space key\n */\n private handleKeyup = (event: KeyboardEvent): void => {\n if (event.code === 'Space') {\n event.preventDefault();\n this.activate(event);\n }\n };\n\n /**\n * Handle keydown - delegate arrow keys to the group\n */\n private handleKeydown = (event: KeyboardEvent): void => {\n // Prevent Space from scrolling the page\n if (event.code === 'Space') {\n event.preventDefault();\n return;\n }\n\n // Let Tab and Shift+Tab work normally for navigation\n if (event.key === 'Tab') {\n this.group?.handleRadioKeyDown(this, event);\n return;\n }\n\n // Only prevent default for arrow keys (to prevent page scrolling)\n if (['ArrowUp', 'ArrowDown', 'ArrowLeft', 'ArrowRight'].includes(event.key)) {\n event.preventDefault();\n }\n\n // Delegate keyboard navigation to the group's public API\n this.group?.handleRadioKeyDown(this, event);\n };\n\n /**\n * Handle click on the host\n */\n private handleClick = (event: PointerEvent | MouseEvent): void => {\n this.activate(event);\n };\n\n override connectedCallback() {\n super.connectedCallback?.();\n\n // Set role on host for screen reader context\n this.setAttribute('role', 'radio');\n\n // Set initial tabindex if not already set (roving tabindex will be managed by group)\n if (!this.hasAttribute('tabindex')) {\n this.tabIndex = 0;\n }\n\n // Add event listeners on host\n this.addEventListener('click', this.handleClick);\n this.addEventListener('keydown', this.handleKeydown, { capture: true });\n this.addEventListener('keyup', this.handleKeyup, { capture: true });\n }\n\n override disconnectedCallback() {\n super.disconnectedCallback?.();\n this.removeEventListener('click', this.handleClick);\n this.removeEventListener('keydown', this.handleKeydown, { capture: true });\n this.removeEventListener('keyup', this.handleKeyup, { capture: true });\n }\n\n override updated(changedProperties: Map<string | number | symbol, unknown>) {\n super.updated?.(changedProperties);\n\n // Update ARIA attributes on host\n if (changedProperties.has('checked')) {\n this.setAttribute('aria-checked', this.checked ? 'true' : 'false');\n }\n\n if (changedProperties.has('disabled')) {\n if (this.disabled) {\n this.setAttribute('aria-disabled', 'true');\n } else {\n this.removeAttribute('aria-disabled');\n }\n }\n\n // Sync name attribute from internal state\n if (changedProperties.has('_name')) {\n if (this._name) {\n this.setAttribute('name', this._name);\n } else {\n this.removeAttribute('name');\n }\n }\n\n // Sync aria-required from internal state\n if (changedProperties.has('_required')) {\n if (this._required) {\n this.setAttribute('aria-required', 'true');\n } else {\n this.removeAttribute('aria-required');\n }\n }\n\n // logger\n if (!this.label) {\n this.logger.warn(`Label is required to ensure accessibility. Please, define a label for <it-radio/> .`);\n }\n }\n\n /**\n * Render internal structure (like Spectrum)\n * Just visual elements, no role/aria/events here (they're on the host)\n * Protected to allow subclasses (like it-rating-item) to override\n */\n // eslint-disable-next-line class-methods-use-this\n protected _renderInput() {\n // Render visual elements like Spectrum does\n // #input = container, #button = visual circle\n const inputRender = html`\n <div id=\"input\" part=\"input\"></div>\n <span id=\"button\" part=\"button\"></span>\n `;\n\n return inputRender;\n }\n\n // Render the UI as a function of component state\n override render() {\n const supportTextId = `${this._id}-support-text`;\n\n const supportTextRender = html` ${when(\n this.supportText,\n () =>\n html`<slot name=\"helpText\"><small class=\"form-text\" id=\"${supportTextId}\">${this.supportText}</small></slot>`,\n )}`;\n\n const wrapperClasses = this.composeClass(\n 'form-check',\n this.inline && !this.grouped ? 'form-check-inline' : '',\n this.grouped && !this.inline ? 'form-check-group' : '',\n );\n const ariaDescribedBy = this.composeClass(\n this.supportText?.length > 0 ? supportTextId : '',\n this._ariaAttributes['aria-describedby']?.length > 0 ? this._ariaAttributes['aria-describedby'] : '',\n );\n const controlClasses = this.composeClass('radio-control', this.grouped ? 'radio-control-grouped' : '');\n const labelClasses = this.composeClass('radio-control-label', this.disabled ? 'disabled' : '');\n\n return html`\n <div class=\"${wrapperClasses}\" part=\"input-wrapper\" aria-describedby=\"${ifDefined(ariaDescribedBy || undefined)}\">\n <div id=\"radio-control\" part=\"radio-control\" class=\"${controlClasses}\">\n ${this._renderInput()}\n <span part=\"label\" class=\"${labelClasses}\"><slot name=\"label\">${this.label}</slot></span>\n </div>\n ${supportTextRender}\n </div>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'it-radio': ItRadio;\n }\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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CAAA;AAGX,UAAA,CAAA;AADP,IAAA,KAAK,EAAE;;AACiB,CAAA,EAAA,OAAA,CAAA,SAAA,EAAA,UAAA,EAAA,MAAA,CAAA;AAGjB,UAAA,CAAA;AADP,IAAA,KAAK,EAAE;;AACkB,CAAA,EAAA,OAAA,CAAA,SAAA,EAAA,WAAA,EAAA,MAAA,CAAA;AAGlB,UAAA,CAAA;AADP,IAAA,KAAK,EAAE;;AACgB,CAAA,EAAA,OAAA,CAAA,SAAA,EAAA,SAAA,EAAA,MAAA,CAAA;AAGxB,UAAA,CAAA;AADC,IAAA,qBAAqB,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;;AACX,CAAA,EAAA,OAAA,CAAA,SAAA,EAAA,eAAA,EAAA,MAAA,CAAA;AApCnB,OAAO,GAAA,UAAA,CAAA;IADnB,aAAa,CAAC,UAAU;AACZ,CAAA,EAAA,OAAO,CA+PnB;;"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@italia/radio",
3
3
  "description": "Web component it-radio del Design system .italia",
4
- "version": "1.0.0-beta.6",
4
+ "version": "1.0.0-beta.8",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -34,9 +34,9 @@
34
34
  "custom-elements.json"
35
35
  ],
36
36
  "dependencies": {
37
- "bootstrap-italia": "3.0.0-beta.7",
37
+ "bootstrap-italia": "3.0.0-beta.9",
38
38
  "lit": "^3.3.0",
39
- "@italia/globals": "^1.0.0-beta.6"
39
+ "@italia/globals": "^1.0.0-beta.8"
40
40
  },
41
41
  "devDependencies": {
42
42
  "@custom-elements-manifest/analyzer": "^0.10.3",