@italia/upload 1.0.0-alpha.10

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.
@@ -0,0 +1,1876 @@
1
+ import { r as registerTranslation, t as translation, a as translation$1, F as FormControl, _ as __decorate, b as __metadata, c as FormControlController } from '../en-C97ZNr-2.js';
2
+ import { css, nothing, html } from 'lit';
3
+ import { query, property, state, customElement } from 'lit/decorators.js';
4
+ import { ifDefined } from 'lit/directives/if-defined.js';
5
+ import 'lit/directive.js';
6
+
7
+ var styles = css`@charset "UTF-8";
8
+ /***************************** 1 ****************************************/
9
+ /***************************** 2 ****************************************/
10
+ /***************************** 1 ****************************************/
11
+ /***************************** 2 ****************************************/
12
+ /***************************** 1 ****************************************/
13
+ /***************************** 2 ****************************************/
14
+ /***************************** 3 ****************************************/
15
+ /***************************** 1 ****************************************/
16
+ /***************************** 2 ****************************************/
17
+ /***************************** 3 ****************************************/
18
+ /***************************** NEUTRAL 1 ****************************************/
19
+ /***************************** NEUTRAL 2 ****************************************/
20
+ /***************************** NEUTRAL 2 / 3 ****************************************/
21
+ *,
22
+ *::before,
23
+ *::after {
24
+ box-sizing: border-box;
25
+ }
26
+
27
+ @media (prefers-reduced-motion: no-preference) {
28
+ :root {
29
+ scroll-behavior: smooth;
30
+ }
31
+ }
32
+
33
+ body {
34
+ margin: 0;
35
+ -webkit-text-size-adjust: 100%;
36
+ -webkit-tap-highlight-color: hsla(0, 0%, 0%, 0);
37
+ }
38
+
39
+ hr {
40
+ margin: 1rem 0;
41
+ color: inherit;
42
+ border: 0;
43
+ border-top: 1px solid;
44
+ opacity: 0.25;
45
+ }
46
+
47
+ p {
48
+ margin-top: 0;
49
+ margin-bottom: var(--bsi-paragraph-spacing);
50
+ }
51
+
52
+ abbr[title] {
53
+ text-decoration: underline dotted;
54
+ cursor: help;
55
+ text-decoration-skip-ink: none;
56
+ }
57
+
58
+ address {
59
+ margin-bottom: var(--bsi-spacing-s);
60
+ font-style: normal;
61
+ line-height: inherit;
62
+ }
63
+
64
+ ol,
65
+ ul {
66
+ padding-left: var(--bsi-spacing-l);
67
+ }
68
+
69
+ ol,
70
+ ul,
71
+ dl {
72
+ margin-top: 0;
73
+ margin-bottom: var(--bsi-spacing-s);
74
+ }
75
+
76
+ ol ol,
77
+ ul ul,
78
+ ol ul,
79
+ ul ol {
80
+ margin-bottom: 0;
81
+ }
82
+
83
+ dt {
84
+ font-weight: var(--bsi-font-weight-strong);
85
+ }
86
+
87
+ dd {
88
+ margin-bottom: var(--bsi-spacing-xxs);
89
+ margin-left: 0;
90
+ }
91
+
92
+ blockquote {
93
+ margin: 0 0 var(--bsi-spacing-s);
94
+ }
95
+
96
+ sub,
97
+ sup {
98
+ position: relative;
99
+ font-size: var(--bsi-font-size-1);
100
+ line-height: 0;
101
+ vertical-align: baseline;
102
+ }
103
+
104
+ sub {
105
+ bottom: -0.25em;
106
+ }
107
+
108
+ sup {
109
+ top: -0.5em;
110
+ }
111
+
112
+ a {
113
+ color: var(--bsi-color-link);
114
+ text-decoration: underline;
115
+ text-decoration-skip-ink: auto;
116
+ text-underline-offset: 2px;
117
+ }
118
+ a:hover {
119
+ color: var(--bsi-color-link-hover);
120
+ cursor: pointer;
121
+ }
122
+
123
+ pre,
124
+ code,
125
+ kbd,
126
+ samp {
127
+ font-size: 1em;
128
+ }
129
+
130
+ pre {
131
+ display: block;
132
+ margin-top: 0;
133
+ margin-bottom: var(--bsi-paragraph-spacing);
134
+ overflow: auto;
135
+ }
136
+ pre code {
137
+ word-break: normal;
138
+ }
139
+
140
+ a > code {
141
+ color: inherit;
142
+ }
143
+
144
+ figure {
145
+ margin: 0 0 1rem;
146
+ }
147
+
148
+ img,
149
+ svg {
150
+ vertical-align: middle;
151
+ }
152
+
153
+ table {
154
+ caption-side: bottom;
155
+ border-collapse: collapse;
156
+ }
157
+
158
+ caption {
159
+ padding-top: 0.5rem;
160
+ padding-bottom: 0.5rem;
161
+ color: hsl(210, 17%, 44%);
162
+ text-align: left;
163
+ }
164
+
165
+ th {
166
+ text-align: inherit;
167
+ text-align: -webkit-match-parent;
168
+ }
169
+
170
+ thead,
171
+ tbody,
172
+ tfoot,
173
+ tr,
174
+ td,
175
+ th {
176
+ border-color: inherit;
177
+ border-style: solid;
178
+ border-width: 0;
179
+ }
180
+
181
+ label {
182
+ display: inline-block;
183
+ }
184
+
185
+ button {
186
+ border-radius: 0;
187
+ }
188
+
189
+ button:focus:not(:focus-visible) {
190
+ outline: 0;
191
+ }
192
+
193
+ input,
194
+ button,
195
+ select,
196
+ optgroup,
197
+ textarea {
198
+ margin: 0;
199
+ font-family: inherit;
200
+ font-size: inherit;
201
+ line-height: inherit;
202
+ }
203
+
204
+ button,
205
+ select {
206
+ text-transform: none;
207
+ }
208
+
209
+ [role=button] {
210
+ cursor: pointer;
211
+ }
212
+
213
+ select {
214
+ word-wrap: normal;
215
+ }
216
+ select:disabled {
217
+ opacity: 1;
218
+ }
219
+
220
+ [list]:not([type=date]):not([type=datetime-local]):not([type=month]):not([type=week]):not([type=time])::-webkit-calendar-picker-indicator {
221
+ display: none !important;
222
+ }
223
+
224
+ button,
225
+ [type=button],
226
+ [type=reset],
227
+ [type=submit] {
228
+ -webkit-appearance: button;
229
+ }
230
+ button:not(:disabled),
231
+ [type=button]:not(:disabled),
232
+ [type=reset]:not(:disabled),
233
+ [type=submit]:not(:disabled) {
234
+ cursor: pointer;
235
+ }
236
+
237
+ ::-moz-focus-inner {
238
+ padding: 0;
239
+ border-style: none;
240
+ }
241
+
242
+ textarea {
243
+ resize: vertical;
244
+ }
245
+
246
+ fieldset {
247
+ min-width: 0;
248
+ padding: 0;
249
+ margin: 0;
250
+ border: 0;
251
+ }
252
+
253
+ ::-webkit-datetime-edit-fields-wrapper,
254
+ ::-webkit-datetime-edit-text,
255
+ ::-webkit-datetime-edit-minute,
256
+ ::-webkit-datetime-edit-hour-field,
257
+ ::-webkit-datetime-edit-day-field,
258
+ ::-webkit-datetime-edit-month-field,
259
+ ::-webkit-datetime-edit-year-field {
260
+ padding: 0;
261
+ }
262
+
263
+ ::-webkit-inner-spin-button {
264
+ height: auto;
265
+ }
266
+
267
+ [type=search] {
268
+ outline-offset: -2px;
269
+ -webkit-appearance: textfield;
270
+ }
271
+
272
+ /* rtl:raw:
273
+ [type="tel"],
274
+ [type="url"],
275
+ [type="email"],
276
+ [type="number"] {
277
+ direction: ltr;
278
+ }
279
+ */
280
+ ::-webkit-search-decoration {
281
+ -webkit-appearance: none;
282
+ }
283
+
284
+ ::-webkit-color-swatch-wrapper {
285
+ padding: 0;
286
+ }
287
+
288
+ ::file-selector-button {
289
+ font: inherit;
290
+ -webkit-appearance: button;
291
+ }
292
+
293
+ output {
294
+ display: inline-block;
295
+ }
296
+
297
+ iframe {
298
+ border: 0;
299
+ }
300
+
301
+ summary {
302
+ display: list-item;
303
+ cursor: pointer;
304
+ }
305
+
306
+ progress {
307
+ vertical-align: baseline;
308
+ }
309
+
310
+ [hidden] {
311
+ display: none !important;
312
+ }
313
+
314
+ .visually-hidden,
315
+ .visually-hidden-focusable:not(:focus):not(:focus-within) {
316
+ position: absolute !important;
317
+ width: 1px !important;
318
+ height: 1px !important;
319
+ padding: 0 !important;
320
+ margin: -1px !important;
321
+ overflow: hidden !important;
322
+ clip: rect(0, 0, 0, 0) !important;
323
+ white-space: nowrap !important;
324
+ border: 0 !important;
325
+ }
326
+
327
+ .avatar {
328
+ --bsi-avatar-background: var(--bsi-color-background-secondary-lighter);
329
+ --bsi-avatar-dot-border-color: var(--bsi-color-border-inverse);
330
+ --bsi-avatar-dot-border-size: 2px;
331
+ --bsi-avatar-dot-offset-bottom: 0;
332
+ --bsi-avatar-dot-offset-right: 0;
333
+ --bsi-avatar-dot-offset-top: 4px;
334
+ --bsi-avatar-dot-size: 12px;
335
+ --bsi-avatar-font-size: var(--bsi-font-size-3);
336
+ --bsi-avatar-font-weight: var(--bsi-font-weight-solid);
337
+ --bsi-avatar-icon-size: var(--bsi-icon-size-s);
338
+ --bsi-avatar-overlay-background: var(--bsi-color-background-emphasis);
339
+ --bsi-avatar-radius: var(--bsi-radius-circle);
340
+ --bsi-avatar-size: 2.5rem;
341
+ --bsi-avatar-text-color: var(--bsi-color-text-secondary);
342
+ --bsi-avatar-dropdown-margin-left: -24px;
343
+ --bsi-avatar-dropdown-margin-top: 24px;
344
+ }
345
+
346
+ /* stylelint-disable-next-line no-duplicate-selectors */
347
+ .avatar {
348
+ position: relative;
349
+ z-index: 1;
350
+ display: inline-flex;
351
+ align-items: center;
352
+ justify-content: center;
353
+ width: var(--bsi-avatar-size);
354
+ height: var(--bsi-avatar-size);
355
+ border-radius: var(--bsi-avatar-radius);
356
+ background: var(--bsi-avatar-background);
357
+ color: var(--bsi-avatar-text-color);
358
+ transition: background-color var(--bsi-transition-instant);
359
+ }
360
+ .avatar.avatar-primary {
361
+ --bsi-avatar-background: var(--bsi-theme-primary);
362
+ --bsi-avatar-text-color: var(--bsi-color-text-inverse);
363
+ }
364
+ .avatar.avatar-secondary {
365
+ --bsi-avatar-background: var(--bsi-color-background-secondary);
366
+ --bsi-avatar-text-color: var(--bsi-color-text-inverse);
367
+ }
368
+ .avatar.size-xs {
369
+ --bsi-avatar-dot-border-size: 1px;
370
+ --bsi-avatar-font-size: 0.625rem;
371
+ --bsi-avatar-size: 1rem;
372
+ --bsi-avatar-icon-size: 0.625rem;
373
+ }
374
+ .avatar.size-sm {
375
+ --bsi-avatar-dot-border-size: 1px;
376
+ --bsi-avatar-font-size: var(--bsi-font-size-1);
377
+ --bsi-avatar-size: 1.5rem;
378
+ --bsi-avatar-icon-size: var(--bsi-icon-size-xs);
379
+ }
380
+ .avatar.size-md {
381
+ --bsi-avatar-font-size: var(--bsi-font-size-4);
382
+ --bsi-avatar-size: 2.5rem;
383
+ --bsi-avatar-icon-size: var(--bsi-icon-size-s);
384
+ --bsi-avatar-dot-offset-right: -2px;
385
+ }
386
+ .avatar.size-lg {
387
+ --bsi-avatar-font-size: var(--bsi-font-size-6);
388
+ --bsi-avatar-size: 3.5rem;
389
+ --bsi-avatar-icon-size: var(--bsi-icon-size-m);
390
+ --bsi-avatar-dot-offset-right: -2px;
391
+ --bsi-avatar-dot-size: 14px;
392
+ }
393
+ .avatar.size-xl {
394
+ --bsi-avatar-font-size: var(--bsi-font-size-9);
395
+ --bsi-avatar-size: 5rem;
396
+ --bsi-avatar-icon-size: var(--bsi-icon-size-l);
397
+ --bsi-avatar-dot-size: 16px;
398
+ }
399
+ .avatar.size-xxl {
400
+ --bsi-avatar-font-size: var(--bsi-font-size-11);
401
+ --bsi-avatar-size: 7rem;
402
+ --bsi-avatar-icon-size: var(--bsi-icon-size-xl);
403
+ --bsi-avatar-dot-size: 20px;
404
+ --bsi-avatar-dot-offset-right: 4px;
405
+ }
406
+ .avatar-wrapper {
407
+ position: relative;
408
+ z-index: 1;
409
+ }
410
+ .avatar-presence, .avatar-status {
411
+ position: absolute;
412
+ right: var(--bsi-avatar-dot-offset-right);
413
+ z-index: 10;
414
+ display: flex;
415
+ align-items: center;
416
+ justify-content: center;
417
+ width: var(--bsi-avatar-dot-size);
418
+ height: var(--bsi-avatar-dot-size);
419
+ border: var(--bsi-avatar-dot-border-size) solid var(--bsi-avatar-dot-border-color);
420
+ border-radius: var(--bsi-avatar-radius);
421
+ background: hsl(210, 3%, 85%);
422
+ color: var(--bsi-color-text-inverse);
423
+ }
424
+ .avatar-presence .icon, .avatar-status .icon {
425
+ stroke-width: 2px;
426
+ stroke: var(--bsi-icon-inverse);
427
+ }
428
+ .avatar-presence.active, .avatar-status.approved {
429
+ background: var(--bsi-color-background-success);
430
+ }
431
+ .avatar-presence.busy, .avatar-status.declined {
432
+ background: hsl(350, 60%, 50%);
433
+ }
434
+ .avatar-presence {
435
+ bottom: 8px;
436
+ }
437
+ .avatar-presence.hidden:after {
438
+ position: absolute;
439
+ top: 50%;
440
+ left: 50%;
441
+ content: "";
442
+ width: calc(100% - 4px);
443
+ height: calc(100% - 4px);
444
+ border-radius: 50%;
445
+ background: var(--bsi-color-background-inverse);
446
+ transform: translateX(-50%) translateY(-50%);
447
+ }
448
+ .avatar-status {
449
+ top: var(--bsi-avatar-dot-offset-top);
450
+ }
451
+ .avatar-status.notify {
452
+ background: var(--bsi-theme-primary);
453
+ }
454
+ .avatar img {
455
+ width: 100%;
456
+ height: 100%;
457
+ border-radius: var(--bsi-avatar-radius);
458
+ object-fit: cover;
459
+ object-position: center;
460
+ }
461
+ .avatar p {
462
+ margin: 0;
463
+ color: var(--bsi-avatar-text-color);
464
+ font-size: var(--bsi-avatar-font-size);
465
+ font-weight: var(--bsi-avatar-font-weight);
466
+ line-height: 1;
467
+ }
468
+ .avatar .icon {
469
+ width: var(--bsi-avatar-icon-size);
470
+ height: var(--bsi-avatar-icon-size);
471
+ }
472
+ .avatar ~ span {
473
+ margin-left: var(--bsi-spacing-xxs);
474
+ }
475
+
476
+ a.avatar::after,
477
+ a .avatar::after {
478
+ position: absolute;
479
+ top: 0;
480
+ right: 0;
481
+ z-index: 10;
482
+ content: "";
483
+ display: block;
484
+ width: 100%;
485
+ height: 100%;
486
+ border-radius: var(--bsi-avatar-radius);
487
+ opacity: 0;
488
+ background: var(--bsi-color-background-emphasis);
489
+ transition: opacity 0.2s;
490
+ }
491
+ a.avatar:hover::after,
492
+ a .avatar:hover::after {
493
+ opacity: 0.25;
494
+ }
495
+
496
+ a.avatar,
497
+ a.avatar:hover,
498
+ a.avatar:hover p,
499
+ a .avatar:hover,
500
+ a .avatar:hover p {
501
+ text-decoration: none;
502
+ }
503
+
504
+ .avatar-dropdown {
505
+ position: relative;
506
+ overflow: visible;
507
+ }
508
+ .avatar-dropdown .dropdown {
509
+ position: absolute;
510
+ top: 0;
511
+ right: 0;
512
+ left: 0;
513
+ display: flex;
514
+ align-items: center;
515
+ justify-content: center;
516
+ height: 100%;
517
+ border: 0;
518
+ }
519
+ .avatar-dropdown .dropdown-menu {
520
+ margin-left: var(--bsi-avatar-dropdown-margin-left) !important;
521
+ margin-top: var(--bsi-avatar-dropdown-margin-top) !important;
522
+ }
523
+ .avatar-dropdown .btn-dropdown {
524
+ padding: 0;
525
+ color: inherit;
526
+ font-size: var(--bsi-avatar-font-size);
527
+ line-height: 0;
528
+ }
529
+ .avatar-dropdown .btn-dropdown:focus {
530
+ box-shadow: none;
531
+ }
532
+ .avatar-dropdown .link-list {
533
+ white-space: nowrap;
534
+ }
535
+
536
+ .avatar-extra-text {
537
+ display: inline-flex;
538
+ align-items: center;
539
+ justify-content: flex-start;
540
+ margin-bottom: 16px;
541
+ }
542
+ .avatar-extra-text .avatar {
543
+ flex-shrink: 0;
544
+ }
545
+ .avatar-extra-text .extra-text {
546
+ margin-left: var(--bsi-spacing-s);
547
+ }
548
+ .avatar-extra-text .extra-text h3,
549
+ .avatar-extra-text .extra-text h4 {
550
+ margin: 0;
551
+ font-size: var(--bsi-heading-6-font-size);
552
+ }
553
+ .avatar-extra-text .extra-text h3 a,
554
+ .avatar-extra-text .extra-text h4 a {
555
+ display: inline-block;
556
+ }
557
+ .avatar-extra-text .extra-text p,
558
+ .avatar-extra-text .extra-text time {
559
+ margin: 0;
560
+ color: var(--bsi-color-text-secondary);
561
+ font-size: var(--bsi-caption-font-size);
562
+ text-transform: uppercase;
563
+ }
564
+
565
+ .avatar-group > li {
566
+ margin-bottom: var(--bsi-spacing-s);
567
+ display: flex;
568
+ }
569
+ .avatar-group > li:last-child {
570
+ margin-bottom: 0;
571
+ }
572
+ .avatar-group > li .list-item {
573
+ padding: 0;
574
+ }
575
+
576
+ .avatar-group-stacked {
577
+ display: flex;
578
+ flex-direction: row;
579
+ align-items: flex-start;
580
+ justify-content: flex-start;
581
+ margin: 0;
582
+ padding: 0;
583
+ }
584
+ .avatar-group-stacked li {
585
+ list-style-type: none;
586
+ line-height: 0;
587
+ }
588
+ .avatar-group-stacked li > .avatar {
589
+ margin-left: -6px;
590
+ border: 2px solid var(--bsi-color-border-inverse);
591
+ }
592
+
593
+ .upload,
594
+ .upload-avatar {
595
+ position: absolute;
596
+ z-index: -1;
597
+ width: 0.1px;
598
+ height: 0.1px;
599
+ overflow: hidden;
600
+ opacity: 0;
601
+ }
602
+
603
+ .upload[type=file] + label {
604
+ display: inline-block;
605
+ margin-bottom: 0;
606
+ max-width: 80%;
607
+ padding: var(--bsi-spacing-xs) var(--bsi-spacing-m);
608
+ overflow: hidden;
609
+ border-radius: var(--bsi-form-control-border-radius);
610
+ background-color: var(--bsi-color-background-primary);
611
+ color: var(--bsi-color-text-inverse);
612
+ font-size: 1rem;
613
+ font-weight: 700;
614
+ transition: background-color var(--bsi-transition-instant);
615
+ cursor: pointer;
616
+ }
617
+ .upload[type=file] + label:hover {
618
+ background-color: var(--bsi-color-background-primary-hover);
619
+ }
620
+ .upload[type=file] + label svg {
621
+ margin-right: var(--bsi-spacing-xxs);
622
+ fill: var(--bsi-icon-inverse);
623
+ }
624
+
625
+ .upload-pictures-wall {
626
+ display: flex;
627
+ flex-wrap: wrap;
628
+ padding: 0;
629
+ }
630
+ .upload-pictures-wall > li {
631
+ margin-right: var(--bsi-spacing-xxs);
632
+ margin-bottom: var(--bsi-spacing-xxs);
633
+ list-style-type: none;
634
+ }
635
+ .upload-pictures-wall > li:last-child {
636
+ margin-right: 0;
637
+ }
638
+ .upload-pictures-wall .upload[type=file] + label {
639
+ display: table-cell;
640
+ width: 128px;
641
+ height: 128px;
642
+ padding: 0;
643
+ border: 2px dashed var(--bsi-color-border-primary);
644
+ border-radius: 0;
645
+ background-color: var(--bsi-color-border-primary-lighter);
646
+ color: var(--bsi-color-text-primary);
647
+ font-weight: 600;
648
+ text-align: center;
649
+ vertical-align: middle;
650
+ transition: border-color var(--bsi-transition-instant);
651
+ }
652
+ .upload-pictures-wall .upload[type=file] + label .icon {
653
+ display: block;
654
+ flex-shrink: 0;
655
+ width: 48px;
656
+ height: 48px;
657
+ margin: 0 auto;
658
+ fill: var(--bsi-icon-primary);
659
+ }
660
+ .upload-pictures-wall .upload[type=file] + label:hover {
661
+ border: 2px dashed var(--bsi-color-border-primary-hover);
662
+ }
663
+ .upload-pictures-wall .upload-image {
664
+ flex-shrink: 0;
665
+ width: 128px;
666
+ height: 128px;
667
+ }
668
+ .upload-pictures-wall .upload-image img {
669
+ width: 100%;
670
+ height: 100%;
671
+ object-fit: cover;
672
+ }
673
+
674
+ .upload-file-list {
675
+ margin-top: 5px;
676
+ padding: 0;
677
+ }
678
+ .upload-file-list.upload-file-list-image .progress {
679
+ left: 52px;
680
+ }
681
+ .upload-file-list .upload-file {
682
+ position: relative;
683
+ display: flex;
684
+ align-items: center;
685
+ max-width: 375px;
686
+ margin-bottom: var(--bsi-spacing-s);
687
+ list-style-type: none;
688
+ }
689
+ .upload-file-list .upload-file.uploading .icon {
690
+ fill: var(--bsi-icon-secondary);
691
+ }
692
+ .upload-file-list .upload-file.uploading p {
693
+ color: var(--bsi-color-text-secondary);
694
+ }
695
+ .upload-file-list .upload-file.success svg {
696
+ fill: var(--bsi-icon-success);
697
+ }
698
+ .upload-file-list .upload-file.success p {
699
+ color: var(--bsi-color-text-success);
700
+ }
701
+ .upload-file-list .upload-file.success p .upload-file-weight {
702
+ display: inline-block;
703
+ }
704
+ .upload-file-list .upload-file.error svg {
705
+ fill: var(--bsi-icon-danger);
706
+ }
707
+ .upload-file-list .upload-file.error p {
708
+ color: var(--bsi-color-text-danger);
709
+ }
710
+ .upload-file-list .upload-file svg {
711
+ flex-shrink: 0;
712
+ }
713
+ .upload-file-list .upload-file .upload-image {
714
+ flex-shrink: 0;
715
+ width: 40px;
716
+ height: 40px;
717
+ }
718
+ .upload-file-list .upload-file .upload-image img {
719
+ width: 100%;
720
+ height: 100%;
721
+ object-fit: cover;
722
+ }
723
+ .upload-file-list .upload-file p {
724
+ margin: 0;
725
+ margin-left: 12px;
726
+ overflow: hidden;
727
+ font-size: 0.875rem;
728
+ font-weight: 600;
729
+ text-overflow: ellipsis;
730
+ white-space: nowrap;
731
+ }
732
+ .upload-file-list .upload-file p .upload-file-weight {
733
+ display: none;
734
+ margin-left: 10px;
735
+ color: var(--bsi-color-text-secondary);
736
+ }
737
+ .upload-file-list .upload-file button {
738
+ margin-left: auto;
739
+ padding: 0;
740
+ border: 0;
741
+ background: transparent;
742
+ }
743
+ .upload-file-list .upload-file button:hover {
744
+ cursor: pointer;
745
+ }
746
+ .upload-file-list .upload-file button:hover svg {
747
+ fill: var(--bsi-icon-primary);
748
+ }
749
+ .upload-file-list .progress {
750
+ position: absolute;
751
+ bottom: -4px;
752
+ left: 36px;
753
+ width: calc(100% - 45px);
754
+ height: 4px;
755
+ background-color: hsl(210, 3%, 85%);
756
+ box-shadow: none;
757
+ }
758
+ .upload-file-list .progress.progress-image {
759
+ width: calc(100% - 60px);
760
+ }
761
+
762
+ .upload-avatar-container {
763
+ position: absolute;
764
+ top: 0;
765
+ left: 0;
766
+ width: 100%;
767
+ height: 100%;
768
+ }
769
+ .upload-avatar-container .upload-avatar[type=file] + label {
770
+ position: absolute;
771
+ top: 0;
772
+ left: 0;
773
+ width: 100%;
774
+ height: 100%;
775
+ }
776
+ .upload-avatar-container .upload-avatar[type=file] + label svg {
777
+ display: none;
778
+ }
779
+ .upload-avatar-container .upload-avatar[type=file] + label span {
780
+ display: none;
781
+ }
782
+
783
+ .avatar-upload {
784
+ overflow: hidden;
785
+ }
786
+
787
+ .avatar-upload-wrapper .avatar-upload-icon {
788
+ position: absolute;
789
+ right: 4px;
790
+ bottom: 16px;
791
+ display: flex;
792
+ align-items: center;
793
+ justify-content: center;
794
+ width: 26px;
795
+ height: 26px;
796
+ border: 2px solid var(--bsi-color-border-inverse);
797
+ border-radius: 50%;
798
+ background: hsl(210, 6.2290689886%, 92.535%);
799
+ pointer-events: none;
800
+ }
801
+ .avatar-upload-wrapper .avatar-upload-icon > svg {
802
+ width: 16px;
803
+ height: 16px;
804
+ }
805
+ .avatar-upload-wrapper.size-sm .avatar {
806
+ width: 80px;
807
+ height: 80px;
808
+ }
809
+ .avatar-upload-wrapper.size-sm .avatar-upload-icon {
810
+ right: 4px;
811
+ bottom: 6px;
812
+ width: 18px;
813
+ height: 18px;
814
+ }
815
+ .avatar-upload-wrapper.size-sm .avatar-upload-icon > svg {
816
+ width: 12px;
817
+ height: 12px;
818
+ }
819
+
820
+ .upload-dragdrop {
821
+ display: inline-flex;
822
+ align-items: center;
823
+ }
824
+ .upload-dragdrop.dragover .upload-dragdrop-image img, .upload-dragdrop.loading .upload-dragdrop-image img {
825
+ transform: translateX(-50%) translateY(-50%) scale(0.85);
826
+ }
827
+ .upload-dragdrop.loading p:not(.upload-dragdrop-weight) {
828
+ font-style: italic;
829
+ }
830
+ .upload-dragdrop.loading .upload-dragdrop-loading {
831
+ opacity: 1;
832
+ }
833
+ .upload-dragdrop.loading .upload-dragdrop-text .upload-dragdrop-weight, .upload-dragdrop.success .upload-dragdrop-text .upload-dragdrop-weight {
834
+ visibility: visible;
835
+ }
836
+ .upload-dragdrop.success .upload-dragdrop-success {
837
+ opacity: 1;
838
+ transform: scale(1);
839
+ }
840
+
841
+ .upload-dragdrop-text p {
842
+ margin: 0;
843
+ color: var(--bsi-color-text-secondary);
844
+ font-size: 0.875rem;
845
+ }
846
+ .upload-dragdrop-text p.upload-dragdrop-weight {
847
+ visibility: hidden;
848
+ color: var(--bsi-color-text-secondary);
849
+ font-size: 0.75rem;
850
+ }
851
+ .upload-dragdrop-text p.upload-dragdrop-weight svg {
852
+ fill: var(--bsi-icon-secondary);
853
+ }
854
+ .upload-dragdrop-text h5 {
855
+ margin: 0;
856
+ color: var(--bsi-color-text-base);
857
+ }
858
+
859
+ .upload-dragdrop-input {
860
+ position: absolute;
861
+ z-index: -1;
862
+ width: 0.1px;
863
+ height: 0.1px;
864
+ overflow: hidden;
865
+ opacity: 0;
866
+ }
867
+ .upload-dragdrop-input[type=file] + label {
868
+ color: var(--bsi-color-text-primary);
869
+ text-decoration: underline;
870
+ cursor: pointer;
871
+ }
872
+ .upload-dragdrop-input:focus[type=file] + label {
873
+ outline: auto 5px -webkit-focus-ring-color;
874
+ }
875
+
876
+ .upload-dragdrop-loading {
877
+ position: absolute;
878
+ top: 0;
879
+ right: 0;
880
+ bottom: 0;
881
+ left: 0;
882
+ width: 128px;
883
+ height: 128px;
884
+ overflow: hidden;
885
+ border-radius: 50%;
886
+ opacity: 0;
887
+ transition: opacity 0.2s;
888
+ }
889
+ .upload-dragdrop-loading .progress-donut {
890
+ position: relative;
891
+ }
892
+ .upload-dragdrop-loading .progress-donut .progressbar-text {
893
+ color: #000 !important;
894
+ font-weight: 700;
895
+ }
896
+ .upload-dragdrop-loading .progress-donut svg {
897
+ position: relative;
898
+ }
899
+ .upload-dragdrop-loading .progress-donut svg path:first-child {
900
+ display: none;
901
+ }
902
+ .upload-dragdrop-loading .progress-donut:before {
903
+ position: absolute;
904
+ top: 50%;
905
+ left: 50%;
906
+ z-index: 0;
907
+ content: "";
908
+ width: 67px;
909
+ height: 67px;
910
+ border-radius: 50%;
911
+ background: #fff;
912
+ transform: translateX(-50%) translateY(-50%);
913
+ }
914
+
915
+ .upload-dragdrop-image {
916
+ position: relative;
917
+ flex-shrink: 0;
918
+ width: 128px;
919
+ height: 128px;
920
+ margin-right: var(--bsi-spacing-s);
921
+ }
922
+ .upload-dragdrop-image img {
923
+ position: absolute;
924
+ top: 50%;
925
+ left: 50%;
926
+ display: block;
927
+ width: 100%;
928
+ height: 100%;
929
+ overflow: hidden;
930
+ border-radius: 50%;
931
+ transform: translateX(-50%) translateY(-50%);
932
+ transform-origin: center center;
933
+ transition: transform 0.4s cubic-bezier(0.33, 1.07, 0.54, 1);
934
+ }
935
+ .upload-dragdrop-image .upload-dragdrop-success {
936
+ position: absolute;
937
+ top: calc(50% - 18px);
938
+ left: 20px;
939
+ display: flex;
940
+ align-items: center;
941
+ justify-content: center;
942
+ width: 36px;
943
+ height: 36px;
944
+ border-radius: 50%;
945
+ opacity: 0;
946
+ background: var(--bsi-color-background-success);
947
+ transform: scale(0.6);
948
+ transition: opacity 0.2s, transform 0.5s cubic-bezier(0.75, -0.5, 0, 1.75);
949
+ }
950
+ .upload-dragdrop-image .upload-dragdrop-success svg {
951
+ width: 30px;
952
+ height: 30px;
953
+ fill: var(--bsi-icon-inverse);
954
+ }
955
+ .upload-dragdrop-image .upload-dragdrop-success .upload-dragdrop-text h5 + p {
956
+ color: var(--bsi-color-text-success);
957
+ font-weight: var(--bsi-font-weight-solid);
958
+ }
959
+
960
+ @media (min-width: 576px) {
961
+ .upload[type=file] + label {
962
+ font-size: var(--bsi-label-font-size-s);
963
+ }
964
+ }
965
+ @media (min-width: 768px) {
966
+ .upload-dragdrop-image {
967
+ width: 180px;
968
+ height: 180px;
969
+ margin-right: 32px;
970
+ }
971
+ .upload-dragdrop-image .upload-dragdrop-success {
972
+ left: 28px;
973
+ }
974
+ .upload-dragdrop-loading {
975
+ width: 180px;
976
+ height: 180px;
977
+ }
978
+ .upload-dragdrop-loading .progress-donut:before {
979
+ content: "";
980
+ width: 94px;
981
+ height: 94px;
982
+ }
983
+ }
984
+ @media (min-width: 1200px) {
985
+ .avatar-upload:hover .upload-avatar-container,
986
+ .avatar-upload:focus-within .upload-avatar-container {
987
+ opacity: 1;
988
+ }
989
+ .upload-avatar-container {
990
+ top: auto;
991
+ right: 0;
992
+ bottom: -10%;
993
+ left: 0;
994
+ width: 100%;
995
+ height: 60%;
996
+ opacity: 0;
997
+ background-color: var(--bsi-overlay-background-primary-muted);
998
+ transition: opacity var(--bsi-transition-instant);
999
+ }
1000
+ .upload-avatar-container .upload-avatar[type=file] + label {
1001
+ display: flex;
1002
+ flex-direction: column;
1003
+ align-items: center;
1004
+ justify-content: flex-start;
1005
+ width: 100%;
1006
+ height: 100%;
1007
+ margin: 0;
1008
+ padding-top: var(--bsi-spacing-xxs);
1009
+ color: var(--bsi-color-text-inverse);
1010
+ font-size: 0.75rem;
1011
+ text-align: center;
1012
+ cursor: pointer;
1013
+ }
1014
+ .upload-avatar-container .upload-avatar[type=file] + label span {
1015
+ display: block;
1016
+ }
1017
+ .upload-avatar-container .upload-avatar[type=file] + label svg {
1018
+ display: block;
1019
+ width: 20px;
1020
+ height: 20px;
1021
+ fill: var(--bsi-icon-inverse);
1022
+ }
1023
+ .upload-avatar-container .upload-avatar:focus:not([data-focus-mouse=true])[type=file] + label {
1024
+ outline: auto 5px -webkit-focus-ring-color;
1025
+ }
1026
+ .avatar-upload-wrapper .avatar-upload-icon {
1027
+ display: none;
1028
+ }
1029
+ .avatar-upload-wrapper.size-sm .upload-avatar[type=file] + label span {
1030
+ display: none;
1031
+ }
1032
+ }
1033
+ .valid-feedback {
1034
+ display: none;
1035
+ width: 100%;
1036
+ margin-top: 0.25rem;
1037
+ font-size: 0.875rem;
1038
+ color: hsl(160, 100%, 25%);
1039
+ }
1040
+
1041
+ .valid-tooltip {
1042
+ position: absolute;
1043
+ top: 100%;
1044
+ z-index: 5;
1045
+ display: none;
1046
+ max-width: 100%;
1047
+ padding: 1rem 1rem;
1048
+ margin-top: 0.1rem;
1049
+ font-size: 0.875rem;
1050
+ color: hsl(0, 0%, 100%);
1051
+ background-color: rgb(0, 127.5, 85);
1052
+ border-radius: 4px;
1053
+ }
1054
+
1055
+ .was-validated :valid ~ .valid-feedback,
1056
+ .was-validated :valid ~ .valid-tooltip,
1057
+ .is-valid ~ .valid-feedback,
1058
+ .is-valid ~ .valid-tooltip {
1059
+ display: block;
1060
+ }
1061
+
1062
+ .was-validated .form-control:valid, .form-control.is-valid {
1063
+ border-color: hsl(160, 100%, 25%);
1064
+ padding-right: calc(1.5em + 0.75rem);
1065
+ background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='hsl%28160, 100%, 25%%29' d='M2.3 6.73.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3e%3c/svg%3e");
1066
+ background-repeat: no-repeat;
1067
+ background-position: right calc(0.375em + 0.1875rem) center;
1068
+ background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
1069
+ }
1070
+ .was-validated .form-control:valid:focus, .form-control.is-valid:focus {
1071
+ border-color: hsl(160, 100%, 25%);
1072
+ box-shadow: 0 0 0 0.25rem rgba(0, 127.5, 85, 0.25);
1073
+ }
1074
+
1075
+ .was-validated textarea.form-control:valid, textarea.form-control.is-valid {
1076
+ padding-right: calc(1.5em + 0.75rem);
1077
+ background-position: top calc(0.375em + 0.1875rem) right calc(0.375em + 0.1875rem);
1078
+ }
1079
+
1080
+ .was-validated .form-select:valid, .form-select.is-valid {
1081
+ border-color: hsl(160, 100%, 25%);
1082
+ }
1083
+ .was-validated .form-select:valid:not([multiple]):not([size]), .was-validated .form-select:valid:not([multiple])[size="1"], .form-select.is-valid:not([multiple]):not([size]), .form-select.is-valid:not([multiple])[size="1"] {
1084
+ padding-right: 4.125rem;
1085
+ 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%, 15%%29' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e"), url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='hsl%28160, 100%, 25%%29' d='M2.3 6.73.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3e%3c/svg%3e");
1086
+ background-position: right 0.75rem center, center right 2.25rem;
1087
+ background-size: 16px 12px, calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
1088
+ }
1089
+ .was-validated .form-select:valid:focus, .form-select.is-valid:focus {
1090
+ border-color: hsl(160, 100%, 25%);
1091
+ box-shadow: 0 0 0 0.25rem rgba(0, 127.5, 85, 0.25);
1092
+ }
1093
+
1094
+ .was-validated .form-control-color:valid, .form-control-color.is-valid {
1095
+ width: calc(3rem + calc(1.5em + 0.75rem));
1096
+ }
1097
+
1098
+ .was-validated .form-check-input:valid, .form-check-input.is-valid {
1099
+ border-color: hsl(160, 100%, 25%);
1100
+ }
1101
+ .was-validated .form-check-input:valid:checked, .form-check-input.is-valid:checked {
1102
+ background-color: hsl(160, 100%, 25%);
1103
+ }
1104
+ .was-validated .form-check-input:valid:focus, .form-check-input.is-valid:focus {
1105
+ box-shadow: 0 0 0 0.25rem rgba(0, 127.5, 85, 0.25);
1106
+ }
1107
+ .was-validated .form-check-input:valid ~ .form-check-label, .form-check-input.is-valid ~ .form-check-label {
1108
+ color: hsl(160, 100%, 25%);
1109
+ }
1110
+
1111
+ .form-check-inline .form-check-input ~ .valid-feedback {
1112
+ margin-left: 0.5em;
1113
+ }
1114
+
1115
+ .was-validated .input-group > .form-control:not(:focus):valid, .input-group > .form-control:not(:focus).is-valid,
1116
+ .was-validated .input-group > .form-select:not(:focus):valid,
1117
+ .input-group > .form-select:not(:focus).is-valid,
1118
+ .was-validated .input-group > .form-floating:not(:focus-within):valid,
1119
+ .input-group > .form-floating:not(:focus-within).is-valid {
1120
+ z-index: 3;
1121
+ }
1122
+
1123
+ .invalid-feedback {
1124
+ display: none;
1125
+ width: 100%;
1126
+ margin-top: 0.25rem;
1127
+ font-size: 0.875rem;
1128
+ color: hsl(350, 60%, 50%);
1129
+ }
1130
+
1131
+ .invalid-tooltip {
1132
+ position: absolute;
1133
+ top: 100%;
1134
+ z-index: 5;
1135
+ display: none;
1136
+ max-width: 100%;
1137
+ padding: 1rem 1rem;
1138
+ margin-top: 0.1rem;
1139
+ font-size: 0.875rem;
1140
+ color: hsl(0, 0%, 100%);
1141
+ background-color: rgb(204, 51, 76.5);
1142
+ border-radius: 4px;
1143
+ }
1144
+
1145
+ .was-validated :invalid ~ .invalid-feedback,
1146
+ .was-validated :invalid ~ .invalid-tooltip,
1147
+ .is-invalid ~ .invalid-feedback,
1148
+ .is-invalid ~ .invalid-tooltip {
1149
+ display: block;
1150
+ }
1151
+
1152
+ .was-validated .form-control:invalid, .form-control.is-invalid {
1153
+ border-color: hsl(350, 60%, 50%);
1154
+ padding-right: calc(1.5em + 0.75rem);
1155
+ background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='hsl%28350, 60%, 50%%29'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='hsl%28350, 60%, 50%%29' stroke='none'/%3e%3c/svg%3e");
1156
+ background-repeat: no-repeat;
1157
+ background-position: right calc(0.375em + 0.1875rem) center;
1158
+ background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
1159
+ }
1160
+ .was-validated .form-control:invalid:focus, .form-control.is-invalid:focus {
1161
+ border-color: hsl(350, 60%, 50%);
1162
+ box-shadow: 0 0 0 0.25rem rgba(204, 51, 76.5, 0.25);
1163
+ }
1164
+
1165
+ .was-validated textarea.form-control:invalid, textarea.form-control.is-invalid {
1166
+ padding-right: calc(1.5em + 0.75rem);
1167
+ background-position: top calc(0.375em + 0.1875rem) right calc(0.375em + 0.1875rem);
1168
+ }
1169
+
1170
+ .was-validated .form-select:invalid, .form-select.is-invalid {
1171
+ border-color: hsl(350, 60%, 50%);
1172
+ }
1173
+ .was-validated .form-select:invalid:not([multiple]):not([size]), .was-validated .form-select:invalid:not([multiple])[size="1"], .form-select.is-invalid:not([multiple]):not([size]), .form-select.is-invalid:not([multiple])[size="1"] {
1174
+ padding-right: 4.125rem;
1175
+ 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%, 15%%29' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e"), url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='hsl%28350, 60%, 50%%29'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='hsl%28350, 60%, 50%%29' stroke='none'/%3e%3c/svg%3e");
1176
+ background-position: right 0.75rem center, center right 2.25rem;
1177
+ background-size: 16px 12px, calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
1178
+ }
1179
+ .was-validated .form-select:invalid:focus, .form-select.is-invalid:focus {
1180
+ border-color: hsl(350, 60%, 50%);
1181
+ box-shadow: 0 0 0 0.25rem rgba(204, 51, 76.5, 0.25);
1182
+ }
1183
+
1184
+ .was-validated .form-control-color:invalid, .form-control-color.is-invalid {
1185
+ width: calc(3rem + calc(1.5em + 0.75rem));
1186
+ }
1187
+
1188
+ .was-validated .form-check-input:invalid, .form-check-input.is-invalid {
1189
+ border-color: hsl(350, 60%, 50%);
1190
+ }
1191
+ .was-validated .form-check-input:invalid:checked, .form-check-input.is-invalid:checked {
1192
+ background-color: hsl(350, 60%, 50%);
1193
+ }
1194
+ .was-validated .form-check-input:invalid:focus, .form-check-input.is-invalid:focus {
1195
+ box-shadow: 0 0 0 0.25rem rgba(204, 51, 76.5, 0.25);
1196
+ }
1197
+ .was-validated .form-check-input:invalid ~ .form-check-label, .form-check-input.is-invalid ~ .form-check-label {
1198
+ color: hsl(350, 60%, 50%);
1199
+ }
1200
+
1201
+ .form-check-inline .form-check-input ~ .invalid-feedback {
1202
+ margin-left: 0.5em;
1203
+ }
1204
+
1205
+ .was-validated .input-group > .form-control:not(:focus):invalid, .input-group > .form-control:not(:focus).is-invalid,
1206
+ .was-validated .input-group > .form-select:not(:focus):invalid,
1207
+ .input-group > .form-select:not(:focus).is-invalid,
1208
+ .was-validated .input-group > .form-floating:not(:focus-within):invalid,
1209
+ .input-group > .form-floating:not(:focus-within).is-invalid {
1210
+ z-index: 4;
1211
+ }
1212
+
1213
+ body {
1214
+ font-family: var(--bsi-font-sans);
1215
+ }
1216
+
1217
+ p,
1218
+ ul,
1219
+ ol,
1220
+ dl {
1221
+ font-size: var(--bsi-body-font-size);
1222
+ line-height: var(--bsi-body-leading);
1223
+ }
1224
+
1225
+ caption,
1226
+ figcaption {
1227
+ font-size: var(--bsi-caption-font-size);
1228
+ line-height: var(--bsi-caption-leading);
1229
+ }
1230
+
1231
+ b,
1232
+ strong {
1233
+ font-weight: var(--bsi-font-weight-strong);
1234
+ }
1235
+
1236
+ mark,
1237
+ code {
1238
+ padding: 0 var(--bsi-spacing-3xs);
1239
+ }
1240
+
1241
+ mark {
1242
+ background-color: var(--bsi-highlight-background);
1243
+ }
1244
+
1245
+ pre,
1246
+ code,
1247
+ kbd,
1248
+ samp {
1249
+ border-radius: var(--bsi-radius-smooth);
1250
+ font-family: var(--bsi-font-mono);
1251
+ }
1252
+
1253
+ ins,
1254
+ del {
1255
+ position: relative;
1256
+ display: flex;
1257
+ align-items: center;
1258
+ padding: var(--bsi-spacing-3xs) var(--bsi-spacing-m);
1259
+ font: var(--bsi-body-font-size);
1260
+ text-decoration: none;
1261
+ }
1262
+
1263
+ ins {
1264
+ background-color: var(--bsi-ins-background);
1265
+ text-decoration: none;
1266
+ }
1267
+
1268
+ del {
1269
+ background-color: var(--bsi-del-background);
1270
+ }
1271
+
1272
+ del::before,
1273
+ ins::before {
1274
+ position: absolute;
1275
+ left: 0.5rem;
1276
+ }
1277
+
1278
+ del::before {
1279
+ content: "−";
1280
+ }
1281
+
1282
+ ins::before {
1283
+ content: "+";
1284
+ }
1285
+
1286
+ kbd {
1287
+ margin: 0 2px;
1288
+ padding: 2px var(--bsi-spacing-3xs);
1289
+ border: var(--bsi-border-base) solid var(--bsi-color-border-subtle);
1290
+ background-color: var(--bsi-color-background-secondary-lighter);
1291
+ box-shadow: var(--bsi-elevation-low), 0 2px 0 0 hsla(255, 0%, 100%, 0.7) inset;
1292
+ color: var(--bsi-color-text-secondary);
1293
+ font-size: var(--bsi-font-size-1);
1294
+ font-weight: var(--bsi-font-weight-solid);
1295
+ white-space: nowrap;
1296
+ }
1297
+ kbd kbd {
1298
+ padding: 0;
1299
+ font-size: var(--bsi-code-font-size);
1300
+ }
1301
+
1302
+ small,
1303
+ .small {
1304
+ font-size: var(--bsi-caption-font-size);
1305
+ }
1306
+
1307
+ .x-small {
1308
+ font-size: var(--bsi-font-size-1);
1309
+ }
1310
+
1311
+ h1,
1312
+ .h1 {
1313
+ font-size: var(--bsi-heading-1-font-size);
1314
+ }
1315
+
1316
+ h2,
1317
+ .h2 {
1318
+ font-size: var(--bsi-heading-2-font-size);
1319
+ }
1320
+
1321
+ h3,
1322
+ .h3 {
1323
+ font-size: var(--bsi-heading-3-font-size);
1324
+ }
1325
+
1326
+ h4,
1327
+ .h4 {
1328
+ font-size: var(--bsi-heading-4-font-size);
1329
+ }
1330
+
1331
+ h5,
1332
+ .h5 {
1333
+ font-size: var(--bsi-heading-5-font-size);
1334
+ }
1335
+
1336
+ h6,
1337
+ .h6 {
1338
+ font-size: var(--bsi-heading-6-font-size);
1339
+ }
1340
+
1341
+ h1,
1342
+ .h1,
1343
+ h2,
1344
+ .h2,
1345
+ h3,
1346
+ .h3,
1347
+ h4,
1348
+ .h4,
1349
+ h5,
1350
+ .h5,
1351
+ h6,
1352
+ .h6 {
1353
+ margin-top: 0;
1354
+ margin-bottom: var(--bsi-heading-spacing);
1355
+ line-height: var(--bsi-heading-leading);
1356
+ }
1357
+ :is(h1, .h1, h2, .h2, h3, .h3, h4, .h4, h5, .h5, h6, .h6) + h1, p + h1,
1358
+ :is(h1, .h1, h2, .h2, h3, .h3, h4, .h4, h5, .h5, h6, .h6) + .h1,
1359
+ p + .h1,
1360
+ :is(h1, .h1, h2, .h2, h3, .h3, h4, .h4, h5, .h5, h6, .h6) + h2,
1361
+ p + h2,
1362
+ :is(h1, .h1, h2, .h2, h3, .h3, h4, .h4, h5, .h5, h6, .h6) + .h2,
1363
+ p + .h2,
1364
+ :is(h1, .h1, h2, .h2, h3, .h3, h4, .h4, h5, .h5, h6, .h6) + h3,
1365
+ p + h3,
1366
+ :is(h1, .h1, h2, .h2, h3, .h3, h4, .h4, h5, .h5, h6, .h6) + .h3,
1367
+ p + .h3,
1368
+ :is(h1, .h1, h2, .h2, h3, .h3, h4, .h4, h5, .h5, h6, .h6) + h4,
1369
+ p + h4,
1370
+ :is(h1, .h1, h2, .h2, h3, .h3, h4, .h4, h5, .h5, h6, .h6) + .h4,
1371
+ p + .h4,
1372
+ :is(h1, .h1, h2, .h2, h3, .h3, h4, .h4, h5, .h5, h6, .h6) + h5,
1373
+ p + h5,
1374
+ :is(h1, .h1, h2, .h2, h3, .h3, h4, .h4, h5, .h5, h6, .h6) + .h5,
1375
+ p + .h5,
1376
+ :is(h1, .h1, h2, .h2, h3, .h3, h4, .h4, h5, .h5, h6, .h6) + h6,
1377
+ p + h6,
1378
+ :is(h1, .h1, h2, .h2, h3, .h3, h4, .h4, h5, .h5, h6, .h6) + .h6,
1379
+ p + .h6 {
1380
+ padding-top: var(--bsi-spacing-s);
1381
+ }
1382
+
1383
+ h1,
1384
+ h2,
1385
+ h3,
1386
+ .h1,
1387
+ .h2,
1388
+ .h3 {
1389
+ font-weight: var(--bsi-heading-font-weight);
1390
+ }
1391
+
1392
+ h4,
1393
+ h5,
1394
+ h6,
1395
+ .h4,
1396
+ .h5,
1397
+ .h6 {
1398
+ font-weight: var(--bsi-heading-font-weight-weak);
1399
+ }
1400
+
1401
+ h1,
1402
+ .h1,
1403
+ .display-1 {
1404
+ letter-spacing: -1px;
1405
+ }
1406
+
1407
+ .font-serif {
1408
+ font-family: var(--bsi-font-serif) !important;
1409
+ }
1410
+
1411
+ .font-sans-serif {
1412
+ font-family: var(--bsi-font-sans) !important;
1413
+ }
1414
+
1415
+ .font-monospace {
1416
+ font-family: var(--bsi-font-mono) !important;
1417
+ }
1418
+
1419
+ .display-1 {
1420
+ font-size: var(--bsi-display-font-size);
1421
+ font-weight: var(--bsi-heading-font-weight);
1422
+ line-height: var(--bsi-heading-leading);
1423
+ }
1424
+
1425
+ .lead {
1426
+ font-size: var(--bsi-lead-font-size);
1427
+ font-weight: var(--bsi-lead-font-weight);
1428
+ line-height: var(--bsi-lead-leading);
1429
+ }
1430
+
1431
+ blockquote,
1432
+ .blockquote {
1433
+ margin: var(--bsi-spacing-m) 0;
1434
+ margin-left: var(--bsi-spacin-inline-xs);
1435
+ padding: var(--bsi-spacing-s);
1436
+ border-left: var(--bsi-border-thick) solid var(--bsi-border-color-secondary);
1437
+ font-size: var(--bsi-body-font-size);
1438
+ line-height: var(--bsi-body-leading);
1439
+ }
1440
+ blockquote > :last-child,
1441
+ .blockquote > :last-child {
1442
+ margin-bottom: 0;
1443
+ }
1444
+ blockquote.text-end,
1445
+ .blockquote.text-end {
1446
+ margin-right: var(--bsi-spacin-inline-xs);
1447
+ border-right: var(--bsi-border-thick) solid var(--bsi-border-color-secondary);
1448
+ }
1449
+ blockquote.text-center, blockquote.text-end, blockquote.blockquote-simple,
1450
+ .blockquote.text-center,
1451
+ .blockquote.text-end,
1452
+ .blockquote.blockquote-simple {
1453
+ margin-left: 0;
1454
+ border-right: none;
1455
+ border-left: none;
1456
+ }
1457
+ blockquote.text-center, blockquote.blockquote-simple,
1458
+ .blockquote.text-center,
1459
+ .blockquote.blockquote-simple {
1460
+ padding: 0;
1461
+ }
1462
+ blockquote.blockquote-simple,
1463
+ .blockquote.blockquote-simple {
1464
+ font-style: italic;
1465
+ }
1466
+ blockquote.blockquote-card,
1467
+ .blockquote.blockquote-card {
1468
+ margin-left: 0;
1469
+ padding: var(--bsi-spacing-m);
1470
+ background-color: var(--bsi-color-background-inverse);
1471
+ box-shadow: var(--bsi-elevation-low);
1472
+ }
1473
+ blockquote.blockquote-card .blockquote-footer,
1474
+ .blockquote.blockquote-card .blockquote-footer {
1475
+ font-size: inherit;
1476
+ }
1477
+ blockquote.blockquote-card .blockquote-footer:before,
1478
+ .blockquote.blockquote-card .blockquote-footer:before {
1479
+ content: none;
1480
+ }
1481
+ blockquote.blockquote-card.dark,
1482
+ .blockquote.blockquote-card.dark {
1483
+ border-left: none;
1484
+ background-color: var(--bsi-color-background-primary);
1485
+ color: var(--bsi-color-text-inverse);
1486
+ }
1487
+ blockquote.blockquote-card.dark .blockquote-footer,
1488
+ .blockquote.blockquote-card.dark .blockquote-footer {
1489
+ color: var(--bsi-color-text-inverse);
1490
+ }
1491
+
1492
+ .blockquote-footer {
1493
+ margin-top: 0;
1494
+ margin-bottom: var(--bsi-spacing-s);
1495
+ color: var(--bsi-color-text-secondary);
1496
+ font-size: var(--bsi-label-font-size);
1497
+ }
1498
+ .blockquote-footer::before {
1499
+ content: "— ";
1500
+ }
1501
+ .bg-dark .blockquote-footer {
1502
+ color: var(--bsi-color-text-muted);
1503
+ }
1504
+
1505
+ .initialism {
1506
+ font-size: var(--bsi-label-font-size-s);
1507
+ text-transform: uppercase;
1508
+ }
1509
+
1510
+ .form-feedback {
1511
+ width: 100%;
1512
+ margin-top: 0.25rem;
1513
+ font-size: 0.75rem;
1514
+ }
1515
+ .form-feedback.just-validate-error-label {
1516
+ color: var(--bsi-color-text-danger);
1517
+ }
1518
+
1519
+ .input-group-text:has(~ [data-focus-mouse=true]:not(.btn)),
1520
+ [data-focus-mouse=true]:not(.btn) ~ .input-group-text,
1521
+ button:has(~ [data-focus-mouse=true]:not(.btn)),
1522
+ [data-focus-mouse=true]:not(.btn) + button {
1523
+ border-color: inherit !important;
1524
+ box-shadow: none !important;
1525
+ outline: none !important;
1526
+ }
1527
+
1528
+ .input-group-text:has(~ .is-invalid),
1529
+ .is-invalid ~ .input-group-text,
1530
+ button:has(~ .is-invalid),
1531
+ .is-invalid + button {
1532
+ border-color: var(--bsi-color-border-danger) !important;
1533
+ }
1534
+
1535
+ .sr-only-justvalidate-bi {
1536
+ display: none;
1537
+ }
1538
+
1539
+ .just-validate-success-field {
1540
+ border-color: var(--bsi-color-border-success) !important;
1541
+ padding-right: calc(1.5em + 0.75rem) !important;
1542
+ background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23008055' viewBox='0 0 192 512'%3E%3Cpath d='M435.848 83.466L172.804 346.51l-96.652-96.652c-4.686-4.686-12.284-4.686-16.971 0l-28.284 28.284c-4.686 4.686-4.686 12.284 0 16.971l133.421 133.421c4.686 4.686 12.284 4.686 16.971 0l299.813-299.813c4.686-4.686 4.686-12.284 0-16.971l-28.284-28.284c-4.686-4.686-12.284-4.686-16.97 0z'/%3E%3C/svg%3E");
1543
+ }
1544
+
1545
+ .input-group-text:has(~ .just-validate-success-field),
1546
+ .just-validate-success-field ~ .input-group-text,
1547
+ button:has(~ .just-validate-success-field),
1548
+ .just-validate-success-field + button {
1549
+ border-color: var(--bsi-color-border-success);
1550
+ }
1551
+
1552
+ .just-validate-success-field + .input-group-text.align-buttons,
1553
+ .is-invalid + .input-group-text.align-buttons {
1554
+ right: 30px;
1555
+ }
1556
+
1557
+ .is-invalid + .input-group-text.align-buttons {
1558
+ bottom: 22px;
1559
+ }
1560
+
1561
+ .autocomplete__wrapper .form-feedback.just-validate-error-label {
1562
+ position: absolute;
1563
+ }
1564
+
1565
+ textarea.form-control {
1566
+ background-position: top 0.3em right 0.3em !important;
1567
+ background-size: 37px 30% !important;
1568
+ }
1569
+ textarea.is-invalid {
1570
+ border-bottom-style: solid;
1571
+ border-bottom-width: 1px;
1572
+ }
1573
+ textarea.just-validate-success-field {
1574
+ border-bottom-style: solid;
1575
+ border-bottom-width: 1px;
1576
+ }
1577
+
1578
+ input[type=checkbox].is-invalid,
1579
+ input[type=radio].is-invalid {
1580
+ --bsi-form-checkbox-border-color: var(--bsi-color-border-danger);
1581
+ }
1582
+
1583
+ select.is-invalid {
1584
+ border: 1px solid var(--bsi-color-border-danger);
1585
+ }
1586
+ select.just-validate-success-field {
1587
+ border: 1px solid var(--bsi-color-border-success);
1588
+ }
1589
+
1590
+ :host {
1591
+ position: relative;
1592
+ display: inline-block;
1593
+ }
1594
+
1595
+ .it-form__control {
1596
+ display: none;
1597
+ }
1598
+
1599
+ input.upload-avatar {
1600
+ position: absolute;
1601
+ z-index: 1;
1602
+ top: 0;
1603
+ left: 0;
1604
+ width: 100%;
1605
+ height: 100%;
1606
+ cursor: pointer;
1607
+ opacity: 0;
1608
+ }
1609
+ @media (min-width: 1200px) {
1610
+ input.upload-avatar {
1611
+ width: 0.1px;
1612
+ height: 0.1px;
1613
+ }
1614
+ }
1615
+
1616
+ .avatar-upload-wrapper {
1617
+ position: relative;
1618
+ display: inline-block;
1619
+ }
1620
+ @media (min-width: 1200px) {
1621
+ .avatar-upload-wrapper {
1622
+ overflow: hidden;
1623
+ }
1624
+ }
1625
+ .avatar-upload-wrapper {
1626
+ border-radius: 50%;
1627
+ cursor: default;
1628
+ line-height: 0;
1629
+ }
1630
+ .avatar-upload-wrapper .avatar-upload-icon {
1631
+ z-index: 10;
1632
+ right: 0;
1633
+ bottom: 0px;
1634
+ display: flex;
1635
+ width: 32px;
1636
+ height: 32px;
1637
+ align-items: center;
1638
+ justify-content: center;
1639
+ isolation: isolate;
1640
+ }
1641
+
1642
+ .it-upload-avatar-label-container {
1643
+ display: flex;
1644
+ flex-direction: column;
1645
+ gap: 8px;
1646
+ }
1647
+ .it-upload-avatar-label-container .it-upload-avatar-label {
1648
+ font-weight: var(--bsi-font-weight-solid, 600);
1649
+ }
1650
+
1651
+ :host([size=xl]) .it-upload-avatar-label {
1652
+ display: none !important;
1653
+ }
1654
+ :host([size=xl]) .avatar-upload-wrapper .avatar-upload-icon {
1655
+ width: 24px;
1656
+ height: 24px;
1657
+ }
1658
+
1659
+ .upload-avatar-container .upload-avatar[type=file] + label it-icon {
1660
+ display: none;
1661
+ }
1662
+
1663
+ .invalid-feedback:not([hidden]) {
1664
+ display: block;
1665
+ }
1666
+
1667
+ .avatar-upload-wrapper:focus-within:not(:hover) {
1668
+ box-shadow: 0 0 0 2px hsl(0, 0%, 100%), 0 0 0 5px hsl(0, 0%, 0%) !important;
1669
+ outline: 3px solid rgba(0, 0, 0, 0) !important;
1670
+ outline-offset: 3px !important;
1671
+ }
1672
+
1673
+ @media (min-width: 1200px) {
1674
+ .upload-avatar:focus-visible + label {
1675
+ box-shadow: 0 0 0 2px hsl(0, 0%, 100%) !important;
1676
+ outline: none !important;
1677
+ }
1678
+ .upload-avatar-container .upload-avatar[type=file] + label {
1679
+ padding-top: calc(var(--bsi-spacing-xxs, 8px) / 2);
1680
+ }
1681
+ :host([size=xl]) .upload-avatar-container .upload-avatar[type=file] + label {
1682
+ padding-top: 6px;
1683
+ }
1684
+ .avatar-upload-wrapper .upload-avatar-container {
1685
+ top: auto;
1686
+ right: 0;
1687
+ bottom: -10%;
1688
+ left: 0;
1689
+ width: 100%;
1690
+ height: 60%;
1691
+ background-color: var(--bsi-overlay-background-primary-muted);
1692
+ cursor: pointer;
1693
+ opacity: 0;
1694
+ transition: opacity 0.15s;
1695
+ }
1696
+ .avatar-upload-wrapper .upload-avatar-container .upload-avatar[type=file] + label it-icon {
1697
+ display: block;
1698
+ }
1699
+ .avatar-upload-wrapper .avatar-upload-icon {
1700
+ display: none !important;
1701
+ }
1702
+ .avatar-upload-wrapper:hover .upload-avatar-container,
1703
+ .avatar-upload-wrapper:focus-within .upload-avatar-container {
1704
+ z-index: 5;
1705
+ opacity: 1;
1706
+ transition: opacity 0.25s;
1707
+ }
1708
+ }`;
1709
+
1710
+ registerTranslation(translation);
1711
+ registerTranslation(translation$1);
1712
+ let ItUploadAvatar = class ItUploadAvatar extends FormControl {
1713
+ constructor() {
1714
+ super(...arguments);
1715
+ // Override the base FormControlController.
1716
+ // Value is the selected File, or falls back to the current src (pre-filled image satisfies required).
1717
+ this.formControlController = new FormControlController(this, {
1718
+ value: (el) => el._currentFile ?? (el._currentSrc || null),
1719
+ assumeInteractionOn: ['it-change'],
1720
+ });
1721
+ /** Current image source URL displayed in the avatar */
1722
+ this.src = '';
1723
+ /** Alt text for the current avatar image */
1724
+ this.alt = '';
1725
+ /** Size of the avatar. Accepts any BSI avatar size token. */
1726
+ this.size = 'xxl';
1727
+ /** Accepted file types, e.g. "image/*" */
1728
+ this.accept = 'image/*';
1729
+ /** If true, the upload button is disabled */
1730
+ this.disabled = false;
1731
+ this._currentSrc = '';
1732
+ /** The currently selected File (null until a new file is chosen). */
1733
+ this._currentFile = null;
1734
+ }
1735
+ connectedCallback() {
1736
+ super.connectedCallback?.();
1737
+ this._currentSrc = this.src;
1738
+ }
1739
+ willUpdate(changedProperties) {
1740
+ super.willUpdate?.(changedProperties);
1741
+ if (changedProperties.has('src') && !this._currentSrc) {
1742
+ this._currentSrc = this.src;
1743
+ }
1744
+ }
1745
+ updated(changedProperties) {
1746
+ super.updated?.(changedProperties);
1747
+ // Re-evaluate validity whenever the form value changes.
1748
+ if (changedProperties.has('_currentFile') || changedProperties.has('_currentSrc')) {
1749
+ this.handleValidationMessages();
1750
+ }
1751
+ }
1752
+ _handleFileChange(e) {
1753
+ const input = e.target;
1754
+ const file = input.files?.[0];
1755
+ if (!file)
1756
+ return;
1757
+ this._currentFile = file;
1758
+ const reader = new FileReader();
1759
+ reader.onload = (event) => {
1760
+ this._currentSrc = event.target?.result;
1761
+ this.requestUpdate();
1762
+ };
1763
+ reader.readAsDataURL(file);
1764
+ // Reset the native input
1765
+ input.value = '';
1766
+ this.dispatchEvent(new CustomEvent('it-change', {
1767
+ detail: { file, name: this.name, id: this.id },
1768
+ bubbles: true,
1769
+ composed: true,
1770
+ }));
1771
+ }
1772
+ // Forward wrapper clicks to the hidden file input.
1773
+ // If the click already originated from the label (which has a `for` association), skip to
1774
+ render() {
1775
+ const labelText = this.$t('upload_avatar_label');
1776
+ const overlayText = this.overlayLabel ?? this.$t('upload_avatar_overlay_label');
1777
+ const proxyValue = this._currentSrc || this._currentFile?.name || '';
1778
+ const isInvalid = this.formControlController.submittedOnce && this.validationMessage.length > 0;
1779
+ return html `
1780
+ <div class="avatar-upload-wrapper size-${this.size}">
1781
+ <it-avatar
1782
+ type="image"
1783
+ size="${this.size}"
1784
+ src="${ifDefined(this._currentSrc || undefined)}"
1785
+ alt="${this.alt}"
1786
+ class="avatar-upload"
1787
+ ></it-avatar>
1788
+
1789
+ <div class="upload-avatar-container">
1790
+ <input
1791
+ type="file"
1792
+ class="upload-avatar"
1793
+ id="${this._id}"
1794
+ accept="${this.accept}"
1795
+ ?disabled="${this.disabled}"
1796
+ aria-label="${labelText}"
1797
+ @change="${this._handleFileChange}"
1798
+ />
1799
+ <label part="overlay-label" for="${this._id}" class="it-upload-avatar-label-container" aria-hidden="true">
1800
+ <it-icon name="it-camera" size="sm" color="inverse" aria-hidden="true"></it-icon>
1801
+ <span class="it-upload-avatar-label">${overlayText}</span>
1802
+ </label>
1803
+ </div>
1804
+
1805
+ <div class="avatar-upload-icon" aria-hidden="true">
1806
+ <it-icon name="it-camera" size="${this.size === 'xl' ? 'xs' : 'sm'}"></it-icon>
1807
+ </div>
1808
+ </div>
1809
+
1810
+ <!-- Hidden proxy input: drives native required/validity checking via FormControl base class -->
1811
+ <input
1812
+ type="text"
1813
+ class="it-form__control"
1814
+ .value="${proxyValue}"
1815
+ ?required="${this.required}"
1816
+ tabindex="-1"
1817
+ aria-hidden="true"
1818
+ />
1819
+
1820
+ <div
1821
+ class="invalid-feedback form-feedback form-text just-validate-error-label"
1822
+ role="alert"
1823
+ ?hidden=${!isInvalid}
1824
+ >
1825
+ ${isInvalid ? this.validationMessage : nothing}
1826
+ </div>
1827
+ `;
1828
+ }
1829
+ };
1830
+ ItUploadAvatar.styles = styles;
1831
+ ItUploadAvatar.shadowRootOptions = {
1832
+ ...FormControl.shadowRootOptions,
1833
+ delegatesFocus: true,
1834
+ };
1835
+ __decorate([
1836
+ query('.it-form__control'),
1837
+ __metadata("design:type", HTMLInputElement)
1838
+ ], ItUploadAvatar.prototype, "inputElement", void 0);
1839
+ __decorate([
1840
+ property({ type: String, reflect: true }),
1841
+ __metadata("design:type", Object)
1842
+ ], ItUploadAvatar.prototype, "src", void 0);
1843
+ __decorate([
1844
+ property({ type: String, reflect: true }),
1845
+ __metadata("design:type", Object)
1846
+ ], ItUploadAvatar.prototype, "alt", void 0);
1847
+ __decorate([
1848
+ property({ type: String, reflect: true }),
1849
+ __metadata("design:type", String)
1850
+ ], ItUploadAvatar.prototype, "size", void 0);
1851
+ __decorate([
1852
+ property({ type: String }),
1853
+ __metadata("design:type", Object)
1854
+ ], ItUploadAvatar.prototype, "accept", void 0);
1855
+ __decorate([
1856
+ property({ type: String, attribute: 'overlay-label' }),
1857
+ __metadata("design:type", String)
1858
+ ], ItUploadAvatar.prototype, "overlayLabel", void 0);
1859
+ __decorate([
1860
+ property({ type: Boolean, reflect: true }),
1861
+ __metadata("design:type", Object)
1862
+ ], ItUploadAvatar.prototype, "disabled", void 0);
1863
+ __decorate([
1864
+ state(),
1865
+ __metadata("design:type", Object)
1866
+ ], ItUploadAvatar.prototype, "_currentSrc", void 0);
1867
+ __decorate([
1868
+ state(),
1869
+ __metadata("design:type", Object)
1870
+ ], ItUploadAvatar.prototype, "_currentFile", void 0);
1871
+ ItUploadAvatar = __decorate([
1872
+ customElement('it-upload-avatar')
1873
+ ], ItUploadAvatar);
1874
+
1875
+ export { ItUploadAvatar };
1876
+ //# sourceMappingURL=it-upload-avatar.js.map