@norges-domstoler/dds-components 21.17.2 → 21.18.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.css +16 -0
- package/dist/index.css.map +1 -1
- package/dist/index.d.mts +49 -19
- package/dist/index.d.ts +49 -19
- package/dist/index.js +685 -456
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +671 -452
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -160,6 +160,16 @@ __export(index_exports, {
|
|
|
160
160
|
FooterLogo: () => FooterLogo,
|
|
161
161
|
FooterSocialsGroup: () => FooterSocialsGroup,
|
|
162
162
|
FooterSocialsList: () => FooterSocialsList,
|
|
163
|
+
FormSummary: () => FormSummary,
|
|
164
|
+
FormSummaryEditButton: () => FormSummaryEditButton,
|
|
165
|
+
FormSummaryEmptyValue: () => FormSummaryEmptyValue,
|
|
166
|
+
FormSummaryError: () => FormSummaryError,
|
|
167
|
+
FormSummaryField: () => FormSummaryField,
|
|
168
|
+
FormSummaryFields: () => FormSummaryFields,
|
|
169
|
+
FormSummaryHeader: () => FormSummaryHeader,
|
|
170
|
+
FormSummaryHeading: () => FormSummaryHeading,
|
|
171
|
+
FormSummaryLabel: () => FormSummaryLabel,
|
|
172
|
+
FormSummaryValue: () => FormSummaryValue,
|
|
163
173
|
FullscreenExitIcon: () => FullscreenExitIcon,
|
|
164
174
|
FullscreenIcon: () => FullscreenIcon,
|
|
165
175
|
GavelIcon: () => GavelIcon,
|
|
@@ -619,7 +629,8 @@ var combineHandlers = (handler1, handler2) => {
|
|
|
619
629
|
|
|
620
630
|
// src/utils/dom.ts
|
|
621
631
|
function cn(...classNames) {
|
|
622
|
-
|
|
632
|
+
const filtered = classNames.filter(Boolean).join(" ");
|
|
633
|
+
return filtered || void 0;
|
|
623
634
|
}
|
|
624
635
|
function convertCamelToHyphen(value) {
|
|
625
636
|
return value.replace(/([a-z])([A-Z])/g, "$1-$2").replace(/([a-z])([0-9])/g, "$1-$2").toLowerCase();
|
|
@@ -3275,8 +3286,8 @@ function useTranslation() {
|
|
|
3275
3286
|
const t = (text) => text[lang];
|
|
3276
3287
|
return { t, lang };
|
|
3277
3288
|
}
|
|
3278
|
-
function createTexts(
|
|
3279
|
-
return
|
|
3289
|
+
function createTexts(texts30) {
|
|
3290
|
+
return texts30;
|
|
3280
3291
|
}
|
|
3281
3292
|
|
|
3282
3293
|
// src/DdsProvider/DdsProvider.tsx
|
|
@@ -4056,7 +4067,8 @@ var texts = createTexts({
|
|
|
4056
4067
|
nb: "G\xE5 tilbake",
|
|
4057
4068
|
no: "G\xE5 tilbake",
|
|
4058
4069
|
nn: "G\xE5 tilbake",
|
|
4059
|
-
en: "Go back"
|
|
4070
|
+
en: "Go back",
|
|
4071
|
+
se: "Mana ruovttoluotta"
|
|
4060
4072
|
}
|
|
4061
4073
|
});
|
|
4062
4074
|
|
|
@@ -4127,25 +4139,29 @@ var commonTexts = createTexts({
|
|
|
4127
4139
|
no: "T\xF8m nedtrekksliste",
|
|
4128
4140
|
nb: "T\xF8m nedtrekksliste",
|
|
4129
4141
|
nn: "T\xF8m nedtrekksliste",
|
|
4130
|
-
en: "Clear selection"
|
|
4142
|
+
en: "Clear selection",
|
|
4143
|
+
se: "Gidde v\xE1lljemiid"
|
|
4131
4144
|
},
|
|
4132
4145
|
close: {
|
|
4133
4146
|
nb: "Lukk",
|
|
4134
4147
|
no: "Lukk",
|
|
4135
4148
|
nn: "Lukk",
|
|
4136
|
-
en: "Close"
|
|
4149
|
+
en: "Close",
|
|
4150
|
+
se: "Gidde"
|
|
4137
4151
|
},
|
|
4138
4152
|
closeMessage: {
|
|
4139
4153
|
nb: "Lukk melding",
|
|
4140
4154
|
no: "Lukk melding",
|
|
4141
4155
|
nn: "Lukk melding",
|
|
4142
|
-
en: "Close message"
|
|
4156
|
+
en: "Close message",
|
|
4157
|
+
se: "Gidde die\u0111u"
|
|
4143
4158
|
},
|
|
4144
4159
|
loading: {
|
|
4145
4160
|
nb: "Innlastning p\xE5g\xE5r",
|
|
4146
4161
|
no: "Innlastning p\xE5g\xE5r",
|
|
4147
4162
|
nn: "Innlastning p\xE5g\xE5r",
|
|
4148
|
-
en: "Loading"
|
|
4163
|
+
en: "Loading",
|
|
4164
|
+
se: "Vie\u017E\u017Eamin"
|
|
4149
4165
|
}
|
|
4150
4166
|
});
|
|
4151
4167
|
|
|
@@ -4231,8 +4247,8 @@ var Button = ({
|
|
|
4231
4247
|
iconPosition = "left",
|
|
4232
4248
|
href,
|
|
4233
4249
|
target,
|
|
4234
|
-
loading
|
|
4235
|
-
loadingTooltip
|
|
4250
|
+
loading,
|
|
4251
|
+
loadingTooltip,
|
|
4236
4252
|
fullWidth = false,
|
|
4237
4253
|
icon,
|
|
4238
4254
|
onClick,
|
|
@@ -4336,7 +4352,8 @@ var texts2 = createTexts({
|
|
|
4336
4352
|
no: "Lagring p\xE5g\xE5r",
|
|
4337
4353
|
nb: "Lagring p\xE5g\xE5r",
|
|
4338
4354
|
nn: "Lagring p\xE5g\xE5r",
|
|
4339
|
-
en: "Saving"
|
|
4355
|
+
en: "Saving",
|
|
4356
|
+
se: "Vurkemin"
|
|
4340
4357
|
}
|
|
4341
4358
|
});
|
|
4342
4359
|
|
|
@@ -4849,19 +4866,22 @@ var texts3 = createTexts({
|
|
|
4849
4866
|
nb: "Br\xF8dsmulesti",
|
|
4850
4867
|
no: "Br\xF8dsmulesti",
|
|
4851
4868
|
nn: "Br\xF8dsmulesti",
|
|
4852
|
-
en: "Breadcrumbs"
|
|
4869
|
+
en: "Breadcrumbs",
|
|
4870
|
+
se: "L\xE1ibemoallob\xE1lggis"
|
|
4853
4871
|
},
|
|
4854
4872
|
showHiddenTo: (to) => ({
|
|
4855
4873
|
nb: `Vis br\xF8dsmule 2 til ${to}`,
|
|
4856
4874
|
no: `Vis br\xF8dsmule 2 til ${to}`,
|
|
4857
4875
|
nn: `Vis br\xF8dsmule 2 til ${to}`,
|
|
4858
|
-
en: `Show breadcrumb 2 to ${to}
|
|
4876
|
+
en: `Show breadcrumb 2 to ${to}`,
|
|
4877
|
+
se: `\u010C\xE1jet l\xE1ibemoalu 2 ${to}`
|
|
4859
4878
|
}),
|
|
4860
4879
|
showHidden: {
|
|
4861
4880
|
nb: "Vis br\xF8dsmule 2",
|
|
4862
4881
|
no: "Vis br\xF8dsmule 2",
|
|
4863
4882
|
nn: "Vis br\xF8dsmule 2",
|
|
4864
|
-
en: "Show breadcrumb 2"
|
|
4883
|
+
en: "Show breadcrumb 2",
|
|
4884
|
+
se: "\u010C\xE1jet l\xE1ibemoalu 2"
|
|
4865
4885
|
}
|
|
4866
4886
|
});
|
|
4867
4887
|
|
|
@@ -5336,6 +5356,7 @@ var InputMessage = ({
|
|
|
5336
5356
|
id,
|
|
5337
5357
|
className,
|
|
5338
5358
|
htmlProps,
|
|
5359
|
+
children,
|
|
5339
5360
|
...rest
|
|
5340
5361
|
}) => {
|
|
5341
5362
|
const isError = messageType === "error";
|
|
@@ -5356,7 +5377,7 @@ var InputMessage = ({
|
|
|
5356
5377
|
typographyType: isError ? "bodySmall" : "bodyXsmall",
|
|
5357
5378
|
color: isError ? "textDefault" : "textSubtle",
|
|
5358
5379
|
as: "span",
|
|
5359
|
-
children: message
|
|
5380
|
+
children: message != null ? message : children
|
|
5360
5381
|
}
|
|
5361
5382
|
)
|
|
5362
5383
|
]
|
|
@@ -5840,7 +5861,8 @@ var texts4 = createTexts({
|
|
|
5840
5861
|
nb: "Fjern merkelapp",
|
|
5841
5862
|
no: "Fjern merkelapp",
|
|
5842
5863
|
nn: "Fjern merkelapp",
|
|
5843
|
-
en: "Remove chip"
|
|
5864
|
+
en: "Remove chip",
|
|
5865
|
+
se: "Sihku lihppu"
|
|
5844
5866
|
}
|
|
5845
5867
|
});
|
|
5846
5868
|
|
|
@@ -6001,7 +6023,8 @@ var texts5 = createTexts({
|
|
|
6001
6023
|
nb: "Utvid samtykke for bruk av informasjonskapsler",
|
|
6002
6024
|
no: "Utvid samtykke for bruk av informasjonskapsler",
|
|
6003
6025
|
nn: "Utvid samtykke for bruk av informasjonskapslar",
|
|
6004
|
-
en: "Expand consent for the use of cookies"
|
|
6026
|
+
en: "Expand consent for the use of cookies",
|
|
6027
|
+
se: "Viiddit mie\u0111\xE1husa diehto\u010Doahkuid geavaheapm\xE1i"
|
|
6005
6028
|
}
|
|
6006
6029
|
});
|
|
6007
6030
|
|
|
@@ -6060,7 +6083,8 @@ var LOCALE = {
|
|
|
6060
6083
|
nb: "nb-NO",
|
|
6061
6084
|
no: "no-NO",
|
|
6062
6085
|
nn: "nn-NO",
|
|
6063
|
-
en: "en-GB"
|
|
6086
|
+
en: "en-GB",
|
|
6087
|
+
se: "se-NO"
|
|
6064
6088
|
};
|
|
6065
6089
|
var timezone = "Europe/Oslo";
|
|
6066
6090
|
|
|
@@ -6383,91 +6407,106 @@ var texts6 = createTexts({
|
|
|
6383
6407
|
nb: "Ukenummer",
|
|
6384
6408
|
no: "Ukenummer",
|
|
6385
6409
|
nn: "Vekenummer",
|
|
6386
|
-
en: "Week number"
|
|
6410
|
+
en: "Week number",
|
|
6411
|
+
se: "Vahkkonummir"
|
|
6387
6412
|
},
|
|
6388
6413
|
mo: {
|
|
6389
6414
|
nb: "Ma",
|
|
6390
6415
|
no: "Ma",
|
|
6391
6416
|
nn: "M\xE5",
|
|
6392
|
-
en: "Mo"
|
|
6417
|
+
en: "Mo",
|
|
6418
|
+
se: "Vuos"
|
|
6393
6419
|
},
|
|
6394
6420
|
tu: {
|
|
6395
6421
|
nb: "Ti",
|
|
6396
6422
|
no: "Ti",
|
|
6397
6423
|
nn: "Ty",
|
|
6398
|
-
en: "Tu"
|
|
6424
|
+
en: "Tu",
|
|
6425
|
+
se: "Ma\u014B"
|
|
6399
6426
|
},
|
|
6400
6427
|
we: {
|
|
6401
6428
|
nb: "On",
|
|
6402
6429
|
no: "On",
|
|
6403
6430
|
nn: "On",
|
|
6404
|
-
en: "We"
|
|
6431
|
+
en: "We",
|
|
6432
|
+
se: "Gask"
|
|
6405
6433
|
},
|
|
6406
6434
|
th: {
|
|
6407
6435
|
nb: "To",
|
|
6408
6436
|
no: "To",
|
|
6409
6437
|
nn: "To",
|
|
6410
|
-
en: "Th"
|
|
6438
|
+
en: "Th",
|
|
6439
|
+
se: "Duo"
|
|
6411
6440
|
},
|
|
6412
6441
|
fr: {
|
|
6413
6442
|
nb: "Fr",
|
|
6414
6443
|
no: "Fr",
|
|
6415
6444
|
nn: "Fr",
|
|
6416
|
-
en: "Fr"
|
|
6445
|
+
en: "Fr",
|
|
6446
|
+
se: "Bea"
|
|
6417
6447
|
},
|
|
6418
6448
|
sa: {
|
|
6419
6449
|
nb: "L\xF8",
|
|
6420
6450
|
no: "L\xF8",
|
|
6421
6451
|
nn: "La",
|
|
6422
|
-
en: "Sa"
|
|
6452
|
+
en: "Sa",
|
|
6453
|
+
se: "L\xE1v"
|
|
6423
6454
|
},
|
|
6424
6455
|
su: {
|
|
6425
6456
|
nb: "S\xF8",
|
|
6426
6457
|
no: "S\xF8",
|
|
6427
6458
|
nn: "Su",
|
|
6428
|
-
en: "Su"
|
|
6459
|
+
en: "Su",
|
|
6460
|
+
se: "Sotn"
|
|
6429
6461
|
},
|
|
6430
6462
|
monday: {
|
|
6431
6463
|
nb: "Mandag",
|
|
6432
6464
|
no: "Mandag",
|
|
6433
6465
|
nn: "M\xE5ndag",
|
|
6434
|
-
en: "Monday"
|
|
6466
|
+
en: "Monday",
|
|
6467
|
+
se: "Vuoss\xE1rga"
|
|
6435
6468
|
},
|
|
6436
6469
|
tuesday: {
|
|
6437
6470
|
nb: "Tirsdag",
|
|
6438
6471
|
no: "Tirsdag",
|
|
6439
6472
|
nn: "Tysdag",
|
|
6440
|
-
en: "Tuesday"
|
|
6473
|
+
en: "Tuesday",
|
|
6474
|
+
se: "Ma\u014B\u014Beb\xE1rga"
|
|
6441
6475
|
},
|
|
6442
6476
|
wednesday: {
|
|
6443
6477
|
nb: "Onsdag",
|
|
6444
6478
|
no: "Onsdag",
|
|
6445
6479
|
nn: "Onsdag",
|
|
6446
|
-
en: "Wednesday"
|
|
6480
|
+
en: "Wednesday",
|
|
6481
|
+
se: "Gaskavahkku"
|
|
6447
6482
|
},
|
|
6448
6483
|
thursday: {
|
|
6449
6484
|
nb: "Torsdag",
|
|
6450
6485
|
no: "Torsdag",
|
|
6451
6486
|
nn: "Torsdag",
|
|
6452
|
-
en: "Thursday"
|
|
6487
|
+
en: "Thursday",
|
|
6488
|
+
se: "Duorastat"
|
|
6453
6489
|
},
|
|
6454
6490
|
friday: {
|
|
6455
6491
|
nb: "Fredag",
|
|
6456
6492
|
no: "Fredag",
|
|
6457
6493
|
nn: "Fredag",
|
|
6458
|
-
en: "Friday"
|
|
6494
|
+
en: "Friday",
|
|
6495
|
+
se: "Bearjadat"
|
|
6459
6496
|
},
|
|
6460
6497
|
saturday: {
|
|
6461
6498
|
nb: "L\xF8rdag",
|
|
6462
6499
|
no: "L\xF8rdag",
|
|
6463
6500
|
nn: "Laurdag",
|
|
6464
|
-
en: "Saturday"
|
|
6501
|
+
en: "Saturday",
|
|
6502
|
+
se: "L\xE1vvardat"
|
|
6465
6503
|
},
|
|
6466
6504
|
sunday: {
|
|
6467
6505
|
nb: "S\xF8ndag",
|
|
6468
6506
|
no: "S\xF8ndag",
|
|
6469
6507
|
nn: "Sundag",
|
|
6470
|
-
en: "Sunday"
|
|
6508
|
+
en: "Sunday",
|
|
6509
|
+
se: "Sotnabeaivi"
|
|
6471
6510
|
}
|
|
6472
6511
|
});
|
|
6473
6512
|
|
|
@@ -6550,26 +6589,28 @@ var texts7 = createTexts({
|
|
|
6550
6589
|
nb: "Neste m\xE5ned",
|
|
6551
6590
|
no: "Neste m\xE5ned",
|
|
6552
6591
|
nn: "Neste m\xE5nad",
|
|
6553
|
-
en: "Next month"
|
|
6592
|
+
en: "Next month",
|
|
6593
|
+
se: "Boahte m\xE1nu"
|
|
6554
6594
|
},
|
|
6555
6595
|
previousMonth: {
|
|
6556
6596
|
nb: "Forrige m\xE5ned",
|
|
6557
6597
|
no: "Forrige m\xE5ned",
|
|
6558
6598
|
nn: "F\xF8rre m\xE5nad",
|
|
6559
|
-
en: "Previous month"
|
|
6599
|
+
en: "Previous month",
|
|
6600
|
+
se: "Ovddit m\xE1nu"
|
|
6560
6601
|
}
|
|
6561
6602
|
});
|
|
6562
6603
|
|
|
6563
6604
|
// src/components/date-inputs/DatePicker/DatePicker.tsx
|
|
6564
6605
|
var import_datepicker4 = require("@react-aria/datepicker");
|
|
6565
|
-
var
|
|
6606
|
+
var import_i18n17 = require("@react-aria/i18n");
|
|
6566
6607
|
var import_datepicker5 = require("@react-stately/datepicker");
|
|
6567
6608
|
var import_react47 = require("react");
|
|
6568
6609
|
|
|
6569
6610
|
// src/components/date-inputs/DatePicker/DateField/DateField.tsx
|
|
6570
6611
|
var import_date5 = require("@internationalized/date");
|
|
6571
6612
|
var import_datepicker2 = require("@react-aria/datepicker");
|
|
6572
|
-
var
|
|
6613
|
+
var import_i18n15 = require("@react-aria/i18n");
|
|
6573
6614
|
var import_datepicker3 = require("@react-stately/datepicker");
|
|
6574
6615
|
var import_react45 = require("react");
|
|
6575
6616
|
|
|
@@ -6629,6 +6670,7 @@ function CalendarButton({
|
|
|
6629
6670
|
|
|
6630
6671
|
// src/components/date-inputs/DatePicker/DateField/DateField.utils.tsx
|
|
6631
6672
|
function formatDateFieldSegments(segments) {
|
|
6673
|
+
const { t } = useTranslation();
|
|
6632
6674
|
const daySegment = segments.find((segment) => segment.type === "day");
|
|
6633
6675
|
const monthSegment = segments.find((segment) => segment.type === "month");
|
|
6634
6676
|
const yearSegment = segments.find((segment) => segment.type === "year");
|
|
@@ -6639,16 +6681,16 @@ function formatDateFieldSegments(segments) {
|
|
|
6639
6681
|
const formattedDaySegment = {
|
|
6640
6682
|
...daySegment,
|
|
6641
6683
|
text: daySegment.text.padStart(2, "0"),
|
|
6642
|
-
placeholder:
|
|
6684
|
+
placeholder: t(texts8.dayPlaceholder)
|
|
6643
6685
|
};
|
|
6644
6686
|
const formattedMonthSegment = {
|
|
6645
6687
|
...monthSegment,
|
|
6646
6688
|
text: monthSegment.text.padStart(2, "0"),
|
|
6647
|
-
placeholder:
|
|
6689
|
+
placeholder: t(texts8.monthPlaceholder)
|
|
6648
6690
|
};
|
|
6649
6691
|
const formattedYearSegment = {
|
|
6650
6692
|
...yearSegment,
|
|
6651
|
-
placeholder:
|
|
6693
|
+
placeholder: t(texts8.yearPlaceholder)
|
|
6652
6694
|
};
|
|
6653
6695
|
const formattedSeparatorSegment = { ...separatorSegment, text: "." };
|
|
6654
6696
|
return [
|
|
@@ -6659,6 +6701,29 @@ function formatDateFieldSegments(segments) {
|
|
|
6659
6701
|
formattedYearSegment
|
|
6660
6702
|
];
|
|
6661
6703
|
}
|
|
6704
|
+
var texts8 = createTexts({
|
|
6705
|
+
dayPlaceholder: {
|
|
6706
|
+
nb: "dd",
|
|
6707
|
+
no: "dd",
|
|
6708
|
+
nn: "dd",
|
|
6709
|
+
en: "dd",
|
|
6710
|
+
se: "jj"
|
|
6711
|
+
},
|
|
6712
|
+
monthPlaceholder: {
|
|
6713
|
+
nb: "mm",
|
|
6714
|
+
no: "mm",
|
|
6715
|
+
nn: "mm",
|
|
6716
|
+
en: "mm",
|
|
6717
|
+
se: "mm"
|
|
6718
|
+
},
|
|
6719
|
+
yearPlaceholder: {
|
|
6720
|
+
nb: "\xE5\xE5\xE5\xE5",
|
|
6721
|
+
no: "\xE5\xE5\xE5\xE5",
|
|
6722
|
+
nn: "\xE5\xE5\xE5\xE5",
|
|
6723
|
+
en: "yyyy",
|
|
6724
|
+
se: "jjjj"
|
|
6725
|
+
}
|
|
6726
|
+
});
|
|
6662
6727
|
|
|
6663
6728
|
// src/components/date-inputs/DatePicker/DateField/DateSegment.tsx
|
|
6664
6729
|
var import_datepicker = require("@react-aria/datepicker");
|
|
@@ -6910,7 +6975,7 @@ function DateField({
|
|
|
6910
6975
|
clearable,
|
|
6911
6976
|
...props
|
|
6912
6977
|
}) {
|
|
6913
|
-
const { locale } = (0,
|
|
6978
|
+
const { locale } = (0, import_i18n15.useLocale)();
|
|
6914
6979
|
const { t } = useTranslation();
|
|
6915
6980
|
const state = (0, import_datepicker3.useDateFieldState)({
|
|
6916
6981
|
...props,
|
|
@@ -6956,7 +7021,7 @@ function DateField({
|
|
|
6956
7021
|
ClearButton,
|
|
6957
7022
|
{
|
|
6958
7023
|
absolute: false,
|
|
6959
|
-
"aria-label": t(
|
|
7024
|
+
"aria-label": t(texts9.clearDate),
|
|
6960
7025
|
"aria-hidden": !hasValue,
|
|
6961
7026
|
className: cn(
|
|
6962
7027
|
DateInput_default["clear-button"],
|
|
@@ -6982,12 +7047,13 @@ function DateField({
|
|
|
6982
7047
|
);
|
|
6983
7048
|
}
|
|
6984
7049
|
DateField.displayName = "DateField";
|
|
6985
|
-
var
|
|
7050
|
+
var texts9 = createTexts({
|
|
6986
7051
|
clearDate: {
|
|
6987
7052
|
en: "Clear date",
|
|
6988
7053
|
nb: "T\xF8m dato",
|
|
6989
7054
|
no: "T\xF8m dato",
|
|
6990
|
-
nn: "T\xF8m dato"
|
|
7055
|
+
nn: "T\xF8m dato",
|
|
7056
|
+
se: "Gurre d\xE1htona"
|
|
6991
7057
|
}
|
|
6992
7058
|
});
|
|
6993
7059
|
|
|
@@ -7042,7 +7108,7 @@ function DatePicker({
|
|
|
7042
7108
|
state,
|
|
7043
7109
|
internalRef
|
|
7044
7110
|
);
|
|
7045
|
-
return /* @__PURE__ */ (0, import_jsx_runtime237.jsx)(
|
|
7111
|
+
return /* @__PURE__ */ (0, import_jsx_runtime237.jsx)(import_i18n17.I18nProvider, { locale: LOCALE[lang], children: /* @__PURE__ */ (0, import_jsx_runtime237.jsxs)(
|
|
7046
7112
|
CalendarPopover,
|
|
7047
7113
|
{
|
|
7048
7114
|
isOpen: state.isOpen,
|
|
@@ -7698,7 +7764,7 @@ var FavStar = ({
|
|
|
7698
7764
|
checked,
|
|
7699
7765
|
onChange: (e) => setChecked(e.target.checked),
|
|
7700
7766
|
type: "checkbox",
|
|
7701
|
-
"aria-label": (_a = props["aria-label"]) != null ? _a : t(
|
|
7767
|
+
"aria-label": (_a = props["aria-label"]) != null ? _a : t(texts10.favourite)
|
|
7702
7768
|
}
|
|
7703
7769
|
),
|
|
7704
7770
|
/* @__PURE__ */ (0, import_jsx_runtime250.jsx)(Icon, { iconSize: size2, icon: StarIcon, className: FavStar_default.icon }),
|
|
@@ -7715,12 +7781,13 @@ var FavStar = ({
|
|
|
7715
7781
|
);
|
|
7716
7782
|
};
|
|
7717
7783
|
FavStar.displayName = "FavStar";
|
|
7718
|
-
var
|
|
7784
|
+
var texts10 = createTexts({
|
|
7719
7785
|
favourite: {
|
|
7720
7786
|
nb: "Stjernemarker",
|
|
7721
7787
|
no: "Stjernemarker",
|
|
7722
7788
|
nn: "Stjernemerk",
|
|
7723
|
-
en: "Mark as favourite"
|
|
7789
|
+
en: "Mark as favourite",
|
|
7790
|
+
se: "Merke favorihta"
|
|
7724
7791
|
}
|
|
7725
7792
|
});
|
|
7726
7793
|
|
|
@@ -7775,7 +7842,7 @@ function CharCounter(props) {
|
|
|
7775
7842
|
"/",
|
|
7776
7843
|
max
|
|
7777
7844
|
] }),
|
|
7778
|
-
/* @__PURE__ */ (0, import_jsx_runtime251.jsx)(VisuallyHidden, { children: t(
|
|
7845
|
+
/* @__PURE__ */ (0, import_jsx_runtime251.jsx)(VisuallyHidden, { children: t(texts11.charsWritten(current, max, max - current)) })
|
|
7779
7846
|
]
|
|
7780
7847
|
}
|
|
7781
7848
|
);
|
|
@@ -7784,12 +7851,13 @@ var renderCharCounter = (id, isShown, textLength, maxLength) => {
|
|
|
7784
7851
|
if (!!maxLength && Number.isInteger(maxLength) && maxLength > 0 && isShown)
|
|
7785
7852
|
return /* @__PURE__ */ (0, import_jsx_runtime251.jsx)(CharCounter, { id, max: maxLength, current: textLength });
|
|
7786
7853
|
};
|
|
7787
|
-
var
|
|
7854
|
+
var texts11 = createTexts({
|
|
7788
7855
|
charsWritten: (current, max, remain) => ({
|
|
7789
7856
|
nb: `${current} av ${max} tegn skrevet. ${remain} igjen.`,
|
|
7790
7857
|
no: `${current} av ${max} tegn skrevet. ${remain} igjen.`,
|
|
7791
7858
|
nn: `${current} av ${max} teikn skrivne. ${remain} att.`,
|
|
7792
|
-
en: `${current} of ${max} characters used. ${remain} remaining
|
|
7859
|
+
en: `${current} of ${max} characters used. ${remain} remaining.`,
|
|
7860
|
+
se: `${current} ${max} mearkabust\xE1va leat ${max} \u010D\xE1llon ${remain}.`
|
|
7793
7861
|
})
|
|
7794
7862
|
});
|
|
7795
7863
|
|
|
@@ -7948,17 +8016,18 @@ var CommentComponent = ({
|
|
|
7948
8016
|
size: "small",
|
|
7949
8017
|
onClick: handleSubmit,
|
|
7950
8018
|
loading,
|
|
7951
|
-
children: t(
|
|
8019
|
+
children: t(texts12.send)
|
|
7952
8020
|
}
|
|
7953
8021
|
)
|
|
7954
8022
|
] });
|
|
7955
8023
|
};
|
|
7956
|
-
var
|
|
8024
|
+
var texts12 = createTexts({
|
|
7957
8025
|
send: {
|
|
7958
8026
|
nb: "Send inn",
|
|
7959
8027
|
no: "Send inn",
|
|
7960
8028
|
nn: "Send inn",
|
|
7961
|
-
en: "Send"
|
|
8029
|
+
en: "Send",
|
|
8030
|
+
se: "S\xE1dde"
|
|
7962
8031
|
}
|
|
7963
8032
|
});
|
|
7964
8033
|
|
|
@@ -8154,7 +8223,7 @@ var RatingComponent = ({
|
|
|
8154
8223
|
),
|
|
8155
8224
|
children: [
|
|
8156
8225
|
/* @__PURE__ */ (0, import_jsx_runtime255.jsx)("h2", { className: typographyStyles_default["label-medium"], children: ratingLabel }),
|
|
8157
|
-
loading ? /* @__PURE__ */ (0, import_jsx_runtime255.jsx)(Spinner, { tooltip: t(
|
|
8226
|
+
loading ? /* @__PURE__ */ (0, import_jsx_runtime255.jsx)(Spinner, { tooltip: t(texts13.uploadingFeedback) }) : /* @__PURE__ */ (0, import_jsx_runtime255.jsxs)(HStack, { gap: "x1", children: [
|
|
8158
8227
|
/* @__PURE__ */ (0, import_jsx_runtime255.jsx)(Tooltip, { text: thumbUpTooltip, children: button("positive", layout, thumbUpTooltip) }),
|
|
8159
8228
|
/* @__PURE__ */ (0, import_jsx_runtime255.jsx)(Tooltip, { text: thumbDownTooltip, children: /* @__PURE__ */ (0, import_jsx_runtime255.jsx)("div", { children: button("negative", layout, thumbDownTooltip) }) })
|
|
8160
8229
|
] })
|
|
@@ -8162,12 +8231,13 @@ var RatingComponent = ({
|
|
|
8162
8231
|
}
|
|
8163
8232
|
);
|
|
8164
8233
|
};
|
|
8165
|
-
var
|
|
8234
|
+
var texts13 = createTexts({
|
|
8166
8235
|
uploadingFeedback: {
|
|
8167
8236
|
nb: "Laster opp tilbakemelding...",
|
|
8168
8237
|
no: "Laster opp tilbakemelding...",
|
|
8169
8238
|
nn: "Lastar opp tilbakemelding...",
|
|
8170
|
-
en: "Uploading feedback..."
|
|
8239
|
+
en: "Uploading feedback...",
|
|
8240
|
+
se: "Vie\u017E\u017Eamin ruovttoluottadie\u0111uid..."
|
|
8171
8241
|
}
|
|
8172
8242
|
});
|
|
8173
8243
|
|
|
@@ -8196,14 +8266,14 @@ var Feedback = ({
|
|
|
8196
8266
|
const [rating, setRating] = (0, import_react57.useState)(null);
|
|
8197
8267
|
const [feedbackText, setFeedbackText] = (0, import_react57.useState)();
|
|
8198
8268
|
const [isFeedbackSubmitted, setIsFeedbackSubmitted] = (0, import_react57.useState)(false);
|
|
8199
|
-
const tRatingLabel = ratingLabel != null ? ratingLabel : t(
|
|
8200
|
-
const tPositiveFeedbackLabel = positiveFeedbackLabel != null ? positiveFeedbackLabel : t(
|
|
8201
|
-
const tNegativeFeedbackLabel = negativeFeedbackLabel != null ? negativeFeedbackLabel : t(
|
|
8202
|
-
const tRatingSubmittedTitle = ratingSubmittedTitle != null ? ratingSubmittedTitle : t(
|
|
8203
|
-
const tSubmittedTitle = submittedTitle != null ? submittedTitle : t(
|
|
8204
|
-
const tTextAreaTip = textAreaTip != null ? textAreaTip : t(
|
|
8205
|
-
const tThumbUpTooltip = thumbUpTooltip != null ? thumbUpTooltip : t(
|
|
8206
|
-
const tThumbDownTooltip = thumbDownTooltip != null ? thumbDownTooltip : t(
|
|
8269
|
+
const tRatingLabel = ratingLabel != null ? ratingLabel : t(texts14.ratingQuestion);
|
|
8270
|
+
const tPositiveFeedbackLabel = positiveFeedbackLabel != null ? positiveFeedbackLabel : t(texts14.improvalQuestion);
|
|
8271
|
+
const tNegativeFeedbackLabel = negativeFeedbackLabel != null ? negativeFeedbackLabel : t(texts14.improvalQuestion);
|
|
8272
|
+
const tRatingSubmittedTitle = ratingSubmittedTitle != null ? ratingSubmittedTitle : t(texts14.thanks);
|
|
8273
|
+
const tSubmittedTitle = submittedTitle != null ? submittedTitle : t(texts14.thanks);
|
|
8274
|
+
const tTextAreaTip = textAreaTip != null ? textAreaTip : t(texts14.sensitiveInfo);
|
|
8275
|
+
const tThumbUpTooltip = thumbUpTooltip != null ? thumbUpTooltip : t(texts14.good);
|
|
8276
|
+
const tThumbDownTooltip = thumbDownTooltip != null ? thumbDownTooltip : t(texts14.bad);
|
|
8207
8277
|
(0, import_react57.useEffect)(() => {
|
|
8208
8278
|
if (ratingProp !== void 0) setRating(ratingProp);
|
|
8209
8279
|
}, [ratingProp]);
|
|
@@ -8258,42 +8328,48 @@ var Feedback = ({
|
|
|
8258
8328
|
}
|
|
8259
8329
|
return /* @__PURE__ */ (0, import_jsx_runtime256.jsx)(Paragraph, { children: tSubmittedTitle });
|
|
8260
8330
|
};
|
|
8261
|
-
var
|
|
8331
|
+
var texts14 = createTexts({
|
|
8262
8332
|
ratingQuestion: {
|
|
8263
8333
|
nb: "Hva syns du om tjenesten?",
|
|
8264
8334
|
no: "Hva syns du om tjenesten?",
|
|
8265
8335
|
nn: "Kva synest du om tenesta?",
|
|
8266
|
-
en: "What do you think about the service?"
|
|
8336
|
+
en: "What do you think about the service?",
|
|
8337
|
+
se: "Maid oaivvildat b\xE1lvalusa birra?"
|
|
8267
8338
|
},
|
|
8268
8339
|
improvalQuestion: {
|
|
8269
8340
|
nb: "Hva kan vi forbedre? (valgfritt)",
|
|
8270
8341
|
no: "Hva kan vi forbedre? (valgfritt)",
|
|
8271
8342
|
nn: "Kva kan vi forbetre? (valfritt)",
|
|
8272
|
-
en: "What can we improve? (optional)"
|
|
8343
|
+
en: "What can we improve? (optional)",
|
|
8344
|
+
se: "Maid s\xE1httit buoridit? (eavttola\u0161)"
|
|
8273
8345
|
},
|
|
8274
8346
|
thanks: {
|
|
8275
8347
|
nb: "Tusen takk! Tilbakemeldingen din hjelper oss \xE5 forbedre l\xF8sningen",
|
|
8276
8348
|
no: "Tusen takk! Tilbakemeldingen din hjelper oss \xE5 forbedre l\xF8sningen",
|
|
8277
8349
|
nn: "Tusen takk! Tilbakemeldinga di hjelper oss \xE5 forbetre l\xF8ysinga",
|
|
8278
|
-
en: "Thank you! Your feedback helps us improve the service"
|
|
8350
|
+
en: "Thank you! Your feedback helps us improve the service",
|
|
8351
|
+
se: "Giitu! Du m\xE1hcahat veahkeha min buoridit \u010Dovdosa"
|
|
8279
8352
|
},
|
|
8280
8353
|
sensitiveInfo: {
|
|
8281
8354
|
nb: "Ikke send inn personopplysninger eller annen sensitiv informasjon",
|
|
8282
8355
|
no: "Ikke send inn personopplysninger eller annen sensitiv informasjon",
|
|
8283
8356
|
nn: "Ikkje send inn personopplysningar eller annan sensitiv informasjon",
|
|
8284
|
-
en: "Do not submit personal data or other sensitive information"
|
|
8357
|
+
en: "Do not submit personal data or other sensitive information",
|
|
8358
|
+
se: "Ale s\xE1dde persuvdnadie\u0111uid dahje ear\xE1 sensitiiva die\u0111uid"
|
|
8285
8359
|
},
|
|
8286
8360
|
good: {
|
|
8287
8361
|
nb: "Bra",
|
|
8288
8362
|
no: "Bra",
|
|
8289
8363
|
nn: "Bra",
|
|
8290
|
-
en: "Good"
|
|
8364
|
+
en: "Good",
|
|
8365
|
+
se: "Buorre"
|
|
8291
8366
|
},
|
|
8292
8367
|
bad: {
|
|
8293
8368
|
nb: "D\xE5rlig",
|
|
8294
8369
|
no: "D\xE5rlig",
|
|
8295
8370
|
nn: "D\xE5rleg",
|
|
8296
|
-
en: "Bad"
|
|
8371
|
+
en: "Bad",
|
|
8372
|
+
se: "Heajos"
|
|
8297
8373
|
}
|
|
8298
8374
|
});
|
|
8299
8375
|
|
|
@@ -8428,9 +8504,9 @@ var File = (props) => {
|
|
|
8428
8504
|
onClick: removeFile,
|
|
8429
8505
|
icon: CloseIcon,
|
|
8430
8506
|
htmlProps: {
|
|
8431
|
-
"aria-label": t(
|
|
8507
|
+
"aria-label": t(texts15.removeFile(stateFile.file.name)),
|
|
8432
8508
|
"aria-invalid": !isValid ? true : void 0,
|
|
8433
|
-
"aria-errormessage": !isValid ? t(
|
|
8509
|
+
"aria-errormessage": !isValid ? t(texts15.invalidFile) : void 0,
|
|
8434
8510
|
"aria-describedby": spaceSeparatedIdListGenerator(
|
|
8435
8511
|
errorsList.map((e) => e.id)
|
|
8436
8512
|
)
|
|
@@ -8444,18 +8520,20 @@ var File = (props) => {
|
|
|
8444
8520
|
/* @__PURE__ */ (0, import_jsx_runtime260.jsx)(ErrorList, { errors: errorsList })
|
|
8445
8521
|
] });
|
|
8446
8522
|
};
|
|
8447
|
-
var
|
|
8523
|
+
var texts15 = createTexts({
|
|
8448
8524
|
removeFile: (file) => ({
|
|
8449
8525
|
nb: `Fjern fil ${file}`,
|
|
8450
8526
|
no: `Fjern fil ${file}`,
|
|
8451
8527
|
nn: `Fjern fil ${file}`,
|
|
8452
|
-
en: `Remove file ${file}
|
|
8528
|
+
en: `Remove file ${file}`,
|
|
8529
|
+
se: `Sihku filla ${file}`
|
|
8453
8530
|
}),
|
|
8454
8531
|
invalidFile: {
|
|
8455
8532
|
nb: "Ugyldig fil",
|
|
8456
8533
|
no: "Ugyldig fil",
|
|
8457
8534
|
nn: "Ugyldig fil",
|
|
8458
|
-
en: "Invalid file"
|
|
8535
|
+
en: "Invalid file",
|
|
8536
|
+
se: "F\xE1mohis fiila"
|
|
8459
8537
|
}
|
|
8460
8538
|
});
|
|
8461
8539
|
|
|
@@ -8578,7 +8656,7 @@ var useFileUploader = (props) => {
|
|
|
8578
8656
|
isFileDialogActive: false,
|
|
8579
8657
|
isDragActive: false,
|
|
8580
8658
|
rootErrors: calcRootErrors(
|
|
8581
|
-
t(
|
|
8659
|
+
t(texts16.invalidFileAmount),
|
|
8582
8660
|
initialFileUploaderFiles,
|
|
8583
8661
|
maxFiles,
|
|
8584
8662
|
errorMessage
|
|
@@ -8591,7 +8669,7 @@ var useFileUploader = (props) => {
|
|
|
8591
8669
|
const accepted = isFileAccepted(file, accept);
|
|
8592
8670
|
return {
|
|
8593
8671
|
file,
|
|
8594
|
-
errors: accepted ? [] : [t(
|
|
8672
|
+
errors: accepted ? [] : [t(texts16.invalidFileType)]
|
|
8595
8673
|
};
|
|
8596
8674
|
});
|
|
8597
8675
|
dispatch({
|
|
@@ -8604,7 +8682,7 @@ var useFileUploader = (props) => {
|
|
|
8604
8682
|
dispatch({
|
|
8605
8683
|
type: "setRootErrors",
|
|
8606
8684
|
payload: calcRootErrors(
|
|
8607
|
-
t(
|
|
8685
|
+
t(texts16.invalidFileAmount),
|
|
8608
8686
|
stateFiles,
|
|
8609
8687
|
maxFiles,
|
|
8610
8688
|
errorMessage
|
|
@@ -8658,7 +8736,7 @@ var useFileUploader = (props) => {
|
|
|
8658
8736
|
const accepted = isFileAccepted(file, accept);
|
|
8659
8737
|
return {
|
|
8660
8738
|
file,
|
|
8661
|
-
errors: accepted ? [] : [t(
|
|
8739
|
+
errors: accepted ? [] : [t(texts16.invalidFileType)]
|
|
8662
8740
|
};
|
|
8663
8741
|
}).concat(stateFiles);
|
|
8664
8742
|
onChange(newFiles.map((f) => f.file));
|
|
@@ -8750,18 +8828,20 @@ var useFileUploader = (props) => {
|
|
|
8750
8828
|
removeFile
|
|
8751
8829
|
};
|
|
8752
8830
|
};
|
|
8753
|
-
var
|
|
8831
|
+
var texts16 = createTexts({
|
|
8754
8832
|
invalidFileType: {
|
|
8755
8833
|
nb: "Ugyldig filtype",
|
|
8756
8834
|
no: "Ugyldig filtype",
|
|
8757
8835
|
nn: "Ugyldig filtype",
|
|
8758
|
-
en: "Invalid file type"
|
|
8836
|
+
en: "Invalid file type",
|
|
8837
|
+
se: "F\xE1mohis fila\u0161ladja"
|
|
8759
8838
|
},
|
|
8760
8839
|
invalidFileAmount: {
|
|
8761
8840
|
nb: "For mange filer. Maksimalt antall er ",
|
|
8762
8841
|
no: "For mange filer. Maksimalt antall er ",
|
|
8763
8842
|
nn: "For mange filer. Maksimalt antall er ",
|
|
8764
|
-
en: "Too many files. The maximum allowed is "
|
|
8843
|
+
en: "Too many files. The maximum allowed is ",
|
|
8844
|
+
se: "Menddo ollu fiillat. Maksim\xE1la lohku lea "
|
|
8765
8845
|
}
|
|
8766
8846
|
});
|
|
8767
8847
|
|
|
@@ -8772,7 +8852,7 @@ var FileUploader = (props) => {
|
|
|
8772
8852
|
id,
|
|
8773
8853
|
label,
|
|
8774
8854
|
dropAreaLabel,
|
|
8775
|
-
btnLabel
|
|
8855
|
+
btnLabel,
|
|
8776
8856
|
tip,
|
|
8777
8857
|
required = false,
|
|
8778
8858
|
withDragAndDrop = true,
|
|
@@ -8792,7 +8872,8 @@ var FileUploader = (props) => {
|
|
|
8792
8872
|
...rest
|
|
8793
8873
|
} = props;
|
|
8794
8874
|
const { t } = useTranslation();
|
|
8795
|
-
const tDropAreaLabel = dropAreaLabel != null ? dropAreaLabel : t(
|
|
8875
|
+
const tDropAreaLabel = dropAreaLabel != null ? dropAreaLabel : t(texts17.dragAndDropOr);
|
|
8876
|
+
const tBtnLabel = btnLabel != null ? btnLabel : t(texts17.selectFile);
|
|
8796
8877
|
const generatedId = (0, import_react59.useId)();
|
|
8797
8878
|
const uniqueId = id != null ? id : `${generatedId}-fileUploader`;
|
|
8798
8879
|
const {
|
|
@@ -8857,7 +8938,7 @@ var FileUploader = (props) => {
|
|
|
8857
8938
|
...rootErrorsList.map((e) => e.id)
|
|
8858
8939
|
])
|
|
8859
8940
|
},
|
|
8860
|
-
children:
|
|
8941
|
+
children: tBtnLabel
|
|
8861
8942
|
}
|
|
8862
8943
|
);
|
|
8863
8944
|
const input = /* @__PURE__ */ (0, import_jsx_runtime261.jsx)(
|
|
@@ -8901,7 +8982,7 @@ var FileUploader = (props) => {
|
|
|
8901
8982
|
children: [
|
|
8902
8983
|
input,
|
|
8903
8984
|
tDropAreaLabel,
|
|
8904
|
-
/* @__PURE__ */ (0, import_jsx_runtime261.jsx)(VisuallyHidden, { children: t(
|
|
8985
|
+
/* @__PURE__ */ (0, import_jsx_runtime261.jsx)(VisuallyHidden, { children: t(texts17.uploadFileWithButton) }),
|
|
8905
8986
|
button
|
|
8906
8987
|
]
|
|
8907
8988
|
}
|
|
@@ -8919,14 +9000,14 @@ var FileUploader = (props) => {
|
|
|
8919
9000
|
readOnly && FileUploader_default["readonly--file-list"]
|
|
8920
9001
|
),
|
|
8921
9002
|
children: [
|
|
8922
|
-
/* @__PURE__ */ (0, import_jsx_runtime261.jsx)(VisuallyHidden, { id: fileListNameId, children: t(
|
|
9003
|
+
/* @__PURE__ */ (0, import_jsx_runtime261.jsx)(VisuallyHidden, { id: fileListNameId, children: t(texts17.uploadedFiles) }),
|
|
8923
9004
|
inactive && fileListElements.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime261.jsx)(
|
|
8924
9005
|
Typography,
|
|
8925
9006
|
{
|
|
8926
9007
|
italic: true,
|
|
8927
9008
|
as: "span",
|
|
8928
9009
|
color: disabled ? "text-subtle" : "text-medium",
|
|
8929
|
-
children: t(
|
|
9010
|
+
children: t(texts17.noFiles)
|
|
8930
9011
|
}
|
|
8931
9012
|
) : /* @__PURE__ */ (0, import_jsx_runtime261.jsx)(StylelessList, { "aria-labelledby": fileListNameId, children: fileListElements })
|
|
8932
9013
|
]
|
|
@@ -8937,30 +9018,41 @@ var FileUploader = (props) => {
|
|
|
8937
9018
|
);
|
|
8938
9019
|
};
|
|
8939
9020
|
FileUploader.displayName = "FileUploader";
|
|
8940
|
-
var
|
|
9021
|
+
var texts17 = createTexts({
|
|
8941
9022
|
dragAndDropOr: {
|
|
8942
9023
|
nb: "Dra og slipp filer her eller",
|
|
8943
9024
|
no: "Dra og slipp filer her eller",
|
|
8944
9025
|
nn: "Dra og slepp filer her eller",
|
|
8945
|
-
en: "Drag and drop files here or"
|
|
9026
|
+
en: "Drag and drop files here or",
|
|
9027
|
+
se: "Sirdde fiillaid d\xE1sa dahje"
|
|
9028
|
+
},
|
|
9029
|
+
selectFile: {
|
|
9030
|
+
nb: "Velg fil",
|
|
9031
|
+
no: "Velg fil",
|
|
9032
|
+
nn: "Velg fil",
|
|
9033
|
+
en: "Sekect file",
|
|
9034
|
+
se: "V\xE1llje fiilla"
|
|
8946
9035
|
},
|
|
8947
9036
|
uploadFileWithButton: {
|
|
8948
9037
|
nb: "last opp en fil med den p\xE5f\xF8lgende knappen",
|
|
8949
9038
|
no: "last opp en fil med den p\xE5f\xF8lgende knappen",
|
|
8950
9039
|
nn: "last opp ei fil med den p\xE5f\xF8lgjande knappen",
|
|
8951
|
-
en: "upload using the following button"
|
|
9040
|
+
en: "upload using the following button",
|
|
9041
|
+
se: "vie\u010D\u010Da fiilla \u010Duovvova\u0161 boaluin"
|
|
8952
9042
|
},
|
|
8953
9043
|
noFiles: {
|
|
8954
9044
|
nb: "Ingen filer.",
|
|
8955
9045
|
no: "Ingen filer.",
|
|
8956
9046
|
nn: "Ingen filer.",
|
|
8957
|
-
en: "No files."
|
|
9047
|
+
en: "No files.",
|
|
9048
|
+
se: "Eai leat fiillat."
|
|
8958
9049
|
},
|
|
8959
9050
|
uploadedFiles: {
|
|
8960
9051
|
nb: "Opplastede filer",
|
|
8961
9052
|
no: "Opplastede filer",
|
|
8962
9053
|
nn: "Opplasta filer",
|
|
8963
|
-
en: "Uploaded files"
|
|
9054
|
+
en: "Uploaded files",
|
|
9055
|
+
se: "Vi\u017E\u017Eon fiillat"
|
|
8964
9056
|
}
|
|
8965
9057
|
});
|
|
8966
9058
|
|
|
@@ -9036,6 +9128,91 @@ var FooterListGroup = ({
|
|
|
9036
9128
|
var import_jsx_runtime269 = require("react/jsx-runtime");
|
|
9037
9129
|
var FooterLeft = ({ className, ...rest }) => /* @__PURE__ */ (0, import_jsx_runtime269.jsx)("div", { className: cn(className, Footer_default["left"]), ...rest });
|
|
9038
9130
|
|
|
9131
|
+
// src/components/FormSummary/FormSummary.tsx
|
|
9132
|
+
var import_jsx_runtime270 = require("react/jsx-runtime");
|
|
9133
|
+
var FormSummary = (props) => {
|
|
9134
|
+
const { children } = props;
|
|
9135
|
+
return /* @__PURE__ */ (0, import_jsx_runtime270.jsx)(Paper, { border: "border-subtle", padding: "x0.5 x0.5 x1 x0.75", ...props, children });
|
|
9136
|
+
};
|
|
9137
|
+
|
|
9138
|
+
// src/components/FormSummary/FormSummary.module.css
|
|
9139
|
+
var FormSummary_default = {
|
|
9140
|
+
dd: "FormSummary_dd",
|
|
9141
|
+
field: "FormSummary_field"
|
|
9142
|
+
};
|
|
9143
|
+
|
|
9144
|
+
// src/components/FormSummary/FormSummary.components.tsx
|
|
9145
|
+
var import_jsx_runtime271 = require("react/jsx-runtime");
|
|
9146
|
+
function FormSummaryHeader({ ...props }) {
|
|
9147
|
+
return /* @__PURE__ */ (0, import_jsx_runtime271.jsx)(
|
|
9148
|
+
HStack,
|
|
9149
|
+
{
|
|
9150
|
+
...props,
|
|
9151
|
+
justifyContent: "space-between",
|
|
9152
|
+
flexWrap: "wrap",
|
|
9153
|
+
alignItems: "center",
|
|
9154
|
+
gap: "x0.75",
|
|
9155
|
+
marginBlock: "0 x0.75"
|
|
9156
|
+
}
|
|
9157
|
+
);
|
|
9158
|
+
}
|
|
9159
|
+
function FormSummaryHeading({
|
|
9160
|
+
level = 2,
|
|
9161
|
+
...props
|
|
9162
|
+
}) {
|
|
9163
|
+
return /* @__PURE__ */ (0, import_jsx_runtime271.jsx)(Heading, { level, ...props });
|
|
9164
|
+
}
|
|
9165
|
+
function FormSummaryEditButton({
|
|
9166
|
+
purpose = "secondary",
|
|
9167
|
+
...props
|
|
9168
|
+
}) {
|
|
9169
|
+
return /* @__PURE__ */ (0, import_jsx_runtime271.jsx)(Button, { icon: EditIcon, purpose, size: "xsmall", ...props });
|
|
9170
|
+
}
|
|
9171
|
+
function FormSummaryFields({ ...props }) {
|
|
9172
|
+
return /* @__PURE__ */ (0, import_jsx_runtime271.jsx)(DescriptionList, { ...props });
|
|
9173
|
+
}
|
|
9174
|
+
function FormSummaryField({
|
|
9175
|
+
className,
|
|
9176
|
+
...props
|
|
9177
|
+
}) {
|
|
9178
|
+
return /* @__PURE__ */ (0, import_jsx_runtime271.jsx)("div", { ...props, className: cn(FormSummary_default.field, className) });
|
|
9179
|
+
}
|
|
9180
|
+
function FormSummaryLabel(props) {
|
|
9181
|
+
return /* @__PURE__ */ (0, import_jsx_runtime271.jsx)(DescriptionListTerm, { ...props });
|
|
9182
|
+
}
|
|
9183
|
+
function FormSummaryValue({
|
|
9184
|
+
className,
|
|
9185
|
+
isLoading,
|
|
9186
|
+
children,
|
|
9187
|
+
...props
|
|
9188
|
+
}) {
|
|
9189
|
+
return /* @__PURE__ */ (0, import_jsx_runtime271.jsx)(DescriptionListDesc, { ...props, className: cn(className, FormSummary_default.dd), children: isLoading ? /* @__PURE__ */ (0, import_jsx_runtime271.jsx)(Spinner, { size: "1.5em" }) : children });
|
|
9190
|
+
}
|
|
9191
|
+
function FormSummaryEmptyValue() {
|
|
9192
|
+
const { t } = useTranslation();
|
|
9193
|
+
return /* @__PURE__ */ (0, import_jsx_runtime271.jsxs)("span", { children: [
|
|
9194
|
+
/* @__PURE__ */ (0, import_jsx_runtime271.jsx)("span", { "aria-hidden": true, children: "-" }),
|
|
9195
|
+
" ",
|
|
9196
|
+
/* @__PURE__ */ (0, import_jsx_runtime271.jsxs)(VisuallyHidden, { children: [
|
|
9197
|
+
" ",
|
|
9198
|
+
t(texts18.noValue),
|
|
9199
|
+
" "
|
|
9200
|
+
] })
|
|
9201
|
+
] });
|
|
9202
|
+
}
|
|
9203
|
+
function FormSummaryError({ ...props }) {
|
|
9204
|
+
return /* @__PURE__ */ (0, import_jsx_runtime271.jsx)(Box, { marginBlock: "x0.25 0", children: /* @__PURE__ */ (0, import_jsx_runtime271.jsx)(InputMessage, { ...props, messageType: "error" }) });
|
|
9205
|
+
}
|
|
9206
|
+
var texts18 = createTexts({
|
|
9207
|
+
noValue: {
|
|
9208
|
+
nb: "Ikke fylt ut",
|
|
9209
|
+
no: "Ikke fylt ut",
|
|
9210
|
+
nn: "Ikkje fylt ut",
|
|
9211
|
+
en: "Not filled out",
|
|
9212
|
+
se: "Ii leat bidjan"
|
|
9213
|
+
}
|
|
9214
|
+
});
|
|
9215
|
+
|
|
9039
9216
|
// src/components/GlobalMessage/GlobalMessage.tsx
|
|
9040
9217
|
var import_react60 = require("react");
|
|
9041
9218
|
|
|
@@ -9051,7 +9228,7 @@ var GlobalMessage_default = {
|
|
|
9051
9228
|
};
|
|
9052
9229
|
|
|
9053
9230
|
// src/components/GlobalMessage/GlobalMessage.tsx
|
|
9054
|
-
var
|
|
9231
|
+
var import_jsx_runtime272 = require("react/jsx-runtime");
|
|
9055
9232
|
var icons = {
|
|
9056
9233
|
info: InfoIcon,
|
|
9057
9234
|
danger: ErrorIcon,
|
|
@@ -9070,7 +9247,7 @@ var GlobalMessage = ({
|
|
|
9070
9247
|
}) => {
|
|
9071
9248
|
const { t } = useTranslation();
|
|
9072
9249
|
const [isClosed, setClosed] = (0, import_react60.useState)(false);
|
|
9073
|
-
return !isClosed ? /* @__PURE__ */ (0,
|
|
9250
|
+
return !isClosed ? /* @__PURE__ */ (0, import_jsx_runtime272.jsxs)(
|
|
9074
9251
|
"div",
|
|
9075
9252
|
{
|
|
9076
9253
|
...getBaseHTMLProps(
|
|
@@ -9085,17 +9262,17 @@ var GlobalMessage = ({
|
|
|
9085
9262
|
rest
|
|
9086
9263
|
),
|
|
9087
9264
|
children: [
|
|
9088
|
-
/* @__PURE__ */ (0,
|
|
9265
|
+
/* @__PURE__ */ (0, import_jsx_runtime272.jsxs)(
|
|
9089
9266
|
"div",
|
|
9090
9267
|
{
|
|
9091
9268
|
className: cn(GlobalMessage_default.content, closable && GlobalMessage_default["content--closable"]),
|
|
9092
9269
|
children: [
|
|
9093
|
-
/* @__PURE__ */ (0,
|
|
9094
|
-
children != null ? children : /* @__PURE__ */ (0,
|
|
9270
|
+
/* @__PURE__ */ (0, import_jsx_runtime272.jsx)(Icon, { icon: icons[purpose], className: GlobalMessage_default.icon }),
|
|
9271
|
+
children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime272.jsx)("span", { children: message })
|
|
9095
9272
|
]
|
|
9096
9273
|
}
|
|
9097
9274
|
),
|
|
9098
|
-
closable && /* @__PURE__ */ (0,
|
|
9275
|
+
closable && /* @__PURE__ */ (0, import_jsx_runtime272.jsx)(
|
|
9099
9276
|
Button,
|
|
9100
9277
|
{
|
|
9101
9278
|
icon: CloseIcon,
|
|
@@ -9120,14 +9297,14 @@ var InlineButton_default = {
|
|
|
9120
9297
|
};
|
|
9121
9298
|
|
|
9122
9299
|
// src/components/InlineButton/InlineButton.tsx
|
|
9123
|
-
var
|
|
9300
|
+
var import_jsx_runtime273 = require("react/jsx-runtime");
|
|
9124
9301
|
var InlineButton = ({
|
|
9125
9302
|
className,
|
|
9126
9303
|
color,
|
|
9127
9304
|
icon,
|
|
9128
9305
|
children,
|
|
9129
9306
|
...rest
|
|
9130
|
-
}) => /* @__PURE__ */ (0,
|
|
9307
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime273.jsx)(
|
|
9131
9308
|
StylelessButton,
|
|
9132
9309
|
{
|
|
9133
9310
|
className: cn(
|
|
@@ -9138,7 +9315,7 @@ var InlineButton = ({
|
|
|
9138
9315
|
getColorCn(color)
|
|
9139
9316
|
),
|
|
9140
9317
|
...rest,
|
|
9141
|
-
children: icon ? /* @__PURE__ */ (0,
|
|
9318
|
+
children: icon ? /* @__PURE__ */ (0, import_jsx_runtime273.jsx)(Icon, { icon, iconSize: "inherit" }) : children
|
|
9142
9319
|
}
|
|
9143
9320
|
);
|
|
9144
9321
|
|
|
@@ -9147,7 +9324,7 @@ var import_react63 = require("react");
|
|
|
9147
9324
|
|
|
9148
9325
|
// src/components/InlineEdit/InlineEdit.context.tsx
|
|
9149
9326
|
var import_react61 = require("react");
|
|
9150
|
-
var
|
|
9327
|
+
var import_jsx_runtime274 = require("react/jsx-runtime");
|
|
9151
9328
|
var InlineEditContext = (0, import_react61.createContext)(
|
|
9152
9329
|
{}
|
|
9153
9330
|
);
|
|
@@ -9191,7 +9368,7 @@ var InlineEditContextProvider = (props) => {
|
|
|
9191
9368
|
useOnKeyDown(["Enter"], () => onExitHandler());
|
|
9192
9369
|
useOnKeyDown(["Escape"], () => onExitHandler());
|
|
9193
9370
|
useOnClickOutside(inputRef == null ? void 0 : inputRef.current, () => onExitHandler());
|
|
9194
|
-
return /* @__PURE__ */ (0,
|
|
9371
|
+
return /* @__PURE__ */ (0, import_jsx_runtime274.jsx)(
|
|
9195
9372
|
InlineEditContext,
|
|
9196
9373
|
{
|
|
9197
9374
|
value: {
|
|
@@ -9226,26 +9403,29 @@ var InlineEdit_default = {
|
|
|
9226
9403
|
};
|
|
9227
9404
|
|
|
9228
9405
|
// src/components/InlineEdit/InlineEdit.utils.tsx
|
|
9229
|
-
var
|
|
9406
|
+
var import_jsx_runtime275 = require("react/jsx-runtime");
|
|
9230
9407
|
var inlineEditVisuallyHidden = (id, clearable) => {
|
|
9231
9408
|
const { t } = useTranslation();
|
|
9232
|
-
return /* @__PURE__ */ (0,
|
|
9233
|
-
t(
|
|
9234
|
-
|
|
9409
|
+
return /* @__PURE__ */ (0, import_jsx_runtime275.jsxs)(VisuallyHidden, { id, children: [
|
|
9410
|
+
t(texts19.inlineEditInfo),
|
|
9411
|
+
" ",
|
|
9412
|
+
!clearable && t(texts19.notClearable)
|
|
9235
9413
|
] });
|
|
9236
9414
|
};
|
|
9237
|
-
var
|
|
9415
|
+
var texts19 = createTexts({
|
|
9238
9416
|
inlineEditInfo: {
|
|
9239
9417
|
nb: "Escape, Enter eller Tab for \xE5 lagre.",
|
|
9240
9418
|
no: "Escape, Enter eller Tab for \xE5 lagre.",
|
|
9241
9419
|
nn: "Escape, Enter eller Tab for \xE5 lagra.",
|
|
9242
|
-
en: "Escape, Enter or Tab to save."
|
|
9420
|
+
en: "Escape, Enter or Tab to save.",
|
|
9421
|
+
se: "Escape, Enter dahje Tab go \xE1iggut vurket"
|
|
9243
9422
|
},
|
|
9244
9423
|
notClearable: {
|
|
9245
|
-
nb: "
|
|
9246
|
-
no: "
|
|
9247
|
-
nn: "
|
|
9248
|
-
en: "
|
|
9424
|
+
nb: "Innskrivingsfeltet kan ikke t\xF8mmes.",
|
|
9425
|
+
no: "Innskrivingsfeltet kan ikke t\xF8mmes.",
|
|
9426
|
+
nn: "Innskrivingsfeltet kan ikkje t\xF8mmast.",
|
|
9427
|
+
en: "Input field cannot be cleared.",
|
|
9428
|
+
se: "\u010C\xE1llinb\xE1ikki ii s\xE1hte sihkut"
|
|
9249
9429
|
}
|
|
9250
9430
|
});
|
|
9251
9431
|
var inlineEditCns = (hasErrorState, showEditingIcon) => [
|
|
@@ -9295,7 +9475,7 @@ function createClearChangeEvent(elementId) {
|
|
|
9295
9475
|
}
|
|
9296
9476
|
|
|
9297
9477
|
// src/components/InlineEdit/InlineField.tsx
|
|
9298
|
-
var
|
|
9478
|
+
var import_jsx_runtime276 = require("react/jsx-runtime");
|
|
9299
9479
|
function InlineField(props) {
|
|
9300
9480
|
const {
|
|
9301
9481
|
elementType,
|
|
@@ -9341,7 +9521,7 @@ function InlineField(props) {
|
|
|
9341
9521
|
const cnArgs = [hasErrorState, !isEditing && !hideIcon];
|
|
9342
9522
|
const iconSize = "small";
|
|
9343
9523
|
function makeIcon(icon, className2) {
|
|
9344
|
-
return /* @__PURE__ */ (0,
|
|
9524
|
+
return /* @__PURE__ */ (0, import_jsx_runtime276.jsx)(
|
|
9345
9525
|
Icon,
|
|
9346
9526
|
{
|
|
9347
9527
|
iconSize,
|
|
@@ -9356,7 +9536,7 @@ function InlineField(props) {
|
|
|
9356
9536
|
const renderElement = () => {
|
|
9357
9537
|
switch (elementType) {
|
|
9358
9538
|
case "input":
|
|
9359
|
-
return /* @__PURE__ */ (0,
|
|
9539
|
+
return /* @__PURE__ */ (0, import_jsx_runtime276.jsx)(
|
|
9360
9540
|
"input",
|
|
9361
9541
|
{
|
|
9362
9542
|
...rest,
|
|
@@ -9366,7 +9546,7 @@ function InlineField(props) {
|
|
|
9366
9546
|
}
|
|
9367
9547
|
);
|
|
9368
9548
|
case "textarea":
|
|
9369
|
-
return /* @__PURE__ */ (0,
|
|
9549
|
+
return /* @__PURE__ */ (0, import_jsx_runtime276.jsx)(
|
|
9370
9550
|
"textarea",
|
|
9371
9551
|
{
|
|
9372
9552
|
...rest,
|
|
@@ -9376,8 +9556,8 @@ function InlineField(props) {
|
|
|
9376
9556
|
}
|
|
9377
9557
|
);
|
|
9378
9558
|
case "select":
|
|
9379
|
-
return /* @__PURE__ */ (0,
|
|
9380
|
-
/* @__PURE__ */ (0,
|
|
9559
|
+
return /* @__PURE__ */ (0, import_jsx_runtime276.jsxs)(import_jsx_runtime276.Fragment, { children: [
|
|
9560
|
+
/* @__PURE__ */ (0, import_jsx_runtime276.jsx)(
|
|
9381
9561
|
"select",
|
|
9382
9562
|
{
|
|
9383
9563
|
...rest,
|
|
@@ -9386,7 +9566,7 @@ function InlineField(props) {
|
|
|
9386
9566
|
className: cn(className, ...inlineSelectCns(...cnArgs, hasValue))
|
|
9387
9567
|
}
|
|
9388
9568
|
),
|
|
9389
|
-
hasValue && emptiable && /* @__PURE__ */ (0,
|
|
9569
|
+
hasValue && emptiable && /* @__PURE__ */ (0, import_jsx_runtime276.jsx)(
|
|
9390
9570
|
ClearButton,
|
|
9391
9571
|
{
|
|
9392
9572
|
"aria-label": t(commonTexts.clearSelect),
|
|
@@ -9401,8 +9581,8 @@ function InlineField(props) {
|
|
|
9401
9581
|
return null;
|
|
9402
9582
|
}
|
|
9403
9583
|
};
|
|
9404
|
-
return /* @__PURE__ */ (0,
|
|
9405
|
-
/* @__PURE__ */ (0,
|
|
9584
|
+
return /* @__PURE__ */ (0, import_jsx_runtime276.jsxs)(Box, { position: "relative", width, children: [
|
|
9585
|
+
/* @__PURE__ */ (0, import_jsx_runtime276.jsxs)("div", { className: Input_default["input-group"], children: [
|
|
9406
9586
|
!isEditing && !hideIcon && makeIcon(EditIcon, InlineEdit_default["edit-icon"]),
|
|
9407
9587
|
renderElement()
|
|
9408
9588
|
] }),
|
|
@@ -9412,7 +9592,7 @@ function InlineField(props) {
|
|
|
9412
9592
|
}
|
|
9413
9593
|
|
|
9414
9594
|
// src/components/InlineEdit/InlineEditTextArea/InlineEditTextArea.tsx
|
|
9415
|
-
var
|
|
9595
|
+
var import_jsx_runtime277 = require("react/jsx-runtime");
|
|
9416
9596
|
var InlineEditTextArea = ({
|
|
9417
9597
|
onSetValue,
|
|
9418
9598
|
emptiable,
|
|
@@ -9425,7 +9605,7 @@ var InlineEditTextArea = ({
|
|
|
9425
9605
|
}) => {
|
|
9426
9606
|
const textareaRef = (0, import_react63.useRef)(null);
|
|
9427
9607
|
const combinedRef = useCombinedRef(ref, textareaRef);
|
|
9428
|
-
return /* @__PURE__ */ (0,
|
|
9608
|
+
return /* @__PURE__ */ (0, import_jsx_runtime277.jsx)(
|
|
9429
9609
|
InlineEditContextProvider,
|
|
9430
9610
|
{
|
|
9431
9611
|
onSetValue,
|
|
@@ -9435,14 +9615,14 @@ var InlineEditTextArea = ({
|
|
|
9435
9615
|
onFocus,
|
|
9436
9616
|
onChange,
|
|
9437
9617
|
onBlur,
|
|
9438
|
-
children: /* @__PURE__ */ (0,
|
|
9618
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime277.jsx)(InlineField, { elementType: "textarea", ...rest, ref: combinedRef })
|
|
9439
9619
|
}
|
|
9440
9620
|
);
|
|
9441
9621
|
};
|
|
9442
9622
|
|
|
9443
9623
|
// src/components/InlineEdit/InlineEditInput/InlineEditInput.tsx
|
|
9444
9624
|
var import_react64 = require("react");
|
|
9445
|
-
var
|
|
9625
|
+
var import_jsx_runtime278 = require("react/jsx-runtime");
|
|
9446
9626
|
var InlineEditInput = ({
|
|
9447
9627
|
onSetValue,
|
|
9448
9628
|
emptiable,
|
|
@@ -9455,7 +9635,7 @@ var InlineEditInput = ({
|
|
|
9455
9635
|
}) => {
|
|
9456
9636
|
const inputRef = (0, import_react64.useRef)(null);
|
|
9457
9637
|
const combinedRef = useCombinedRef(ref, inputRef);
|
|
9458
|
-
return /* @__PURE__ */ (0,
|
|
9638
|
+
return /* @__PURE__ */ (0, import_jsx_runtime278.jsx)(
|
|
9459
9639
|
InlineEditContextProvider,
|
|
9460
9640
|
{
|
|
9461
9641
|
onSetValue,
|
|
@@ -9465,14 +9645,14 @@ var InlineEditInput = ({
|
|
|
9465
9645
|
onFocus,
|
|
9466
9646
|
onChange,
|
|
9467
9647
|
onBlur,
|
|
9468
|
-
children: /* @__PURE__ */ (0,
|
|
9648
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime278.jsx)(InlineField, { elementType: "input", ...rest, ref: combinedRef })
|
|
9469
9649
|
}
|
|
9470
9650
|
);
|
|
9471
9651
|
};
|
|
9472
9652
|
|
|
9473
9653
|
// src/components/InlineEdit/InlineEditSelect/InlineEditSelect.tsx
|
|
9474
9654
|
var import_react65 = require("react");
|
|
9475
|
-
var
|
|
9655
|
+
var import_jsx_runtime279 = require("react/jsx-runtime");
|
|
9476
9656
|
var InlineEditSelect = ({
|
|
9477
9657
|
onSetValue,
|
|
9478
9658
|
emptiable,
|
|
@@ -9485,7 +9665,7 @@ var InlineEditSelect = ({
|
|
|
9485
9665
|
}) => {
|
|
9486
9666
|
const inputRef = (0, import_react65.useRef)(null);
|
|
9487
9667
|
const combinedRef = useCombinedRef(ref, inputRef);
|
|
9488
|
-
return /* @__PURE__ */ (0,
|
|
9668
|
+
return /* @__PURE__ */ (0, import_jsx_runtime279.jsx)(
|
|
9489
9669
|
InlineEditContextProvider,
|
|
9490
9670
|
{
|
|
9491
9671
|
onSetValue,
|
|
@@ -9495,7 +9675,7 @@ var InlineEditSelect = ({
|
|
|
9495
9675
|
onFocus,
|
|
9496
9676
|
onChange,
|
|
9497
9677
|
onBlur,
|
|
9498
|
-
children: /* @__PURE__ */ (0,
|
|
9678
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime279.jsx)(InlineField, { elementType: "select", ...rest, ref: combinedRef })
|
|
9499
9679
|
}
|
|
9500
9680
|
);
|
|
9501
9681
|
};
|
|
@@ -9517,8 +9697,8 @@ var InternalHeader_default = {
|
|
|
9517
9697
|
};
|
|
9518
9698
|
|
|
9519
9699
|
// src/components/InternalHeader/NavigationItem.tsx
|
|
9520
|
-
var
|
|
9521
|
-
var NavigationItem = ({ isCurrent, ...rest }) => /* @__PURE__ */ (0,
|
|
9700
|
+
var import_jsx_runtime280 = require("react/jsx-runtime");
|
|
9701
|
+
var NavigationItem = ({ isCurrent, ...rest }) => /* @__PURE__ */ (0, import_jsx_runtime280.jsx)(
|
|
9522
9702
|
"a",
|
|
9523
9703
|
{
|
|
9524
9704
|
...rest,
|
|
@@ -9533,7 +9713,7 @@ var NavigationItem = ({ isCurrent, ...rest }) => /* @__PURE__ */ (0, import_jsx_
|
|
|
9533
9713
|
);
|
|
9534
9714
|
|
|
9535
9715
|
// src/components/InternalHeader/InternalHeader.tsx
|
|
9536
|
-
var
|
|
9716
|
+
var import_jsx_runtime281 = require("react/jsx-runtime");
|
|
9537
9717
|
var import_react67 = require("react");
|
|
9538
9718
|
var InternalHeader = (props) => {
|
|
9539
9719
|
const {
|
|
@@ -9563,7 +9743,7 @@ var InternalHeader = (props) => {
|
|
|
9563
9743
|
const hasContextMenuElements = !!contextMenuItems && contextMenuItems.length > 0;
|
|
9564
9744
|
const hasSmallScreenBreakpoint = !!smallScreenBreakpoint;
|
|
9565
9745
|
const hasNavInContextMenu = hasSmallScreenBreakpoint && hasNavigationElements;
|
|
9566
|
-
const navigation = hasNavigationElements ? /* @__PURE__ */ (0,
|
|
9746
|
+
const navigation = hasNavigationElements ? /* @__PURE__ */ (0, import_jsx_runtime281.jsx)("nav", { "aria-label": t(texts20.siteNavigation), children: /* @__PURE__ */ (0, import_jsx_runtime281.jsx)(
|
|
9567
9747
|
ShowHide,
|
|
9568
9748
|
{
|
|
9569
9749
|
as: StylelessList,
|
|
@@ -9572,7 +9752,7 @@ var InternalHeader = (props) => {
|
|
|
9572
9752
|
children: navItems.map((item, i) => {
|
|
9573
9753
|
const { href, ...rest2 } = item;
|
|
9574
9754
|
const isCurrent = href === currentPage;
|
|
9575
|
-
return /* @__PURE__ */ (0,
|
|
9755
|
+
return /* @__PURE__ */ (0, import_jsx_runtime281.jsx)("li", { className: InternalHeader_default["nav-list__item"], children: /* @__PURE__ */ (0, import_jsx_runtime281.jsx)(
|
|
9576
9756
|
NavigationItem,
|
|
9577
9757
|
{
|
|
9578
9758
|
href,
|
|
@@ -9586,7 +9766,7 @@ var InternalHeader = (props) => {
|
|
|
9586
9766
|
) }) : null;
|
|
9587
9767
|
const hasContextMenu = hasContextMenuElements || !!user || hasNavInContextMenu;
|
|
9588
9768
|
const hasContextMenuLargeScreen = hasContextMenuElements || !!user;
|
|
9589
|
-
return /* @__PURE__ */ (0,
|
|
9769
|
+
return /* @__PURE__ */ (0, import_jsx_runtime281.jsxs)(
|
|
9590
9770
|
Box,
|
|
9591
9771
|
{
|
|
9592
9772
|
display: "flex",
|
|
@@ -9604,7 +9784,7 @@ var InternalHeader = (props) => {
|
|
|
9604
9784
|
rest
|
|
9605
9785
|
),
|
|
9606
9786
|
children: [
|
|
9607
|
-
/* @__PURE__ */ (0,
|
|
9787
|
+
/* @__PURE__ */ (0, import_jsx_runtime281.jsx)(Typography, { typographyType: "headingSmall", bold: true, as: "span", children: applicationHref ? /* @__PURE__ */ (0, import_jsx_runtime281.jsx)(
|
|
9608
9788
|
"a",
|
|
9609
9789
|
{
|
|
9610
9790
|
href: applicationHref,
|
|
@@ -9613,42 +9793,42 @@ var InternalHeader = (props) => {
|
|
|
9613
9793
|
children: applicationName
|
|
9614
9794
|
}
|
|
9615
9795
|
) : applicationName }),
|
|
9616
|
-
/* @__PURE__ */ (0,
|
|
9617
|
-
(hasContextMenu || navigation !== null) && /* @__PURE__ */ (0,
|
|
9796
|
+
/* @__PURE__ */ (0, import_jsx_runtime281.jsx)(Typography, { typographyType: "bodyMedium", as: "span", children: applicationDesc }),
|
|
9797
|
+
(hasContextMenu || navigation !== null) && /* @__PURE__ */ (0, import_jsx_runtime281.jsx)("div", { className: InternalHeader_default["bar-separator"] }),
|
|
9618
9798
|
navigation,
|
|
9619
|
-
hasContextMenu && /* @__PURE__ */ (0,
|
|
9799
|
+
hasContextMenu && /* @__PURE__ */ (0, import_jsx_runtime281.jsx)(
|
|
9620
9800
|
ShowHide,
|
|
9621
9801
|
{
|
|
9622
9802
|
showBelow: !hasContextMenuLargeScreen && hasSmallScreenBreakpoint ? smallScreenBreakpoint : void 0,
|
|
9623
9803
|
className: cn(InternalHeader_default["context-menu-group"]),
|
|
9624
|
-
children: /* @__PURE__ */ (0,
|
|
9625
|
-
/* @__PURE__ */ (0,
|
|
9804
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime281.jsxs)(OverflowMenuGroup, { children: [
|
|
9805
|
+
/* @__PURE__ */ (0, import_jsx_runtime281.jsx)(
|
|
9626
9806
|
Button,
|
|
9627
9807
|
{
|
|
9628
9808
|
icon: hasNavInContextMenu ? MenuIcon : MoreVerticalIcon,
|
|
9629
9809
|
purpose: "tertiary",
|
|
9630
|
-
"aria-label": t(
|
|
9810
|
+
"aria-label": t(texts20.openMenu)
|
|
9631
9811
|
}
|
|
9632
9812
|
),
|
|
9633
|
-
/* @__PURE__ */ (0,
|
|
9634
|
-
user && /* @__PURE__ */ (0,
|
|
9635
|
-
hasNavInContextMenu && /* @__PURE__ */ (0,
|
|
9813
|
+
/* @__PURE__ */ (0, import_jsx_runtime281.jsxs)(OverflowMenu, { className: InternalHeader_default["context-menu"], children: [
|
|
9814
|
+
user && /* @__PURE__ */ (0, import_jsx_runtime281.jsx)(OverflowMenuList, { children: user.href ? /* @__PURE__ */ (0, import_jsx_runtime281.jsx)(OverflowMenuLink, { icon: PersonIcon, ...user }) : /* @__PURE__ */ (0, import_jsx_runtime281.jsx)(OverflowMenuSpan, { icon: PersonIcon, ...user }) }),
|
|
9815
|
+
hasNavInContextMenu && /* @__PURE__ */ (0, import_jsx_runtime281.jsx)(
|
|
9636
9816
|
ShowHide,
|
|
9637
9817
|
{
|
|
9638
9818
|
as: "nav",
|
|
9639
|
-
"aria-label": t(
|
|
9819
|
+
"aria-label": t(texts20.siteNavigation),
|
|
9640
9820
|
showBelow: smallScreenBreakpoint,
|
|
9641
|
-
children: /* @__PURE__ */ (0,
|
|
9821
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime281.jsx)(OverflowMenuList, { children: navItems.map((item, i) => /* @__PURE__ */ (0, import_react67.createElement)(OverflowMenuLink, { ...item, key: `nav-${i}` })) })
|
|
9642
9822
|
}
|
|
9643
9823
|
),
|
|
9644
|
-
hasNavInContextMenu && hasContextMenuElements && /* @__PURE__ */ (0,
|
|
9824
|
+
hasNavInContextMenu && hasContextMenuElements && /* @__PURE__ */ (0, import_jsx_runtime281.jsx)(
|
|
9645
9825
|
ShowHide,
|
|
9646
9826
|
{
|
|
9647
9827
|
as: OverflowMenuDivider,
|
|
9648
9828
|
showBelow: smallScreenBreakpoint
|
|
9649
9829
|
}
|
|
9650
9830
|
),
|
|
9651
|
-
hasContextMenuElements && /* @__PURE__ */ (0,
|
|
9831
|
+
hasContextMenuElements && /* @__PURE__ */ (0, import_jsx_runtime281.jsx)(OverflowMenuList, { children: contextMenuItems.map((item, i) => {
|
|
9652
9832
|
return item.href ? /* @__PURE__ */ (0, import_react67.createElement)(
|
|
9653
9833
|
OverflowMenuLink,
|
|
9654
9834
|
{
|
|
@@ -9672,18 +9852,20 @@ var InternalHeader = (props) => {
|
|
|
9672
9852
|
);
|
|
9673
9853
|
};
|
|
9674
9854
|
InternalHeader.displayName = "InternalHeader";
|
|
9675
|
-
var
|
|
9855
|
+
var texts20 = createTexts({
|
|
9676
9856
|
openMenu: {
|
|
9677
9857
|
nb: "\xC5pne meny",
|
|
9678
9858
|
no: "\xC5pne meny",
|
|
9679
9859
|
nn: "Opna meny",
|
|
9680
|
-
en: "Open menu"
|
|
9860
|
+
en: "Open menu",
|
|
9861
|
+
se: "Rabas f\xE1llu"
|
|
9681
9862
|
},
|
|
9682
9863
|
siteNavigation: {
|
|
9683
9864
|
nb: "Sidenavigasjon",
|
|
9684
9865
|
no: "Sidenavigasjon",
|
|
9685
9866
|
nn: "Sidenavigasjon",
|
|
9686
|
-
en: "Site navigation"
|
|
9867
|
+
en: "Site navigation",
|
|
9868
|
+
se: "Siidu navig\xE1\u0161uvdna"
|
|
9687
9869
|
}
|
|
9688
9870
|
});
|
|
9689
9871
|
|
|
@@ -9697,7 +9879,7 @@ var List_default = {
|
|
|
9697
9879
|
};
|
|
9698
9880
|
|
|
9699
9881
|
// src/components/List/List.tsx
|
|
9700
|
-
var
|
|
9882
|
+
var import_jsx_runtime282 = require("react/jsx-runtime");
|
|
9701
9883
|
var List = ({
|
|
9702
9884
|
listType = "unordered",
|
|
9703
9885
|
typographyType = "inherit",
|
|
@@ -9708,7 +9890,7 @@ var List = ({
|
|
|
9708
9890
|
...rest
|
|
9709
9891
|
}) => {
|
|
9710
9892
|
const List2 = listType === "ordered" ? "ol" : "ul";
|
|
9711
|
-
return /* @__PURE__ */ (0,
|
|
9893
|
+
return /* @__PURE__ */ (0, import_jsx_runtime282.jsx)(
|
|
9712
9894
|
List2,
|
|
9713
9895
|
{
|
|
9714
9896
|
...getBaseHTMLProps(id, className, htmlProps, rest),
|
|
@@ -9724,8 +9906,8 @@ var List = ({
|
|
|
9724
9906
|
List.displayName = "List";
|
|
9725
9907
|
|
|
9726
9908
|
// src/components/List/ListItem.tsx
|
|
9727
|
-
var
|
|
9728
|
-
var ListItem = ({ className, ...rest }) => /* @__PURE__ */ (0,
|
|
9909
|
+
var import_jsx_runtime283 = require("react/jsx-runtime");
|
|
9910
|
+
var ListItem = ({ className, ...rest }) => /* @__PURE__ */ (0, import_jsx_runtime283.jsx)("li", { ...rest, className: cn(className, List_default.li) });
|
|
9729
9911
|
ListItem.displayName = "ListItem";
|
|
9730
9912
|
|
|
9731
9913
|
// src/components/LocalMessage/LocalMessage.tsx
|
|
@@ -9750,7 +9932,7 @@ var LocalMessage_default = {
|
|
|
9750
9932
|
};
|
|
9751
9933
|
|
|
9752
9934
|
// src/components/LocalMessage/LocalMessage.tsx
|
|
9753
|
-
var
|
|
9935
|
+
var import_jsx_runtime284 = require("react/jsx-runtime");
|
|
9754
9936
|
var icons2 = {
|
|
9755
9937
|
info: InfoIcon,
|
|
9756
9938
|
danger: ErrorIcon,
|
|
@@ -9774,9 +9956,9 @@ var LocalMessage = ({
|
|
|
9774
9956
|
const { t } = useTranslation();
|
|
9775
9957
|
const [isClosed, setClosed] = (0, import_react68.useState)(false);
|
|
9776
9958
|
if (isClosed) {
|
|
9777
|
-
return /* @__PURE__ */ (0,
|
|
9959
|
+
return /* @__PURE__ */ (0, import_jsx_runtime284.jsx)(import_jsx_runtime284.Fragment, {});
|
|
9778
9960
|
}
|
|
9779
|
-
return /* @__PURE__ */ (0,
|
|
9961
|
+
return /* @__PURE__ */ (0, import_jsx_runtime284.jsxs)(
|
|
9780
9962
|
Box,
|
|
9781
9963
|
{
|
|
9782
9964
|
...getBaseHTMLProps(
|
|
@@ -9797,15 +9979,15 @@ var LocalMessage = ({
|
|
|
9797
9979
|
padding: "x0.75 x0.75 x0.75 x0.5",
|
|
9798
9980
|
gap: "x0.5",
|
|
9799
9981
|
children: [
|
|
9800
|
-
/* @__PURE__ */ (0,
|
|
9982
|
+
/* @__PURE__ */ (0, import_jsx_runtime284.jsx)(
|
|
9801
9983
|
Icon,
|
|
9802
9984
|
{
|
|
9803
9985
|
icon: icons2[purpose],
|
|
9804
9986
|
className: cn(LocalMessage_default.icon, LocalMessage_default.container__icon)
|
|
9805
9987
|
}
|
|
9806
9988
|
),
|
|
9807
|
-
/* @__PURE__ */ (0,
|
|
9808
|
-
closable && /* @__PURE__ */ (0,
|
|
9989
|
+
/* @__PURE__ */ (0, import_jsx_runtime284.jsx)("div", { className: LocalMessage_default.container__text, children: children != null ? children : /* @__PURE__ */ (0, import_jsx_runtime284.jsx)("span", { children: message }) }),
|
|
9990
|
+
closable && /* @__PURE__ */ (0, import_jsx_runtime284.jsx)(
|
|
9809
9991
|
Button,
|
|
9810
9992
|
{
|
|
9811
9993
|
icon: CloseIcon,
|
|
@@ -9840,7 +10022,7 @@ var Modal_default = {
|
|
|
9840
10022
|
};
|
|
9841
10023
|
|
|
9842
10024
|
// src/components/Modal/Modal.tsx
|
|
9843
|
-
var
|
|
10025
|
+
var import_jsx_runtime285 = require("react/jsx-runtime");
|
|
9844
10026
|
var Modal = ({
|
|
9845
10027
|
isOpen = false,
|
|
9846
10028
|
parentElement,
|
|
@@ -9891,14 +10073,14 @@ var Modal = ({
|
|
|
9891
10073
|
useOnKeyDown(["Escape", "Esc"], () => handleClose());
|
|
9892
10074
|
const hasTransitionedIn = useMountTransition(isOpen, 200);
|
|
9893
10075
|
return (isOpen || hasTransitionedIn) && portalTarget ? (0, import_react_dom4.createPortal)(
|
|
9894
|
-
/* @__PURE__ */ (0,
|
|
10076
|
+
/* @__PURE__ */ (0, import_jsx_runtime285.jsx)(
|
|
9895
10077
|
Backdrop,
|
|
9896
10078
|
{
|
|
9897
10079
|
zIndex: "modal",
|
|
9898
10080
|
isMounted: isOpen && hasTransitionedIn,
|
|
9899
10081
|
ref: backdropRef,
|
|
9900
10082
|
onClick: onBackdropClick,
|
|
9901
|
-
children: /* @__PURE__ */ (0,
|
|
10083
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime285.jsxs)(
|
|
9902
10084
|
Paper,
|
|
9903
10085
|
{
|
|
9904
10086
|
display: "flex",
|
|
@@ -9925,7 +10107,7 @@ var Modal = ({
|
|
|
9925
10107
|
id: modalId,
|
|
9926
10108
|
elevation: 4,
|
|
9927
10109
|
children: [
|
|
9928
|
-
/* @__PURE__ */ (0,
|
|
10110
|
+
/* @__PURE__ */ (0, import_jsx_runtime285.jsxs)(
|
|
9929
10111
|
HStack,
|
|
9930
10112
|
{
|
|
9931
10113
|
paddingBlock: "0 x0.75",
|
|
@@ -9935,8 +10117,8 @@ var Modal = ({
|
|
|
9935
10117
|
width: "100%",
|
|
9936
10118
|
className: Modal_default["header-container"],
|
|
9937
10119
|
children: [
|
|
9938
|
-
!!header && /* @__PURE__ */ (0,
|
|
9939
|
-
onClose && /* @__PURE__ */ (0,
|
|
10120
|
+
!!header && /* @__PURE__ */ (0, import_jsx_runtime285.jsx)("div", { id: headerId, children: typeof header === "string" ? /* @__PURE__ */ (0, import_jsx_runtime285.jsx)(Heading, { level: 2, typographyType: "headingLarge", children: header }) : header }),
|
|
10121
|
+
onClose && /* @__PURE__ */ (0, import_jsx_runtime285.jsx)(
|
|
9940
10122
|
Button,
|
|
9941
10123
|
{
|
|
9942
10124
|
size: "small",
|
|
@@ -9950,7 +10132,7 @@ var Modal = ({
|
|
|
9950
10132
|
]
|
|
9951
10133
|
}
|
|
9952
10134
|
),
|
|
9953
|
-
/* @__PURE__ */ (0,
|
|
10135
|
+
/* @__PURE__ */ (0, import_jsx_runtime285.jsx)(Box, { display: "grid", gap: "x1", children })
|
|
9954
10136
|
]
|
|
9955
10137
|
}
|
|
9956
10138
|
)
|
|
@@ -9962,7 +10144,7 @@ var Modal = ({
|
|
|
9962
10144
|
Modal.displayName = "Modal";
|
|
9963
10145
|
|
|
9964
10146
|
// src/components/Modal/ModalBody.tsx
|
|
9965
|
-
var
|
|
10147
|
+
var import_jsx_runtime286 = require("react/jsx-runtime");
|
|
9966
10148
|
var ModalBody = ({
|
|
9967
10149
|
children,
|
|
9968
10150
|
id,
|
|
@@ -9972,7 +10154,7 @@ var ModalBody = ({
|
|
|
9972
10154
|
height,
|
|
9973
10155
|
...rest
|
|
9974
10156
|
}) => {
|
|
9975
|
-
return /* @__PURE__ */ (0,
|
|
10157
|
+
return /* @__PURE__ */ (0, import_jsx_runtime286.jsx)(
|
|
9976
10158
|
"div",
|
|
9977
10159
|
{
|
|
9978
10160
|
...getBaseHTMLProps(
|
|
@@ -9994,8 +10176,8 @@ var ModalBody = ({
|
|
|
9994
10176
|
ModalBody.displayName = "ModalBody";
|
|
9995
10177
|
|
|
9996
10178
|
// src/components/Modal/ModalActions.tsx
|
|
9997
|
-
var
|
|
9998
|
-
var ModalActions = (props) => /* @__PURE__ */ (0,
|
|
10179
|
+
var import_jsx_runtime287 = require("react/jsx-runtime");
|
|
10180
|
+
var ModalActions = (props) => /* @__PURE__ */ (0, import_jsx_runtime287.jsx)(Box, { display: "flex", flexWrap: "wrap", gap: "x1", ...props });
|
|
9999
10181
|
ModalActions.displayName = "ModalActions";
|
|
10000
10182
|
|
|
10001
10183
|
// src/components/Pagination/Pagination.tsx
|
|
@@ -10326,7 +10508,7 @@ var getCustomStyles = (size2, hasError, hasIcon, isReadOnly) => ({
|
|
|
10326
10508
|
// src/components/Select/SelectComponents.tsx
|
|
10327
10509
|
var import_react70 = __toESM(require("react"));
|
|
10328
10510
|
var import_react_select = require("react-select");
|
|
10329
|
-
var
|
|
10511
|
+
var import_jsx_runtime288 = require("react/jsx-runtime");
|
|
10330
10512
|
var {
|
|
10331
10513
|
Option,
|
|
10332
10514
|
NoOptionsMessage,
|
|
@@ -10349,30 +10531,30 @@ var getIndicatorIconSize = (componentSize) => {
|
|
|
10349
10531
|
};
|
|
10350
10532
|
var DDSOption = ({
|
|
10351
10533
|
...props
|
|
10352
|
-
}) => /* @__PURE__ */ (0,
|
|
10353
|
-
props.isSelected && /* @__PURE__ */ (0,
|
|
10534
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime288.jsxs)(Option, { ...props, children: [
|
|
10535
|
+
props.isSelected && /* @__PURE__ */ (0, import_jsx_runtime288.jsx)(Icon, { icon: CheckIcon, iconSize: "small" }),
|
|
10354
10536
|
props.children
|
|
10355
10537
|
] });
|
|
10356
|
-
var CustomOption = (props) => /* @__PURE__ */ (0,
|
|
10538
|
+
var CustomOption = (props) => /* @__PURE__ */ (0, import_jsx_runtime288.jsx)(Option, { ...props, children: import_react70.default.createElement(props.customElement, props) });
|
|
10357
10539
|
var CustomSingleValue = ({
|
|
10358
10540
|
id,
|
|
10359
10541
|
Element,
|
|
10360
10542
|
...props
|
|
10361
|
-
}) => /* @__PURE__ */ (0,
|
|
10362
|
-
var DDSNoOptionsMessage = (props) => /* @__PURE__ */ (0,
|
|
10543
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime288.jsx)(SingleValue, { ...props, children: /* @__PURE__ */ (0, import_jsx_runtime288.jsx)("div", { id, className: Select_default["inner-single-value"], children: Element ? /* @__PURE__ */ (0, import_jsx_runtime288.jsx)(Element, { ...props }) : props.children }) });
|
|
10544
|
+
var DDSNoOptionsMessage = (props) => /* @__PURE__ */ (0, import_jsx_runtime288.jsx)(NoOptionsMessage, { ...props, children: "Ingen treff" });
|
|
10363
10545
|
var DDSClearIndicator = ({
|
|
10364
10546
|
size: size2,
|
|
10365
10547
|
...props
|
|
10366
|
-
}) => /* @__PURE__ */ (0,
|
|
10367
|
-
var DDSMultiValueRemove = (props) => /* @__PURE__ */ (0,
|
|
10548
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime288.jsx)(ClearIndicator, { ...props, children: /* @__PURE__ */ (0, import_jsx_runtime288.jsx)(Icon, { icon: CloseSmallIcon, iconSize: getIndicatorIconSize(size2) }) });
|
|
10549
|
+
var DDSMultiValueRemove = (props) => /* @__PURE__ */ (0, import_jsx_runtime288.jsx)(MultiValueRemove, { ...props, children: /* @__PURE__ */ (0, import_jsx_runtime288.jsx)(Icon, { icon: CloseSmallIcon, iconSize: "small" }) });
|
|
10368
10550
|
var DDSDropdownIndicator = (props) => {
|
|
10369
10551
|
const { className, componentSize, ...rest } = props;
|
|
10370
|
-
return /* @__PURE__ */ (0,
|
|
10552
|
+
return /* @__PURE__ */ (0, import_jsx_runtime288.jsx)(
|
|
10371
10553
|
DropdownIndicator,
|
|
10372
10554
|
{
|
|
10373
10555
|
...rest,
|
|
10374
10556
|
className: cn(className, Select_default["dropdown-indicator"]),
|
|
10375
|
-
children: /* @__PURE__ */ (0,
|
|
10557
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime288.jsx)(
|
|
10376
10558
|
Icon,
|
|
10377
10559
|
{
|
|
10378
10560
|
icon: ChevronDownIcon,
|
|
@@ -10386,7 +10568,7 @@ var DDSInput = ({
|
|
|
10386
10568
|
ariaInvalid,
|
|
10387
10569
|
ariaDescribedby,
|
|
10388
10570
|
...props
|
|
10389
|
-
}) => /* @__PURE__ */ (0,
|
|
10571
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime288.jsx)(
|
|
10390
10572
|
Input2,
|
|
10391
10573
|
{
|
|
10392
10574
|
...props,
|
|
@@ -10405,7 +10587,7 @@ function DDSControl(props) {
|
|
|
10405
10587
|
innerProps,
|
|
10406
10588
|
...rest
|
|
10407
10589
|
} = props;
|
|
10408
|
-
return /* @__PURE__ */ (0,
|
|
10590
|
+
return /* @__PURE__ */ (0, import_jsx_runtime288.jsxs)(
|
|
10409
10591
|
Control,
|
|
10410
10592
|
{
|
|
10411
10593
|
...rest,
|
|
@@ -10420,7 +10602,7 @@ function DDSControl(props) {
|
|
|
10420
10602
|
readOnly && Select_default["control--readonly"]
|
|
10421
10603
|
),
|
|
10422
10604
|
children: [
|
|
10423
|
-
icon && /* @__PURE__ */ (0,
|
|
10605
|
+
icon && /* @__PURE__ */ (0, import_jsx_runtime288.jsx)(
|
|
10424
10606
|
Icon,
|
|
10425
10607
|
{
|
|
10426
10608
|
icon,
|
|
@@ -10438,7 +10620,7 @@ function DDSControl(props) {
|
|
|
10438
10620
|
}
|
|
10439
10621
|
|
|
10440
10622
|
// src/components/Select/Select.tsx
|
|
10441
|
-
var
|
|
10623
|
+
var import_jsx_runtime289 = require("react/jsx-runtime");
|
|
10442
10624
|
function Select({
|
|
10443
10625
|
id,
|
|
10444
10626
|
label,
|
|
@@ -10488,7 +10670,7 @@ function Select({
|
|
|
10488
10670
|
componentSize === "xsmall" && "var(--dds-input-default-width-xsmall)"
|
|
10489
10671
|
);
|
|
10490
10672
|
const customInput = (0, import_react71.useCallback)(
|
|
10491
|
-
(props) => /* @__PURE__ */ (0,
|
|
10673
|
+
(props) => /* @__PURE__ */ (0, import_jsx_runtime289.jsx)(
|
|
10492
10674
|
DDSInput,
|
|
10493
10675
|
{
|
|
10494
10676
|
...props,
|
|
@@ -10506,7 +10688,7 @@ function Select({
|
|
|
10506
10688
|
[]
|
|
10507
10689
|
);
|
|
10508
10690
|
const customSingleValue = (0, import_react71.useCallback)(
|
|
10509
|
-
(props) => /* @__PURE__ */ (0,
|
|
10691
|
+
(props) => /* @__PURE__ */ (0, import_jsx_runtime289.jsx)(
|
|
10510
10692
|
CustomSingleValue,
|
|
10511
10693
|
{
|
|
10512
10694
|
...props,
|
|
@@ -10517,15 +10699,15 @@ function Select({
|
|
|
10517
10699
|
[]
|
|
10518
10700
|
);
|
|
10519
10701
|
const customClearIndicator = (0, import_react71.useCallback)(
|
|
10520
|
-
(props) => /* @__PURE__ */ (0,
|
|
10702
|
+
(props) => /* @__PURE__ */ (0, import_jsx_runtime289.jsx)(DDSClearIndicator, { ...props, size: componentSize }),
|
|
10521
10703
|
[componentSize]
|
|
10522
10704
|
);
|
|
10523
10705
|
const customDropdownIndicator = (0, import_react71.useCallback)(
|
|
10524
|
-
(props) => /* @__PURE__ */ (0,
|
|
10706
|
+
(props) => /* @__PURE__ */ (0, import_jsx_runtime289.jsx)(DDSDropdownIndicator, { ...props, componentSize }),
|
|
10525
10707
|
[componentSize]
|
|
10526
10708
|
);
|
|
10527
10709
|
const customControl = (0, import_react71.useCallback)(
|
|
10528
|
-
(props) => /* @__PURE__ */ (0,
|
|
10710
|
+
(props) => /* @__PURE__ */ (0, import_jsx_runtime289.jsx)(
|
|
10529
10711
|
DDSControl,
|
|
10530
10712
|
{
|
|
10531
10713
|
...props,
|
|
@@ -10540,9 +10722,9 @@ function Select({
|
|
|
10540
10722
|
const customOptionComponent = (0, import_react71.useCallback)(
|
|
10541
10723
|
(props) => {
|
|
10542
10724
|
if (customOptionElement) {
|
|
10543
|
-
return /* @__PURE__ */ (0,
|
|
10725
|
+
return /* @__PURE__ */ (0, import_jsx_runtime289.jsx)(CustomOption, { ...props, customElement: customOptionElement });
|
|
10544
10726
|
} else {
|
|
10545
|
-
return /* @__PURE__ */ (0,
|
|
10727
|
+
return /* @__PURE__ */ (0, import_jsx_runtime289.jsx)(DDSOption, { ...props });
|
|
10546
10728
|
}
|
|
10547
10729
|
},
|
|
10548
10730
|
[customOptionElement, componentSize]
|
|
@@ -10586,7 +10768,7 @@ function Select({
|
|
|
10586
10768
|
openMenuOnClick: readOnly ? false : openMenuOnClick ? openMenuOnClick : void 0,
|
|
10587
10769
|
...rest
|
|
10588
10770
|
};
|
|
10589
|
-
return /* @__PURE__ */ (0,
|
|
10771
|
+
return /* @__PURE__ */ (0, import_jsx_runtime289.jsxs)(
|
|
10590
10772
|
Box,
|
|
10591
10773
|
{
|
|
10592
10774
|
width: inputWidth,
|
|
@@ -10606,7 +10788,7 @@ function Select({
|
|
|
10606
10788
|
readOnly,
|
|
10607
10789
|
afterLabelContent
|
|
10608
10790
|
}),
|
|
10609
|
-
/* @__PURE__ */ (0,
|
|
10791
|
+
/* @__PURE__ */ (0, import_jsx_runtime289.jsx)(import_react_select2.default, { ...reactSelectProps, ref }),
|
|
10610
10792
|
renderInputMessage(tip, tipId, errorMessage, errorMessageId)
|
|
10611
10793
|
]
|
|
10612
10794
|
}
|
|
@@ -10633,7 +10815,7 @@ var NativeSelect_default = {
|
|
|
10633
10815
|
};
|
|
10634
10816
|
|
|
10635
10817
|
// src/components/Select/NativeSelect/NativeSelect.tsx
|
|
10636
|
-
var
|
|
10818
|
+
var import_jsx_runtime290 = require("react/jsx-runtime");
|
|
10637
10819
|
var NativeSelect = ({
|
|
10638
10820
|
ref,
|
|
10639
10821
|
id,
|
|
@@ -10700,7 +10882,7 @@ var NativeSelect = ({
|
|
|
10700
10882
|
};
|
|
10701
10883
|
const iconSize = componentSize === "medium" ? "medium" : "small";
|
|
10702
10884
|
const showClearButton = clearable && hasValue && !readOnly && !rest.disabled;
|
|
10703
|
-
return /* @__PURE__ */ (0,
|
|
10885
|
+
return /* @__PURE__ */ (0, import_jsx_runtime290.jsxs)("div", { className, style, children: [
|
|
10704
10886
|
renderLabel({
|
|
10705
10887
|
label,
|
|
10706
10888
|
htmlFor: uniqueId,
|
|
@@ -10708,8 +10890,8 @@ var NativeSelect = ({
|
|
|
10708
10890
|
readOnly,
|
|
10709
10891
|
afterLabelContent
|
|
10710
10892
|
}),
|
|
10711
|
-
/* @__PURE__ */ (0,
|
|
10712
|
-
/* @__PURE__ */ (0,
|
|
10893
|
+
/* @__PURE__ */ (0, import_jsx_runtime290.jsxs)(Box, { position: "relative", width: inputWidth, children: [
|
|
10894
|
+
/* @__PURE__ */ (0, import_jsx_runtime290.jsx)(
|
|
10713
10895
|
"select",
|
|
10714
10896
|
{
|
|
10715
10897
|
ref: useCombinedRef(ref, selectRef),
|
|
@@ -10743,7 +10925,7 @@ var NativeSelect = ({
|
|
|
10743
10925
|
children
|
|
10744
10926
|
}
|
|
10745
10927
|
),
|
|
10746
|
-
showClearButton && /* @__PURE__ */ (0,
|
|
10928
|
+
showClearButton && /* @__PURE__ */ (0, import_jsx_runtime290.jsx)(
|
|
10747
10929
|
ClearButton,
|
|
10748
10930
|
{
|
|
10749
10931
|
"aria-label": t(commonTexts.clearSelect),
|
|
@@ -10752,7 +10934,7 @@ var NativeSelect = ({
|
|
|
10752
10934
|
className: NativeSelect_default[`clear-button--${iconSize}`]
|
|
10753
10935
|
}
|
|
10754
10936
|
),
|
|
10755
|
-
!multiple && /* @__PURE__ */ (0,
|
|
10937
|
+
!multiple && /* @__PURE__ */ (0, import_jsx_runtime290.jsx)(
|
|
10756
10938
|
Icon,
|
|
10757
10939
|
{
|
|
10758
10940
|
icon: ChevronDownIcon,
|
|
@@ -10768,14 +10950,14 @@ var NativeSelectPlaceholder = ({
|
|
|
10768
10950
|
children = "-- Velg fra listen --",
|
|
10769
10951
|
value,
|
|
10770
10952
|
...rest
|
|
10771
|
-
}) => /* @__PURE__ */ (0,
|
|
10953
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime290.jsx)("option", { value: value != null ? value : "", selected: true, ...rest, children });
|
|
10772
10954
|
NativeSelectPlaceholder.displayName = "NativeSelectPlaceholder";
|
|
10773
10955
|
|
|
10774
10956
|
// src/components/Select/utils.ts
|
|
10775
10957
|
var createSelectOptions = (...args) => args.map((v) => ({ label: v, value: v }));
|
|
10776
10958
|
|
|
10777
10959
|
// src/components/Pagination/Pagination.tsx
|
|
10778
|
-
var
|
|
10960
|
+
var import_jsx_runtime291 = require("react/jsx-runtime");
|
|
10779
10961
|
var Pagination = ({
|
|
10780
10962
|
itemsAmount,
|
|
10781
10963
|
defaultItemsPerPage = 10,
|
|
@@ -10784,12 +10966,7 @@ var Pagination = ({
|
|
|
10784
10966
|
withPagination = true,
|
|
10785
10967
|
withCounter,
|
|
10786
10968
|
withSelect,
|
|
10787
|
-
selectOptions
|
|
10788
|
-
{ label: "10", value: 10 },
|
|
10789
|
-
{ label: "25", value: 25 },
|
|
10790
|
-
{ label: "50", value: 50 },
|
|
10791
|
-
{ label: "Alle", value: itemsAmount }
|
|
10792
|
-
],
|
|
10969
|
+
selectOptions,
|
|
10793
10970
|
smallScreenBreakpoint,
|
|
10794
10971
|
onChange,
|
|
10795
10972
|
onSelectOptionChange,
|
|
@@ -10800,7 +10977,13 @@ var Pagination = ({
|
|
|
10800
10977
|
...rest
|
|
10801
10978
|
}) => {
|
|
10802
10979
|
const { t } = useTranslation();
|
|
10803
|
-
|
|
10980
|
+
const tSelectOptions = selectOptions && selectOptions.length > 0 ? selectOptions : [
|
|
10981
|
+
{ label: "10", value: 10 },
|
|
10982
|
+
{ label: "25", value: 25 },
|
|
10983
|
+
{ label: "50", value: 50 },
|
|
10984
|
+
{ label: t(texts21.all), value: itemsAmount }
|
|
10985
|
+
];
|
|
10986
|
+
if (withSelect && !tSelectOptions.some((o) => o.value === defaultItemsPerPage)) {
|
|
10804
10987
|
console.warn(
|
|
10805
10988
|
`[Pagination] defaultItemsPerPage prop value (${defaultItemsPerPage}) is not included in customOptions prop. Please add it to ensure it appears in the dropdown.`
|
|
10806
10989
|
);
|
|
@@ -10828,7 +11011,7 @@ var Pagination = ({
|
|
|
10828
11011
|
};
|
|
10829
11012
|
const listItems = items.length > 0 ? items.map((item, i) => {
|
|
10830
11013
|
const isActive = item === activePage;
|
|
10831
|
-
return /* @__PURE__ */ (0,
|
|
11014
|
+
return /* @__PURE__ */ (0, import_jsx_runtime291.jsx)("li", { className: Pagination_default.list__item, children: item !== "truncator" && typeof item === "number" ? /* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
|
|
10832
11015
|
Button,
|
|
10833
11016
|
{
|
|
10834
11017
|
purpose: isActive ? "primary" : "secondary",
|
|
@@ -10836,10 +11019,10 @@ var Pagination = ({
|
|
|
10836
11019
|
onClick: (event) => {
|
|
10837
11020
|
onPageChange(event, item);
|
|
10838
11021
|
},
|
|
10839
|
-
"aria-label": isActive ? t(
|
|
11022
|
+
"aria-label": isActive ? t(texts21.currentPage(item)) : t(texts21.page(item)),
|
|
10840
11023
|
children: item
|
|
10841
11024
|
}
|
|
10842
|
-
) : /* @__PURE__ */ (0,
|
|
11025
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
|
|
10843
11026
|
Icon,
|
|
10844
11027
|
{
|
|
10845
11028
|
icon: MoreHorizontalIcon,
|
|
@@ -10847,7 +11030,7 @@ var Pagination = ({
|
|
|
10847
11030
|
}
|
|
10848
11031
|
) }, `pagination-item-${i}`);
|
|
10849
11032
|
}) : void 0;
|
|
10850
|
-
const previousPageButton = /* @__PURE__ */ (0,
|
|
11033
|
+
const previousPageButton = /* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
|
|
10851
11034
|
Button,
|
|
10852
11035
|
{
|
|
10853
11036
|
purpose: "secondary",
|
|
@@ -10856,10 +11039,10 @@ var Pagination = ({
|
|
|
10856
11039
|
onClick: (event) => {
|
|
10857
11040
|
onPageChange(event, activePage - 1);
|
|
10858
11041
|
},
|
|
10859
|
-
"aria-label": t(
|
|
11042
|
+
"aria-label": t(texts21.previousPage)
|
|
10860
11043
|
}
|
|
10861
11044
|
);
|
|
10862
|
-
const nextPageButton = /* @__PURE__ */ (0,
|
|
11045
|
+
const nextPageButton = /* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
|
|
10863
11046
|
Button,
|
|
10864
11047
|
{
|
|
10865
11048
|
purpose: "secondary",
|
|
@@ -10868,31 +11051,31 @@ var Pagination = ({
|
|
|
10868
11051
|
onClick: (event) => {
|
|
10869
11052
|
onPageChange(event, activePage + 1);
|
|
10870
11053
|
},
|
|
10871
|
-
"aria-label": t(
|
|
11054
|
+
"aria-label": t(texts21.nextPage)
|
|
10872
11055
|
}
|
|
10873
11056
|
);
|
|
10874
11057
|
const isOnFirstPage = activePage === 1;
|
|
10875
11058
|
const isOnLastPage = activePage === pagesLength;
|
|
10876
|
-
const navigation = withPagination ? /* @__PURE__ */ (0,
|
|
11059
|
+
const navigation = withPagination ? /* @__PURE__ */ (0, import_jsx_runtime291.jsxs)(
|
|
10877
11060
|
Box,
|
|
10878
11061
|
{
|
|
10879
11062
|
as: "nav",
|
|
10880
11063
|
ref,
|
|
10881
|
-
"aria-label": t(
|
|
11064
|
+
"aria-label": t(texts21.pagination),
|
|
10882
11065
|
display: "flex",
|
|
10883
11066
|
alignItems: "center",
|
|
10884
11067
|
...!withSelect && !withCounter && {
|
|
10885
11068
|
...getBaseHTMLProps(id, className, htmlProps, rest)
|
|
10886
11069
|
},
|
|
10887
11070
|
children: [
|
|
10888
|
-
/* @__PURE__ */ (0,
|
|
11071
|
+
/* @__PURE__ */ (0, import_jsx_runtime291.jsxs)(
|
|
10889
11072
|
ShowHide,
|
|
10890
11073
|
{
|
|
10891
11074
|
as: "ol",
|
|
10892
11075
|
hideBelow: smallScreenBreakpoint,
|
|
10893
11076
|
className: Pagination_default.list,
|
|
10894
11077
|
children: [
|
|
10895
|
-
/* @__PURE__ */ (0,
|
|
11078
|
+
/* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
|
|
10896
11079
|
"li",
|
|
10897
11080
|
{
|
|
10898
11081
|
className: cn(
|
|
@@ -10904,7 +11087,7 @@ var Pagination = ({
|
|
|
10904
11087
|
}
|
|
10905
11088
|
),
|
|
10906
11089
|
listItems,
|
|
10907
|
-
/* @__PURE__ */ (0,
|
|
11090
|
+
/* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
|
|
10908
11091
|
"li",
|
|
10909
11092
|
{
|
|
10910
11093
|
className: cn(
|
|
@@ -10918,14 +11101,14 @@ var Pagination = ({
|
|
|
10918
11101
|
]
|
|
10919
11102
|
}
|
|
10920
11103
|
),
|
|
10921
|
-
!!smallScreenBreakpoint && /* @__PURE__ */ (0,
|
|
11104
|
+
!!smallScreenBreakpoint && /* @__PURE__ */ (0, import_jsx_runtime291.jsxs)(
|
|
10922
11105
|
ShowHide,
|
|
10923
11106
|
{
|
|
10924
11107
|
as: "ol",
|
|
10925
11108
|
showBelow: smallScreenBreakpoint,
|
|
10926
11109
|
className: Pagination_default.list,
|
|
10927
11110
|
children: [
|
|
10928
|
-
/* @__PURE__ */ (0,
|
|
11111
|
+
/* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
|
|
10929
11112
|
"li",
|
|
10930
11113
|
{
|
|
10931
11114
|
className: cn(
|
|
@@ -10933,7 +11116,7 @@ var Pagination = ({
|
|
|
10933
11116
|
isOnFirstPage && Pagination_default["list__item--hidden"]
|
|
10934
11117
|
),
|
|
10935
11118
|
"aria-hidden": isOnFirstPage,
|
|
10936
|
-
children: /* @__PURE__ */ (0,
|
|
11119
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
|
|
10937
11120
|
Button,
|
|
10938
11121
|
{
|
|
10939
11122
|
purpose: "secondary",
|
|
@@ -10942,12 +11125,12 @@ var Pagination = ({
|
|
|
10942
11125
|
onClick: (event) => {
|
|
10943
11126
|
onPageChange(event, 1);
|
|
10944
11127
|
},
|
|
10945
|
-
"aria-label": t(
|
|
11128
|
+
"aria-label": t(texts21.firstPage)
|
|
10946
11129
|
}
|
|
10947
11130
|
)
|
|
10948
11131
|
}
|
|
10949
11132
|
),
|
|
10950
|
-
/* @__PURE__ */ (0,
|
|
11133
|
+
/* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
|
|
10951
11134
|
"li",
|
|
10952
11135
|
{
|
|
10953
11136
|
className: cn(
|
|
@@ -10958,7 +11141,7 @@ var Pagination = ({
|
|
|
10958
11141
|
children: previousPageButton
|
|
10959
11142
|
}
|
|
10960
11143
|
),
|
|
10961
|
-
/* @__PURE__ */ (0,
|
|
11144
|
+
/* @__PURE__ */ (0, import_jsx_runtime291.jsx)("li", { className: Pagination_default.list__item, children: /* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
|
|
10962
11145
|
Button,
|
|
10963
11146
|
{
|
|
10964
11147
|
size: "small",
|
|
@@ -10968,7 +11151,7 @@ var Pagination = ({
|
|
|
10968
11151
|
children: activePage
|
|
10969
11152
|
}
|
|
10970
11153
|
) }),
|
|
10971
|
-
/* @__PURE__ */ (0,
|
|
11154
|
+
/* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
|
|
10972
11155
|
"li",
|
|
10973
11156
|
{
|
|
10974
11157
|
className: cn(
|
|
@@ -10979,7 +11162,7 @@ var Pagination = ({
|
|
|
10979
11162
|
children: nextPageButton
|
|
10980
11163
|
}
|
|
10981
11164
|
),
|
|
10982
|
-
/* @__PURE__ */ (0,
|
|
11165
|
+
/* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
|
|
10983
11166
|
"li",
|
|
10984
11167
|
{
|
|
10985
11168
|
className: cn(
|
|
@@ -10987,7 +11170,7 @@ var Pagination = ({
|
|
|
10987
11170
|
isOnLastPage && Pagination_default["list__item--hidden"]
|
|
10988
11171
|
),
|
|
10989
11172
|
"aria-hidden": isOnLastPage,
|
|
10990
|
-
children: /* @__PURE__ */ (0,
|
|
11173
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
|
|
10991
11174
|
Button,
|
|
10992
11175
|
{
|
|
10993
11176
|
purpose: "secondary",
|
|
@@ -10996,7 +11179,7 @@ var Pagination = ({
|
|
|
10996
11179
|
onClick: (event) => {
|
|
10997
11180
|
onPageChange(event, pagesLength);
|
|
10998
11181
|
},
|
|
10999
|
-
"aria-label": t(
|
|
11182
|
+
"aria-label": t(texts21.lastPage)
|
|
11000
11183
|
}
|
|
11001
11184
|
)
|
|
11002
11185
|
}
|
|
@@ -11009,7 +11192,7 @@ var Pagination = ({
|
|
|
11009
11192
|
) : null;
|
|
11010
11193
|
const activePageFirstItem = activePage === 1 ? 1 : activePage * itemsPerPage - itemsPerPage + 1;
|
|
11011
11194
|
const activePageLastItem = activePage === pagesLength ? itemsAmount : activePage * itemsPerPage;
|
|
11012
|
-
return !withCounter && !withSelect ? navigation : /* @__PURE__ */ (0,
|
|
11195
|
+
return !withCounter && !withSelect ? navigation : /* @__PURE__ */ (0, import_jsx_runtime291.jsxs)(
|
|
11013
11196
|
Box,
|
|
11014
11197
|
{
|
|
11015
11198
|
display: "flex",
|
|
@@ -11020,11 +11203,11 @@ var Pagination = ({
|
|
|
11020
11203
|
alignItems: styleUpToBreakpoint("center", smallScreenBreakpoint),
|
|
11021
11204
|
...getBaseHTMLProps(id, className, htmlProps, rest),
|
|
11022
11205
|
children: [
|
|
11023
|
-
/* @__PURE__ */ (0,
|
|
11024
|
-
withSelect && /* @__PURE__ */ (0,
|
|
11206
|
+
/* @__PURE__ */ (0, import_jsx_runtime291.jsxs)("div", { className: Pagination_default.indicators, children: [
|
|
11207
|
+
withSelect && /* @__PURE__ */ (0, import_jsx_runtime291.jsx)(
|
|
11025
11208
|
Select,
|
|
11026
11209
|
{
|
|
11027
|
-
options:
|
|
11210
|
+
options: tSelectOptions,
|
|
11028
11211
|
isSearchable: false,
|
|
11029
11212
|
width: "90px",
|
|
11030
11213
|
defaultValue: {
|
|
@@ -11034,11 +11217,11 @@ var Pagination = ({
|
|
|
11034
11217
|
isClearable: false,
|
|
11035
11218
|
onChange: handleSelectChange,
|
|
11036
11219
|
componentSize: "small",
|
|
11037
|
-
"aria-label": t(
|
|
11220
|
+
"aria-label": t(texts21.itemsPerPage)
|
|
11038
11221
|
}
|
|
11039
11222
|
),
|
|
11040
|
-
withCounter && /* @__PURE__ */ (0,
|
|
11041
|
-
|
|
11223
|
+
withCounter && /* @__PURE__ */ (0, import_jsx_runtime291.jsx)(Paragraph, { children: t(
|
|
11224
|
+
texts21.showsAmountOfTotalItems(
|
|
11042
11225
|
activePageFirstItem,
|
|
11043
11226
|
activePageLastItem,
|
|
11044
11227
|
itemsAmount
|
|
@@ -11051,61 +11234,77 @@ var Pagination = ({
|
|
|
11051
11234
|
);
|
|
11052
11235
|
};
|
|
11053
11236
|
Pagination.displayName = "Pagination";
|
|
11054
|
-
var
|
|
11237
|
+
var texts21 = createTexts({
|
|
11055
11238
|
pagination: {
|
|
11056
11239
|
nb: "Paginering",
|
|
11057
11240
|
no: "Paginering",
|
|
11058
11241
|
nn: "Paginering",
|
|
11059
|
-
en: "Pagination"
|
|
11242
|
+
en: "Pagination",
|
|
11243
|
+
se: "Pagineren"
|
|
11060
11244
|
},
|
|
11061
11245
|
itemsPerPage: {
|
|
11062
11246
|
nb: "Elementer per side",
|
|
11063
11247
|
no: "Elementer per side",
|
|
11064
11248
|
nn: "Element per side",
|
|
11065
|
-
en: "Items per page"
|
|
11249
|
+
en: "Items per page",
|
|
11250
|
+
se: "Elementat juohki siidui"
|
|
11066
11251
|
},
|
|
11067
11252
|
nextPage: {
|
|
11068
11253
|
nb: "Neste side",
|
|
11069
11254
|
no: "Neste side",
|
|
11070
11255
|
nn: "Neste side",
|
|
11071
|
-
en: "Next page"
|
|
11256
|
+
en: "Next page",
|
|
11257
|
+
se: "Boahte siidu"
|
|
11072
11258
|
},
|
|
11073
11259
|
previousPage: {
|
|
11074
11260
|
nb: "Forrige side",
|
|
11075
11261
|
no: "Forrige side",
|
|
11076
11262
|
nn: "F\xF8rre side",
|
|
11077
|
-
en: "Previous page"
|
|
11263
|
+
en: "Previous page",
|
|
11264
|
+
se: "Ovddit siidu"
|
|
11078
11265
|
},
|
|
11079
11266
|
firstPage: {
|
|
11080
11267
|
nb: "F\xF8rste side",
|
|
11081
11268
|
no: "F\xF8rste side",
|
|
11082
11269
|
nn: "Fyrste side",
|
|
11083
|
-
en: "First page"
|
|
11270
|
+
en: "First page",
|
|
11271
|
+
se: "Vustta\u0161 siidu"
|
|
11084
11272
|
},
|
|
11085
11273
|
lastPage: {
|
|
11086
11274
|
nb: "Siste side",
|
|
11087
11275
|
no: "Siste side",
|
|
11088
11276
|
nn: "Siste side",
|
|
11089
|
-
en: "Last page"
|
|
11277
|
+
en: "Last page",
|
|
11278
|
+
se: "Ma\u014Bimu\u0161 siidu"
|
|
11090
11279
|
},
|
|
11091
11280
|
currentPage: (page) => ({
|
|
11092
11281
|
nb: `N\xE5v\xE6rende side (${page})`,
|
|
11093
11282
|
no: `N\xE5v\xE6rende side (${page})`,
|
|
11094
11283
|
nn: `Noverande side (${page})`,
|
|
11095
|
-
en: `Current page (${page})
|
|
11284
|
+
en: `Current page (${page})`,
|
|
11285
|
+
se: `D\xE1la siidu (${page})`
|
|
11096
11286
|
}),
|
|
11097
11287
|
page: (page) => ({
|
|
11098
11288
|
nb: `Side ${page}`,
|
|
11099
11289
|
no: `Side ${page}`,
|
|
11100
11290
|
nn: `Side ${page}`,
|
|
11101
|
-
en: `Page ${page}
|
|
11291
|
+
en: `Page ${page}`,
|
|
11292
|
+
se: `Siidu ${page}`
|
|
11102
11293
|
}),
|
|
11103
11294
|
showsAmountOfTotalItems: (first, last, total) => ({
|
|
11104
11295
|
nb: `Viser ${first}-${last} av ${total}`,
|
|
11105
11296
|
no: `Viser ${first}-${last} av ${total}`,
|
|
11106
11297
|
nn: `Viser ${first}-${last} av ${total}`,
|
|
11107
|
-
en: `Shows ${first}-${last} of ${total}
|
|
11108
|
-
|
|
11298
|
+
en: `Shows ${first}-${last} of ${total}`,
|
|
11299
|
+
se: `\u010C\xE1jeha ${first}-${last} ${total} gaskkas`
|
|
11300
|
+
}),
|
|
11301
|
+
all: {
|
|
11302
|
+
nb: "Alle",
|
|
11303
|
+
no: "Alle",
|
|
11304
|
+
nn: "Alle",
|
|
11305
|
+
en: "All",
|
|
11306
|
+
se: "Buot"
|
|
11307
|
+
}
|
|
11109
11308
|
});
|
|
11110
11309
|
|
|
11111
11310
|
// src/components/PhoneInput/PhoneInput.tsx
|
|
@@ -11509,7 +11708,7 @@ var PhoneInput_default = {
|
|
|
11509
11708
|
};
|
|
11510
11709
|
|
|
11511
11710
|
// src/components/PhoneInput/PhoneInput.tsx
|
|
11512
|
-
var
|
|
11711
|
+
var import_jsx_runtime292 = require("react/jsx-runtime");
|
|
11513
11712
|
var prioritizedCountries = [
|
|
11514
11713
|
COUNTRIES.NO,
|
|
11515
11714
|
COUNTRIES.SE,
|
|
@@ -11556,21 +11755,21 @@ var PhoneInput = ({
|
|
|
11556
11755
|
className,
|
|
11557
11756
|
style,
|
|
11558
11757
|
value,
|
|
11559
|
-
selectLabel
|
|
11758
|
+
selectLabel,
|
|
11560
11759
|
selectRef,
|
|
11561
11760
|
onChange,
|
|
11562
11761
|
defaultValue,
|
|
11563
11762
|
"aria-required": ariaRequired,
|
|
11564
11763
|
"aria-describedby": ariaDescribedby,
|
|
11565
|
-
groupLabel
|
|
11764
|
+
groupLabel,
|
|
11566
11765
|
afterLabelContent,
|
|
11567
11766
|
ref,
|
|
11568
11767
|
...props
|
|
11569
11768
|
}) => {
|
|
11570
11769
|
var _a;
|
|
11571
11770
|
const { t } = useTranslation();
|
|
11572
|
-
const tGroupLabel = groupLabel != null ? groupLabel : t(
|
|
11573
|
-
const tSelectLabel = selectLabel != null ? selectLabel : t(
|
|
11771
|
+
const tGroupLabel = groupLabel != null ? groupLabel : t(texts22.countryCodeAndPhoneNumber);
|
|
11772
|
+
const tSelectLabel = selectLabel != null ? selectLabel : t(texts22.countryCode);
|
|
11574
11773
|
const generatedId = (0, import_react74.useId)();
|
|
11575
11774
|
const uniqueId = (_a = props.id) != null ? _a : generatedId;
|
|
11576
11775
|
const phoneInputId = `${uniqueId}-phone-input`;
|
|
@@ -11647,7 +11846,7 @@ var PhoneInput = ({
|
|
|
11647
11846
|
const showRequiredStyling = !!(required || ariaRequired);
|
|
11648
11847
|
const bp = props.smallScreenBreakpoint;
|
|
11649
11848
|
const widthDefault = componentSize === "xsmall" && "var(--dds-input-default-width-xsmall)";
|
|
11650
|
-
return /* @__PURE__ */ (0,
|
|
11849
|
+
return /* @__PURE__ */ (0, import_jsx_runtime292.jsxs)("div", { className: cn(className, Input_default.container), style, children: [
|
|
11651
11850
|
renderLabel({
|
|
11652
11851
|
label,
|
|
11653
11852
|
htmlFor: phoneNumberId,
|
|
@@ -11655,7 +11854,7 @@ var PhoneInput = ({
|
|
|
11655
11854
|
readOnly,
|
|
11656
11855
|
afterLabelContent
|
|
11657
11856
|
}),
|
|
11658
|
-
/* @__PURE__ */ (0,
|
|
11857
|
+
/* @__PURE__ */ (0, import_jsx_runtime292.jsxs)(
|
|
11659
11858
|
Box,
|
|
11660
11859
|
{
|
|
11661
11860
|
display: "flex",
|
|
@@ -11668,8 +11867,8 @@ var PhoneInput = ({
|
|
|
11668
11867
|
role: "group",
|
|
11669
11868
|
"aria-label": tGroupLabel,
|
|
11670
11869
|
children: [
|
|
11671
|
-
/* @__PURE__ */ (0,
|
|
11672
|
-
/* @__PURE__ */ (0,
|
|
11870
|
+
/* @__PURE__ */ (0, import_jsx_runtime292.jsx)("label", { className: utilStyles_default["visually-hidden"], htmlFor: selectId, children: tSelectLabel }),
|
|
11871
|
+
/* @__PURE__ */ (0, import_jsx_runtime292.jsx)(
|
|
11673
11872
|
NativeSelect,
|
|
11674
11873
|
{
|
|
11675
11874
|
width: styleUpToBreakpoint(
|
|
@@ -11690,11 +11889,11 @@ var PhoneInput = ({
|
|
|
11690
11889
|
hasTip ? tipId : void 0,
|
|
11691
11890
|
ariaDescribedby
|
|
11692
11891
|
]),
|
|
11693
|
-
children: countryOptions.map((item, index) => /* @__PURE__ */ (0,
|
|
11892
|
+
children: countryOptions.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime292.jsx)("option", { value: item.countryCode, children: item.label }, index))
|
|
11694
11893
|
}
|
|
11695
11894
|
),
|
|
11696
|
-
/* @__PURE__ */ (0,
|
|
11697
|
-
/* @__PURE__ */ (0,
|
|
11895
|
+
/* @__PURE__ */ (0, import_jsx_runtime292.jsxs)(Box, { width: "100%", className: Input_default["input-group"], children: [
|
|
11896
|
+
/* @__PURE__ */ (0, import_jsx_runtime292.jsx)(
|
|
11698
11897
|
"span",
|
|
11699
11898
|
{
|
|
11700
11899
|
className: cn(
|
|
@@ -11706,7 +11905,7 @@ var PhoneInput = ({
|
|
|
11706
11905
|
children: callingCode
|
|
11707
11906
|
}
|
|
11708
11907
|
),
|
|
11709
|
-
/* @__PURE__ */ (0,
|
|
11908
|
+
/* @__PURE__ */ (0, import_jsx_runtime292.jsx)(
|
|
11710
11909
|
Box,
|
|
11711
11910
|
{
|
|
11712
11911
|
as: StatefulInput,
|
|
@@ -11744,18 +11943,20 @@ var getCallingCode = (s) => {
|
|
|
11744
11943
|
var _a;
|
|
11745
11944
|
return (_a = s.substring(s.indexOf("+"), s.length)) != null ? _a : "";
|
|
11746
11945
|
};
|
|
11747
|
-
var
|
|
11946
|
+
var texts22 = createTexts({
|
|
11748
11947
|
countryCode: {
|
|
11749
11948
|
nb: "Landskode",
|
|
11750
11949
|
no: "Landskode",
|
|
11751
11950
|
nn: "Landskode",
|
|
11752
|
-
en: "Country code"
|
|
11951
|
+
en: "Country code",
|
|
11952
|
+
se: "Riikkakoda"
|
|
11753
11953
|
},
|
|
11754
11954
|
countryCodeAndPhoneNumber: {
|
|
11755
11955
|
nb: "Landskode og telefonnummer",
|
|
11756
11956
|
no: "Landskode og telefonnummer",
|
|
11757
11957
|
nn: "Landskode og telefonnummer",
|
|
11758
|
-
en: "Country code and phone number"
|
|
11958
|
+
en: "Country code and phone number",
|
|
11959
|
+
se: "Riikkakoda ja telefovnndanummir"
|
|
11759
11960
|
}
|
|
11760
11961
|
});
|
|
11761
11962
|
|
|
@@ -11777,7 +11978,7 @@ var PopoverContext = (0, import_react75.createContext)({});
|
|
|
11777
11978
|
var usePopoverContext = () => (0, import_react75.useContext)(PopoverContext);
|
|
11778
11979
|
|
|
11779
11980
|
// src/components/Popover/Popover.tsx
|
|
11780
|
-
var
|
|
11981
|
+
var import_jsx_runtime293 = require("react/jsx-runtime");
|
|
11781
11982
|
var Popover = ({
|
|
11782
11983
|
id,
|
|
11783
11984
|
header,
|
|
@@ -11865,7 +12066,7 @@ var Popover = ({
|
|
|
11865
12066
|
});
|
|
11866
12067
|
const hasTitle = !!header;
|
|
11867
12068
|
const openCn = hasTransitionedIn && isOpen ? "open" : "closed";
|
|
11868
|
-
const popover = /* @__PURE__ */ (0,
|
|
12069
|
+
const popover = /* @__PURE__ */ (0, import_jsx_runtime293.jsxs)(
|
|
11869
12070
|
Paper,
|
|
11870
12071
|
{
|
|
11871
12072
|
...getBaseHTMLProps(
|
|
@@ -11896,15 +12097,15 @@ var Popover = ({
|
|
|
11896
12097
|
elevation: 3,
|
|
11897
12098
|
border: "border-subtle",
|
|
11898
12099
|
children: [
|
|
11899
|
-
header && /* @__PURE__ */ (0,
|
|
11900
|
-
/* @__PURE__ */ (0,
|
|
12100
|
+
header && /* @__PURE__ */ (0, import_jsx_runtime293.jsx)("div", { className: Popover_default.header, children: typeof header === "string" ? /* @__PURE__ */ (0, import_jsx_runtime293.jsx)(Heading, { level: 2, typographyType: "headingMedium", children: header }) : header }),
|
|
12101
|
+
/* @__PURE__ */ (0, import_jsx_runtime293.jsx)(
|
|
11901
12102
|
"div",
|
|
11902
12103
|
{
|
|
11903
12104
|
className: !hasTitle && withCloseButton ? Popover_default["content--closable--no-header"] : "",
|
|
11904
12105
|
children
|
|
11905
12106
|
}
|
|
11906
12107
|
),
|
|
11907
|
-
withCloseButton && /* @__PURE__ */ (0,
|
|
12108
|
+
withCloseButton && /* @__PURE__ */ (0, import_jsx_runtime293.jsx)(
|
|
11908
12109
|
Button,
|
|
11909
12110
|
{
|
|
11910
12111
|
icon: CloseIcon,
|
|
@@ -11924,7 +12125,7 @@ Popover.displayName = "Popover";
|
|
|
11924
12125
|
|
|
11925
12126
|
// src/components/Popover/PopoverGroup.tsx
|
|
11926
12127
|
var import_react77 = require("react");
|
|
11927
|
-
var
|
|
12128
|
+
var import_jsx_runtime294 = require("react/jsx-runtime");
|
|
11928
12129
|
var PopoverGroup = ({
|
|
11929
12130
|
isOpen: propIsOpen,
|
|
11930
12131
|
setIsOpen: propSetIsOpen,
|
|
@@ -11985,7 +12186,7 @@ var PopoverGroup = ({
|
|
|
11985
12186
|
ref: combinedAnchorRef
|
|
11986
12187
|
}) : child);
|
|
11987
12188
|
});
|
|
11988
|
-
return /* @__PURE__ */ (0,
|
|
12189
|
+
return /* @__PURE__ */ (0, import_jsx_runtime294.jsx)(
|
|
11989
12190
|
PopoverContext,
|
|
11990
12191
|
{
|
|
11991
12192
|
value: {
|
|
@@ -12036,7 +12237,7 @@ var ProgressTracker_default = {
|
|
|
12036
12237
|
|
|
12037
12238
|
// src/components/ProgressTracker/ProgressTrackerItem.tsx
|
|
12038
12239
|
var import_react79 = require("react");
|
|
12039
|
-
var
|
|
12240
|
+
var import_jsx_runtime295 = require("react/jsx-runtime");
|
|
12040
12241
|
var toItemState = (active, completed, disabled) => {
|
|
12041
12242
|
if (disabled) {
|
|
12042
12243
|
return "disabled";
|
|
@@ -12080,10 +12281,10 @@ var ProgressTrackerItem = (props) => {
|
|
|
12080
12281
|
};
|
|
12081
12282
|
const stepNumberContent = (0, import_react79.useMemo)(() => {
|
|
12082
12283
|
if (completed) {
|
|
12083
|
-
return /* @__PURE__ */ (0,
|
|
12284
|
+
return /* @__PURE__ */ (0, import_jsx_runtime295.jsx)(Icon, { icon: CheckIcon, iconSize: "small" });
|
|
12084
12285
|
}
|
|
12085
12286
|
if (icon !== void 0) {
|
|
12086
|
-
return /* @__PURE__ */ (0,
|
|
12287
|
+
return /* @__PURE__ */ (0, import_jsx_runtime295.jsx)(Icon, { icon, iconSize: "small" });
|
|
12087
12288
|
}
|
|
12088
12289
|
return stepNumber;
|
|
12089
12290
|
}, [completed, icon, index]);
|
|
@@ -12092,8 +12293,8 @@ var ProgressTrackerItem = (props) => {
|
|
|
12092
12293
|
if (active) return "text-action-resting";
|
|
12093
12294
|
}
|
|
12094
12295
|
const isInactiveLink = disabled || active;
|
|
12095
|
-
const stepContent = /* @__PURE__ */ (0,
|
|
12096
|
-
/* @__PURE__ */ (0,
|
|
12296
|
+
const stepContent = /* @__PURE__ */ (0, import_jsx_runtime295.jsxs)(import_jsx_runtime295.Fragment, { children: [
|
|
12297
|
+
/* @__PURE__ */ (0, import_jsx_runtime295.jsx)(
|
|
12097
12298
|
Box,
|
|
12098
12299
|
{
|
|
12099
12300
|
display: "flex",
|
|
@@ -12108,7 +12309,7 @@ var ProgressTrackerItem = (props) => {
|
|
|
12108
12309
|
children: stepNumberContent
|
|
12109
12310
|
}
|
|
12110
12311
|
),
|
|
12111
|
-
/* @__PURE__ */ (0,
|
|
12312
|
+
/* @__PURE__ */ (0, import_jsx_runtime295.jsx)(
|
|
12112
12313
|
Typography,
|
|
12113
12314
|
{
|
|
12114
12315
|
as: "div",
|
|
@@ -12122,15 +12323,15 @@ var ProgressTrackerItem = (props) => {
|
|
|
12122
12323
|
}
|
|
12123
12324
|
)
|
|
12124
12325
|
] });
|
|
12125
|
-
const ariaLabel = props["aria-label"] ? props["aria-label"] : `${children}, ${stepNumber}. ${completed ? t(
|
|
12126
|
-
return /* @__PURE__ */ (0,
|
|
12326
|
+
const ariaLabel = props["aria-label"] ? props["aria-label"] : `${children}, ${stepNumber}. ${completed ? t(texts23.completed) : t(texts23.uncompleted)}`;
|
|
12327
|
+
return /* @__PURE__ */ (0, import_jsx_runtime295.jsx)(
|
|
12127
12328
|
Box,
|
|
12128
12329
|
{
|
|
12129
12330
|
as: "li",
|
|
12130
12331
|
display: direction === "row" ? "flex" : void 0,
|
|
12131
12332
|
"aria-current": active ? "step" : void 0,
|
|
12132
12333
|
className: cn(ProgressTracker_default["list-item"], ProgressTracker_default[`list-item--${direction}`]),
|
|
12133
|
-
children: handleStepChange ? /* @__PURE__ */ (0,
|
|
12334
|
+
children: handleStepChange ? /* @__PURE__ */ (0, import_jsx_runtime295.jsx)(
|
|
12134
12335
|
Box,
|
|
12135
12336
|
{
|
|
12136
12337
|
as: StylelessButton,
|
|
@@ -12154,7 +12355,7 @@ var ProgressTrackerItem = (props) => {
|
|
|
12154
12355
|
disabled,
|
|
12155
12356
|
children: stepContent
|
|
12156
12357
|
}
|
|
12157
|
-
) : /* @__PURE__ */ (0,
|
|
12358
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime295.jsx)(
|
|
12158
12359
|
"div",
|
|
12159
12360
|
{
|
|
12160
12361
|
...getBaseHTMLProps(
|
|
@@ -12171,23 +12372,25 @@ var ProgressTrackerItem = (props) => {
|
|
|
12171
12372
|
);
|
|
12172
12373
|
};
|
|
12173
12374
|
ProgressTrackerItem.displayName = "ProgressTracker.Item";
|
|
12174
|
-
var
|
|
12375
|
+
var texts23 = createTexts({
|
|
12175
12376
|
uncompleted: {
|
|
12176
12377
|
nb: "trinn ikke ferdig",
|
|
12177
12378
|
no: "trinn ikke ferdig",
|
|
12178
12379
|
nn: "trinn ikkje ferdig",
|
|
12179
|
-
en: "step uncompleted"
|
|
12380
|
+
en: "step uncompleted",
|
|
12381
|
+
se: "ceahkki ii g\xE1rvvis"
|
|
12180
12382
|
},
|
|
12181
12383
|
completed: {
|
|
12182
12384
|
nb: "trinn ferdig",
|
|
12183
12385
|
no: "trinn ferdig",
|
|
12184
12386
|
nn: "trinn ferdig",
|
|
12185
|
-
en: "step completed"
|
|
12387
|
+
en: "step completed",
|
|
12388
|
+
se: "ceahkki g\xE1rv\xE1"
|
|
12186
12389
|
}
|
|
12187
12390
|
});
|
|
12188
12391
|
|
|
12189
12392
|
// src/components/ProgressTracker/ProgressTracker.tsx
|
|
12190
|
-
var
|
|
12393
|
+
var import_jsx_runtime296 = require("react/jsx-runtime");
|
|
12191
12394
|
var ProgressTracker = (() => {
|
|
12192
12395
|
const Res = ({
|
|
12193
12396
|
id,
|
|
@@ -12217,7 +12420,7 @@ var ProgressTracker = (() => {
|
|
|
12217
12420
|
}, [children]);
|
|
12218
12421
|
const isRow = direction === "row";
|
|
12219
12422
|
const { "aria-label": ariaLabel } = htmlProps;
|
|
12220
|
-
return /* @__PURE__ */ (0,
|
|
12423
|
+
return /* @__PURE__ */ (0, import_jsx_runtime296.jsx)(
|
|
12221
12424
|
ProgressTrackerContext,
|
|
12222
12425
|
{
|
|
12223
12426
|
value: {
|
|
@@ -12225,12 +12428,12 @@ var ProgressTracker = (() => {
|
|
|
12225
12428
|
handleStepChange: handleChange,
|
|
12226
12429
|
direction
|
|
12227
12430
|
},
|
|
12228
|
-
children: /* @__PURE__ */ (0,
|
|
12431
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime296.jsx)(
|
|
12229
12432
|
"nav",
|
|
12230
12433
|
{
|
|
12231
|
-
"aria-label": ariaLabel != null ? ariaLabel : t(
|
|
12434
|
+
"aria-label": ariaLabel != null ? ariaLabel : t(texts24.stepProgression),
|
|
12232
12435
|
...getBaseHTMLProps(id, className, htmlProps, rest),
|
|
12233
|
-
children: /* @__PURE__ */ (0,
|
|
12436
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime296.jsx)(
|
|
12234
12437
|
Box,
|
|
12235
12438
|
{
|
|
12236
12439
|
as: StylelessOList,
|
|
@@ -12266,12 +12469,13 @@ function passIndexPropToProgressTrackerItem(children) {
|
|
|
12266
12469
|
})
|
|
12267
12470
|
);
|
|
12268
12471
|
}
|
|
12269
|
-
var
|
|
12472
|
+
var texts24 = createTexts({
|
|
12270
12473
|
stepProgression: {
|
|
12271
12474
|
nb: "Trinnprogresjon",
|
|
12272
12475
|
no: "Trinnprogresjon",
|
|
12273
12476
|
nn: "Trinnprogresjon",
|
|
12274
|
-
en: "Step progression"
|
|
12477
|
+
en: "Step progression",
|
|
12478
|
+
se: "Ceahkkeprogre\u0161uvdna"
|
|
12275
12479
|
}
|
|
12276
12480
|
});
|
|
12277
12481
|
|
|
@@ -12289,7 +12493,7 @@ var ProgressBar_default = {
|
|
|
12289
12493
|
};
|
|
12290
12494
|
|
|
12291
12495
|
// src/components/ProgressBar/ProgressBar.tsx
|
|
12292
|
-
var
|
|
12496
|
+
var import_jsx_runtime297 = require("react/jsx-runtime");
|
|
12293
12497
|
var PROGRESS_BAR_SIZES = createSizes("small", "medium");
|
|
12294
12498
|
var ProgressBar = ({
|
|
12295
12499
|
label,
|
|
@@ -12315,9 +12519,9 @@ var ProgressBar = ({
|
|
|
12315
12519
|
const errorMessageId = derivativeIdGenerator(uniqueId, "errorMessage");
|
|
12316
12520
|
const fillPrecentage = hasValidValue && value / (max != null ? max : 1) * 100 + "%";
|
|
12317
12521
|
const isIndeterminate = !hasValidValue && !hasErrorMessage;
|
|
12318
|
-
return /* @__PURE__ */ (0,
|
|
12522
|
+
return /* @__PURE__ */ (0, import_jsx_runtime297.jsxs)(Box, { width: "100%", className, style, children: [
|
|
12319
12523
|
renderLabel({ label, htmlFor: uniqueId }),
|
|
12320
|
-
/* @__PURE__ */ (0,
|
|
12524
|
+
/* @__PURE__ */ (0, import_jsx_runtime297.jsx)(
|
|
12321
12525
|
"progress",
|
|
12322
12526
|
{
|
|
12323
12527
|
id: uniqueId,
|
|
@@ -12333,13 +12537,13 @@ var ProgressBar = ({
|
|
|
12333
12537
|
children: fillPrecentage
|
|
12334
12538
|
}
|
|
12335
12539
|
),
|
|
12336
|
-
/* @__PURE__ */ (0,
|
|
12540
|
+
/* @__PURE__ */ (0, import_jsx_runtime297.jsx)(
|
|
12337
12541
|
Box,
|
|
12338
12542
|
{
|
|
12339
12543
|
width: getInputWidth(width),
|
|
12340
12544
|
height: size2 === "small" ? "x0.75" : "x1.5",
|
|
12341
12545
|
className: cn(ProgressBar_default.progress),
|
|
12342
|
-
children: /* @__PURE__ */ (0,
|
|
12546
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime297.jsx)(
|
|
12343
12547
|
Box,
|
|
12344
12548
|
{
|
|
12345
12549
|
height: "100%",
|
|
@@ -12388,7 +12592,7 @@ var typographyTypes2 = {
|
|
|
12388
12592
|
|
|
12389
12593
|
// src/components/Search/SearchSuggestionItem.tsx
|
|
12390
12594
|
var import_react83 = require("react");
|
|
12391
|
-
var
|
|
12595
|
+
var import_jsx_runtime298 = require("react/jsx-runtime");
|
|
12392
12596
|
var SearchSuggestionItem = ({
|
|
12393
12597
|
focus,
|
|
12394
12598
|
className,
|
|
@@ -12403,7 +12607,7 @@ var SearchSuggestionItem = ({
|
|
|
12403
12607
|
(_a = itemRef.current) == null ? void 0 : _a.focus();
|
|
12404
12608
|
}
|
|
12405
12609
|
}, [focus]);
|
|
12406
|
-
return /* @__PURE__ */ (0,
|
|
12610
|
+
return /* @__PURE__ */ (0, import_jsx_runtime298.jsx)(
|
|
12407
12611
|
StylelessButton,
|
|
12408
12612
|
{
|
|
12409
12613
|
ref: combinedRef,
|
|
@@ -12421,7 +12625,7 @@ var SearchSuggestionItem = ({
|
|
|
12421
12625
|
SearchSuggestionItem.displayName = "SearchSuggestionItem";
|
|
12422
12626
|
|
|
12423
12627
|
// src/components/Search/SearchSuggestions.tsx
|
|
12424
|
-
var
|
|
12628
|
+
var import_jsx_runtime299 = require("react/jsx-runtime");
|
|
12425
12629
|
var SearchSuggestions = ({
|
|
12426
12630
|
id,
|
|
12427
12631
|
searchId,
|
|
@@ -12441,7 +12645,7 @@ var SearchSuggestions = ({
|
|
|
12441
12645
|
const { t } = useTranslation();
|
|
12442
12646
|
const [focus] = useRoveFocus(suggestions == null ? void 0 : suggestions.length, showSuggestions);
|
|
12443
12647
|
const suggestionsToRender = maxSuggestions ? suggestions == null ? void 0 : suggestions.slice(maxSuggestions) : suggestions;
|
|
12444
|
-
return /* @__PURE__ */ (0,
|
|
12648
|
+
return /* @__PURE__ */ (0, import_jsx_runtime299.jsxs)(
|
|
12445
12649
|
Paper,
|
|
12446
12650
|
{
|
|
12447
12651
|
...getBaseHTMLProps(
|
|
@@ -12465,23 +12669,23 @@ var SearchSuggestions = ({
|
|
|
12465
12669
|
overflowY: "scroll",
|
|
12466
12670
|
marginBlock: "x0.25 0",
|
|
12467
12671
|
children: [
|
|
12468
|
-
/* @__PURE__ */ (0,
|
|
12672
|
+
/* @__PURE__ */ (0, import_jsx_runtime299.jsx)(
|
|
12469
12673
|
Box,
|
|
12470
12674
|
{
|
|
12471
12675
|
as: "h2",
|
|
12472
12676
|
paddingInline: "0 x1",
|
|
12473
12677
|
id: suggestionsHeaderId,
|
|
12474
12678
|
className: typographyStyles_default["body-xsmall"],
|
|
12475
|
-
children:
|
|
12679
|
+
children: t(texts25.searchSuggestions)
|
|
12476
12680
|
}
|
|
12477
12681
|
),
|
|
12478
|
-
/* @__PURE__ */ (0,
|
|
12479
|
-
return /* @__PURE__ */ (0,
|
|
12682
|
+
/* @__PURE__ */ (0, import_jsx_runtime299.jsx)(StylelessList, { role: "listbox", "aria-labelledby": suggestionsHeaderId, children: suggestionsToRender.map((suggestion, index) => {
|
|
12683
|
+
return /* @__PURE__ */ (0, import_jsx_runtime299.jsx)("li", { role: "option", children: /* @__PURE__ */ (0, import_jsx_runtime299.jsx)(
|
|
12480
12684
|
SearchSuggestionItem,
|
|
12481
12685
|
{
|
|
12482
12686
|
index,
|
|
12483
12687
|
focus: focus === index && showSuggestions,
|
|
12484
|
-
"aria-label": t(
|
|
12688
|
+
"aria-label": t(texts25.search(suggestion)),
|
|
12485
12689
|
onClick: onSuggestionClick,
|
|
12486
12690
|
"aria-setsize": suggestionsToRender.length,
|
|
12487
12691
|
"aria-posinset": index,
|
|
@@ -12495,17 +12699,25 @@ var SearchSuggestions = ({
|
|
|
12495
12699
|
);
|
|
12496
12700
|
};
|
|
12497
12701
|
SearchSuggestions.displayName = "SearchSuggestions";
|
|
12498
|
-
var
|
|
12702
|
+
var texts25 = createTexts({
|
|
12499
12703
|
search: (suggestion) => ({
|
|
12500
12704
|
no: `${suggestion} s\xF8k`,
|
|
12501
12705
|
nb: `${suggestion} s\xF8k`,
|
|
12502
12706
|
nn: `${suggestion} s\xF8k`,
|
|
12503
|
-
en: `${suggestion} search
|
|
12504
|
-
|
|
12707
|
+
en: `${suggestion} search`,
|
|
12708
|
+
se: `${suggestion} ohcan`
|
|
12709
|
+
}),
|
|
12710
|
+
searchSuggestions: {
|
|
12711
|
+
no: "S\xF8keforslag",
|
|
12712
|
+
nb: "S\xF8keforslag",
|
|
12713
|
+
nn: "S\xF8keforslag",
|
|
12714
|
+
en: "Search suggestions",
|
|
12715
|
+
se: "Ozanf\xE1laldagat"
|
|
12716
|
+
}
|
|
12505
12717
|
});
|
|
12506
12718
|
|
|
12507
12719
|
// src/components/Search/Search.tsx
|
|
12508
|
-
var
|
|
12720
|
+
var import_jsx_runtime300 = require("react/jsx-runtime");
|
|
12509
12721
|
var getIconSize2 = (size2) => {
|
|
12510
12722
|
switch (size2) {
|
|
12511
12723
|
case "large":
|
|
@@ -12581,14 +12793,14 @@ var Search = ({
|
|
|
12581
12793
|
} = buttonProps != null ? buttonProps : {};
|
|
12582
12794
|
const hasSuggestions = !!context.suggestions;
|
|
12583
12795
|
const showSearchButton = !!buttonProps && !!onClick;
|
|
12584
|
-
const inputGroup = /* @__PURE__ */ (0,
|
|
12796
|
+
const inputGroup = /* @__PURE__ */ (0, import_jsx_runtime300.jsxs)(
|
|
12585
12797
|
HStack,
|
|
12586
12798
|
{
|
|
12587
12799
|
position: "relative",
|
|
12588
12800
|
width: !showSearchButton ? width : void 0,
|
|
12589
12801
|
className: !showSearchButton ? className : void 0,
|
|
12590
12802
|
children: [
|
|
12591
|
-
showIcon && /* @__PURE__ */ (0,
|
|
12803
|
+
showIcon && /* @__PURE__ */ (0, import_jsx_runtime300.jsx)(
|
|
12592
12804
|
Icon,
|
|
12593
12805
|
{
|
|
12594
12806
|
icon: SearchIcon,
|
|
@@ -12599,7 +12811,7 @@ var Search = ({
|
|
|
12599
12811
|
)
|
|
12600
12812
|
}
|
|
12601
12813
|
),
|
|
12602
|
-
/* @__PURE__ */ (0,
|
|
12814
|
+
/* @__PURE__ */ (0, import_jsx_runtime300.jsx)(
|
|
12603
12815
|
Box,
|
|
12604
12816
|
{
|
|
12605
12817
|
as: Input,
|
|
@@ -12628,8 +12840,8 @@ var Search = ({
|
|
|
12628
12840
|
)
|
|
12629
12841
|
}
|
|
12630
12842
|
),
|
|
12631
|
-
hasSuggestions && /* @__PURE__ */ (0,
|
|
12632
|
-
/* @__PURE__ */ (0,
|
|
12843
|
+
hasSuggestions && /* @__PURE__ */ (0, import_jsx_runtime300.jsxs)(import_jsx_runtime300.Fragment, { children: [
|
|
12844
|
+
/* @__PURE__ */ (0, import_jsx_runtime300.jsx)(
|
|
12633
12845
|
SearchSuggestions,
|
|
12634
12846
|
{
|
|
12635
12847
|
id: suggestionsId,
|
|
@@ -12641,13 +12853,13 @@ var Search = ({
|
|
|
12641
12853
|
componentSize
|
|
12642
12854
|
}
|
|
12643
12855
|
),
|
|
12644
|
-
/* @__PURE__ */ (0,
|
|
12856
|
+
/* @__PURE__ */ (0, import_jsx_runtime300.jsx)(VisuallyHidden, { id: suggestionsDescriptionId, children: t(texts26.useArrowKeys) })
|
|
12645
12857
|
] }),
|
|
12646
|
-
hasValue && /* @__PURE__ */ (0,
|
|
12858
|
+
hasValue && /* @__PURE__ */ (0, import_jsx_runtime300.jsx)(
|
|
12647
12859
|
ClearButton,
|
|
12648
12860
|
{
|
|
12649
12861
|
size: getIconSize2(componentSize),
|
|
12650
|
-
"aria-label": t(
|
|
12862
|
+
"aria-label": t(texts26.clearSearch),
|
|
12651
12863
|
onClick: clearInput,
|
|
12652
12864
|
className: Search_default["clear-button"]
|
|
12653
12865
|
}
|
|
@@ -12655,10 +12867,10 @@ var Search = ({
|
|
|
12655
12867
|
]
|
|
12656
12868
|
}
|
|
12657
12869
|
);
|
|
12658
|
-
return /* @__PURE__ */ (0,
|
|
12870
|
+
return /* @__PURE__ */ (0, import_jsx_runtime300.jsxs)("div", { children: [
|
|
12659
12871
|
renderLabel({ htmlFor: uniqueId, label }),
|
|
12660
|
-
/* @__PURE__ */ (0,
|
|
12661
|
-
showSearchButton ? /* @__PURE__ */ (0,
|
|
12872
|
+
/* @__PURE__ */ (0, import_jsx_runtime300.jsxs)("div", { children: [
|
|
12873
|
+
showSearchButton ? /* @__PURE__ */ (0, import_jsx_runtime300.jsxs)(
|
|
12662
12874
|
Grid,
|
|
12663
12875
|
{
|
|
12664
12876
|
className,
|
|
@@ -12670,13 +12882,13 @@ var Search = ({
|
|
|
12670
12882
|
style,
|
|
12671
12883
|
children: [
|
|
12672
12884
|
inputGroup,
|
|
12673
|
-
/* @__PURE__ */ (0,
|
|
12885
|
+
/* @__PURE__ */ (0, import_jsx_runtime300.jsx)(
|
|
12674
12886
|
Button,
|
|
12675
12887
|
{
|
|
12676
12888
|
size: componentSize,
|
|
12677
12889
|
onClick,
|
|
12678
12890
|
...otherButtonProps,
|
|
12679
|
-
children: buttonLabel != null ? buttonLabel : t(
|
|
12891
|
+
children: buttonLabel != null ? buttonLabel : t(texts26.search)
|
|
12680
12892
|
}
|
|
12681
12893
|
)
|
|
12682
12894
|
]
|
|
@@ -12687,30 +12899,33 @@ var Search = ({
|
|
|
12687
12899
|
] });
|
|
12688
12900
|
};
|
|
12689
12901
|
Search.displayName = "Search";
|
|
12690
|
-
var
|
|
12902
|
+
var texts26 = createTexts({
|
|
12691
12903
|
clearSearch: {
|
|
12692
12904
|
nb: "T\xF8m s\xF8k",
|
|
12693
12905
|
no: "T\xF8m s\xF8k",
|
|
12694
12906
|
nn: "T\xF8m s\xF8k",
|
|
12695
|
-
en: "Clear search"
|
|
12907
|
+
en: "Clear search",
|
|
12908
|
+
se: "Gurre ohcama"
|
|
12696
12909
|
},
|
|
12697
12910
|
search: {
|
|
12698
12911
|
nb: "S\xF8k",
|
|
12699
12912
|
no: "S\xF8k",
|
|
12700
12913
|
nn: "S\xF8k",
|
|
12701
|
-
en: "Search"
|
|
12914
|
+
en: "Search",
|
|
12915
|
+
se: "Ohcan"
|
|
12702
12916
|
},
|
|
12703
12917
|
useArrowKeys: {
|
|
12704
12918
|
nb: "Bruk piltastene for \xE5 navigere i forslagene n\xE5r listen er utvidet",
|
|
12705
12919
|
no: "Bruk piltastene for \xE5 navigere i forslagene n\xE5r listen er utvidet",
|
|
12706
12920
|
nn: "Bruk piltastane for \xE5 navigere i forslaga n\xE5r lista er utvida",
|
|
12707
|
-
en: "Use the arrow keys to navigate suggestions when the list is expanded"
|
|
12921
|
+
en: "Use the arrow keys to navigate suggestions when the list is expanded",
|
|
12922
|
+
se: "Deatte njuollaboalu ohccat \xE1rvalusaid listtus mii lea viiddiduvvon"
|
|
12708
12923
|
}
|
|
12709
12924
|
});
|
|
12710
12925
|
|
|
12711
12926
|
// src/components/Search/SearchAutocompleteWrapper.tsx
|
|
12712
12927
|
var import_react85 = require("react");
|
|
12713
|
-
var
|
|
12928
|
+
var import_jsx_runtime301 = require("react/jsx-runtime");
|
|
12714
12929
|
var SearchAutocompleteWrapper = (props) => {
|
|
12715
12930
|
const {
|
|
12716
12931
|
value,
|
|
@@ -12786,7 +13001,7 @@ var SearchAutocompleteWrapper = (props) => {
|
|
|
12786
13001
|
inputValue,
|
|
12787
13002
|
onSugggestionClick: handleSuggestionClick
|
|
12788
13003
|
};
|
|
12789
|
-
return /* @__PURE__ */ (0,
|
|
13004
|
+
return /* @__PURE__ */ (0, import_jsx_runtime301.jsx)(AutocompleteSearchContext, { value: contextProps, children });
|
|
12790
13005
|
};
|
|
12791
13006
|
SearchAutocompleteWrapper.displayName = "SearchAutocompleteWrapper";
|
|
12792
13007
|
|
|
@@ -12802,7 +13017,7 @@ var Skeleton_default = {
|
|
|
12802
13017
|
};
|
|
12803
13018
|
|
|
12804
13019
|
// src/components/Skeleton/Skeleton.tsx
|
|
12805
|
-
var
|
|
13020
|
+
var import_jsx_runtime302 = require("react/jsx-runtime");
|
|
12806
13021
|
var Skeleton = ({
|
|
12807
13022
|
width,
|
|
12808
13023
|
height,
|
|
@@ -12812,7 +13027,7 @@ var Skeleton = ({
|
|
|
12812
13027
|
ref,
|
|
12813
13028
|
...rest
|
|
12814
13029
|
}) => {
|
|
12815
|
-
return /* @__PURE__ */ (0,
|
|
13030
|
+
return /* @__PURE__ */ (0, import_jsx_runtime302.jsx)(
|
|
12816
13031
|
Box,
|
|
12817
13032
|
{
|
|
12818
13033
|
width,
|
|
@@ -12832,7 +13047,7 @@ var SkipToContent_default = {
|
|
|
12832
13047
|
};
|
|
12833
13048
|
|
|
12834
13049
|
// src/components/SkipToContent/SkipToContent.tsx
|
|
12835
|
-
var
|
|
13050
|
+
var import_jsx_runtime303 = require("react/jsx-runtime");
|
|
12836
13051
|
var SkipToContent = ({
|
|
12837
13052
|
text = "Til hovedinnhold",
|
|
12838
13053
|
top = 0,
|
|
@@ -12842,12 +13057,12 @@ var SkipToContent = ({
|
|
|
12842
13057
|
...rest
|
|
12843
13058
|
}) => {
|
|
12844
13059
|
const { className: htmlPropsClassName, style, ...restHtmlProps } = htmlProps;
|
|
12845
|
-
return /* @__PURE__ */ (0,
|
|
13060
|
+
return /* @__PURE__ */ (0, import_jsx_runtime303.jsx)(
|
|
12846
13061
|
Contrast,
|
|
12847
13062
|
{
|
|
12848
13063
|
className: cn(className, htmlPropsClassName, SkipToContent_default.wrapper),
|
|
12849
13064
|
style: { ...style, top },
|
|
12850
|
-
children: /* @__PURE__ */ (0,
|
|
13065
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime303.jsx)(Link, { ...getBaseHTMLProps(id, restHtmlProps, rest), children: text })
|
|
12851
13066
|
}
|
|
12852
13067
|
);
|
|
12853
13068
|
};
|
|
@@ -12865,7 +13080,7 @@ var SplitButton_default = {
|
|
|
12865
13080
|
};
|
|
12866
13081
|
|
|
12867
13082
|
// src/components/SplitButton/SplitButton.tsx
|
|
12868
|
-
var
|
|
13083
|
+
var import_jsx_runtime304 = require("react/jsx-runtime");
|
|
12869
13084
|
var SplitButton = ({
|
|
12870
13085
|
size: size2,
|
|
12871
13086
|
primaryAction,
|
|
@@ -12880,8 +13095,8 @@ var SplitButton = ({
|
|
|
12880
13095
|
purpose,
|
|
12881
13096
|
size: size2
|
|
12882
13097
|
};
|
|
12883
|
-
return /* @__PURE__ */ (0,
|
|
12884
|
-
/* @__PURE__ */ (0,
|
|
13098
|
+
return /* @__PURE__ */ (0, import_jsx_runtime304.jsxs)("div", { className: cn(className, SplitButton_default.container), ...rest, children: [
|
|
13099
|
+
/* @__PURE__ */ (0, import_jsx_runtime304.jsx)(
|
|
12885
13100
|
Button,
|
|
12886
13101
|
{
|
|
12887
13102
|
...buttonStyleProps,
|
|
@@ -12890,13 +13105,13 @@ var SplitButton = ({
|
|
|
12890
13105
|
className: SplitButton_default.main
|
|
12891
13106
|
}
|
|
12892
13107
|
),
|
|
12893
|
-
/* @__PURE__ */ (0,
|
|
12894
|
-
/* @__PURE__ */ (0,
|
|
13108
|
+
/* @__PURE__ */ (0, import_jsx_runtime304.jsxs)(OverflowMenuGroup, { isOpen, setIsOpen, children: [
|
|
13109
|
+
/* @__PURE__ */ (0, import_jsx_runtime304.jsx)(
|
|
12895
13110
|
Button,
|
|
12896
13111
|
{
|
|
12897
13112
|
...buttonStyleProps,
|
|
12898
13113
|
icon: isOpen ? ChevronUpIcon : ChevronDownIcon,
|
|
12899
|
-
"aria-label": t(
|
|
13114
|
+
"aria-label": t(texts27.moreActions),
|
|
12900
13115
|
purpose,
|
|
12901
13116
|
className: cn(
|
|
12902
13117
|
SplitButton_default.option,
|
|
@@ -12905,17 +13120,18 @@ var SplitButton = ({
|
|
|
12905
13120
|
type: "button"
|
|
12906
13121
|
}
|
|
12907
13122
|
),
|
|
12908
|
-
/* @__PURE__ */ (0,
|
|
13123
|
+
/* @__PURE__ */ (0, import_jsx_runtime304.jsx)(OverflowMenu, { placement: "bottom-end", children: /* @__PURE__ */ (0, import_jsx_runtime304.jsx)(OverflowMenuList, { children: secondaryActions.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime304.jsx)(OverflowMenuButton, { ...item, children: item.children }, index)) }) })
|
|
12909
13124
|
] })
|
|
12910
13125
|
] });
|
|
12911
13126
|
};
|
|
12912
13127
|
SplitButton.displayName = "SplitButton";
|
|
12913
|
-
var
|
|
13128
|
+
var texts27 = createTexts({
|
|
12914
13129
|
moreActions: {
|
|
12915
13130
|
nb: "Flere handlinger",
|
|
12916
13131
|
no: "Flere handlinger",
|
|
12917
13132
|
nn: "Fleire handlingar",
|
|
12918
|
-
en: "More actions"
|
|
13133
|
+
en: "More actions",
|
|
13134
|
+
se: "Eanet doaimmat"
|
|
12919
13135
|
}
|
|
12920
13136
|
});
|
|
12921
13137
|
|
|
@@ -12931,14 +13147,14 @@ var CollapsibleTableContext = (0, import_react87.createContext)({
|
|
|
12931
13147
|
var useCollapsibleTableContext = () => (0, import_react87.useContext)(CollapsibleTableContext);
|
|
12932
13148
|
|
|
12933
13149
|
// src/components/Table/normal/Body.tsx
|
|
12934
|
-
var
|
|
12935
|
-
var Body = (props) => /* @__PURE__ */ (0,
|
|
13150
|
+
var import_jsx_runtime305 = require("react/jsx-runtime");
|
|
13151
|
+
var Body = (props) => /* @__PURE__ */ (0, import_jsx_runtime305.jsx)("tbody", { ...props });
|
|
12936
13152
|
Body.displayName = "Table.Body";
|
|
12937
13153
|
|
|
12938
13154
|
// src/components/Table/normal/Head.tsx
|
|
12939
13155
|
var import_react88 = require("react");
|
|
12940
|
-
var
|
|
12941
|
-
var Head = ({ children, ...rest }) => /* @__PURE__ */ (0,
|
|
13156
|
+
var import_jsx_runtime306 = require("react/jsx-runtime");
|
|
13157
|
+
var Head = ({ children, ...rest }) => /* @__PURE__ */ (0, import_jsx_runtime306.jsx)("thead", { ...rest, children: /* @__PURE__ */ (0, import_jsx_runtime306.jsx)(HeadContext, { value: true, children }) });
|
|
12942
13158
|
var HeadContext = (0, import_react88.createContext)(false);
|
|
12943
13159
|
function useIsInTableHead() {
|
|
12944
13160
|
const isInTableHead = (0, import_react88.useContext)(HeadContext);
|
|
@@ -12971,7 +13187,7 @@ var Table_default = {
|
|
|
12971
13187
|
};
|
|
12972
13188
|
|
|
12973
13189
|
// src/components/Table/normal/Cell.tsx
|
|
12974
|
-
var
|
|
13190
|
+
var import_jsx_runtime307 = require("react/jsx-runtime");
|
|
12975
13191
|
var Cell = ({
|
|
12976
13192
|
children,
|
|
12977
13193
|
type: _type,
|
|
@@ -12984,7 +13200,7 @@ var Cell = ({
|
|
|
12984
13200
|
const type = _type != null ? _type : isInHead ? "head" : "data";
|
|
12985
13201
|
const { isCollapsibleChild } = collapsibleProps != null ? collapsibleProps : {};
|
|
12986
13202
|
const isComplexLayout = layout === "text and icon";
|
|
12987
|
-
return isCollapsibleChild ? /* @__PURE__ */ (0,
|
|
13203
|
+
return isCollapsibleChild ? /* @__PURE__ */ (0, import_jsx_runtime307.jsx)(DescriptionListDesc, { children }) : type === "head" ? /* @__PURE__ */ (0, import_jsx_runtime307.jsx)(
|
|
12988
13204
|
"th",
|
|
12989
13205
|
{
|
|
12990
13206
|
...rest,
|
|
@@ -12993,26 +13209,26 @@ var Cell = ({
|
|
|
12993
13209
|
!isComplexLayout && Table_default[`cell--${layout}`],
|
|
12994
13210
|
Table_default["cell--head"]
|
|
12995
13211
|
),
|
|
12996
|
-
children: isComplexLayout ? /* @__PURE__ */ (0,
|
|
13212
|
+
children: isComplexLayout ? /* @__PURE__ */ (0, import_jsx_runtime307.jsx)("div", { className: Table_default.cell__inner, children }) : children
|
|
12997
13213
|
}
|
|
12998
|
-
) : /* @__PURE__ */ (0,
|
|
13214
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime307.jsx)(
|
|
12999
13215
|
"td",
|
|
13000
13216
|
{
|
|
13001
13217
|
...rest,
|
|
13002
13218
|
className: cn(className, !isComplexLayout && Table_default[`cell--${layout}`]),
|
|
13003
|
-
children: isComplexLayout ? /* @__PURE__ */ (0,
|
|
13219
|
+
children: isComplexLayout ? /* @__PURE__ */ (0, import_jsx_runtime307.jsx)("div", { className: Table_default.cell__inner, children }) : children
|
|
13004
13220
|
}
|
|
13005
13221
|
);
|
|
13006
13222
|
};
|
|
13007
13223
|
Cell.displayName = "Table.Cell";
|
|
13008
13224
|
|
|
13009
13225
|
// src/components/Table/normal/Foot.tsx
|
|
13010
|
-
var
|
|
13011
|
-
var Foot = (props) => /* @__PURE__ */ (0,
|
|
13226
|
+
var import_jsx_runtime308 = require("react/jsx-runtime");
|
|
13227
|
+
var Foot = (props) => /* @__PURE__ */ (0, import_jsx_runtime308.jsx)("tfoot", { ...props });
|
|
13012
13228
|
Foot.displayName = "Table.Foot";
|
|
13013
13229
|
|
|
13014
13230
|
// src/components/Table/normal/Row.tsx
|
|
13015
|
-
var
|
|
13231
|
+
var import_jsx_runtime309 = require("react/jsx-runtime");
|
|
13016
13232
|
var Row = ({
|
|
13017
13233
|
type: _type,
|
|
13018
13234
|
mode = "normal",
|
|
@@ -13023,7 +13239,7 @@ var Row = ({
|
|
|
13023
13239
|
}) => {
|
|
13024
13240
|
const isInHeader = useIsInTableHead();
|
|
13025
13241
|
const type = _type != null ? _type : isInHeader ? "head" : "body";
|
|
13026
|
-
return /* @__PURE__ */ (0,
|
|
13242
|
+
return /* @__PURE__ */ (0, import_jsx_runtime309.jsx)(
|
|
13027
13243
|
"tr",
|
|
13028
13244
|
{
|
|
13029
13245
|
className: cn(
|
|
@@ -13043,12 +13259,12 @@ var Row = ({
|
|
|
13043
13259
|
Row.displayName = "Table.Row";
|
|
13044
13260
|
|
|
13045
13261
|
// src/components/Table/normal/SortCell.tsx
|
|
13046
|
-
var
|
|
13262
|
+
var import_jsx_runtime310 = require("react/jsx-runtime");
|
|
13047
13263
|
var makeSortIcon = (isSorted, sortOrder) => {
|
|
13048
13264
|
if (!isSorted || !sortOrder) {
|
|
13049
|
-
return /* @__PURE__ */ (0,
|
|
13265
|
+
return /* @__PURE__ */ (0, import_jsx_runtime310.jsx)(Icon, { icon: UnfoldMoreIcon, iconSize: "inherit" });
|
|
13050
13266
|
}
|
|
13051
|
-
return sortOrder === "ascending" ? /* @__PURE__ */ (0,
|
|
13267
|
+
return sortOrder === "ascending" ? /* @__PURE__ */ (0, import_jsx_runtime310.jsx)(Icon, { icon: ChevronDownIcon, iconSize: "inherit" }) : /* @__PURE__ */ (0, import_jsx_runtime310.jsx)(Icon, { icon: ChevronUpIcon, iconSize: "inherit" });
|
|
13052
13268
|
};
|
|
13053
13269
|
var SortCell = ({
|
|
13054
13270
|
isSorted,
|
|
@@ -13058,17 +13274,17 @@ var SortCell = ({
|
|
|
13058
13274
|
...rest
|
|
13059
13275
|
}) => {
|
|
13060
13276
|
const { t } = useTranslation();
|
|
13061
|
-
return /* @__PURE__ */ (0,
|
|
13277
|
+
return /* @__PURE__ */ (0, import_jsx_runtime310.jsx)(
|
|
13062
13278
|
Cell,
|
|
13063
13279
|
{
|
|
13064
13280
|
type: "head",
|
|
13065
13281
|
"aria-sort": isSorted && sortOrder ? sortOrder : void 0,
|
|
13066
13282
|
...rest,
|
|
13067
|
-
children: /* @__PURE__ */ (0,
|
|
13283
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime310.jsxs)(
|
|
13068
13284
|
StylelessButton,
|
|
13069
13285
|
{
|
|
13070
13286
|
onClick,
|
|
13071
|
-
"aria-description": t(
|
|
13287
|
+
"aria-description": t(texts28.changeSort),
|
|
13072
13288
|
className: cn(Table_default["sort-button"], focusable),
|
|
13073
13289
|
children: [
|
|
13074
13290
|
children,
|
|
@@ -13081,17 +13297,18 @@ var SortCell = ({
|
|
|
13081
13297
|
);
|
|
13082
13298
|
};
|
|
13083
13299
|
SortCell.displayName = "Table.SortCell";
|
|
13084
|
-
var
|
|
13300
|
+
var texts28 = createTexts({
|
|
13085
13301
|
changeSort: {
|
|
13086
13302
|
nb: "Aktiver for \xE5 endre sorteringsrekkef\xF8lge",
|
|
13087
13303
|
no: "Aktiver for \xE5 endre sorteringsrekkef\xF8lge",
|
|
13088
13304
|
nn: "Aktiver for \xE5 endre sorteringsrekkjef\xF8lgje",
|
|
13089
|
-
en: "Activate to change sort order"
|
|
13305
|
+
en: "Activate to change sort order",
|
|
13306
|
+
se: "Aktivere rievdadit sorterenortnega"
|
|
13090
13307
|
}
|
|
13091
13308
|
});
|
|
13092
13309
|
|
|
13093
13310
|
// src/components/Table/normal/Table.tsx
|
|
13094
|
-
var
|
|
13311
|
+
var import_jsx_runtime311 = require("react/jsx-runtime");
|
|
13095
13312
|
var Table = ({
|
|
13096
13313
|
size: size2 = "medium",
|
|
13097
13314
|
stickyHeader,
|
|
@@ -13099,7 +13316,7 @@ var Table = ({
|
|
|
13099
13316
|
className,
|
|
13100
13317
|
children,
|
|
13101
13318
|
...rest
|
|
13102
|
-
}) => /* @__PURE__ */ (0,
|
|
13319
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime311.jsx)(
|
|
13103
13320
|
"table",
|
|
13104
13321
|
{
|
|
13105
13322
|
...rest,
|
|
@@ -13118,7 +13335,7 @@ Table.displayName = "Table";
|
|
|
13118
13335
|
|
|
13119
13336
|
// src/components/Table/normal/TableWrapper.tsx
|
|
13120
13337
|
var import_react89 = require("react");
|
|
13121
|
-
var
|
|
13338
|
+
var import_jsx_runtime312 = require("react/jsx-runtime");
|
|
13122
13339
|
var TableWrapper = ({ className, ...rest }) => {
|
|
13123
13340
|
const themeContext = (0, import_react89.useContext)(ThemeContext);
|
|
13124
13341
|
const container2 = themeContext == null ? void 0 : themeContext.el;
|
|
@@ -13143,7 +13360,7 @@ var TableWrapper = ({ className, ...rest }) => {
|
|
|
13143
13360
|
window.addEventListener("resize", handleResize);
|
|
13144
13361
|
return () => window.removeEventListener("resize", handleResize);
|
|
13145
13362
|
});
|
|
13146
|
-
return /* @__PURE__ */ (0,
|
|
13363
|
+
return /* @__PURE__ */ (0, import_jsx_runtime312.jsx)(
|
|
13147
13364
|
"div",
|
|
13148
13365
|
{
|
|
13149
13366
|
ref: wrapperRef,
|
|
@@ -13170,7 +13387,7 @@ Table2.Row = Row;
|
|
|
13170
13387
|
Table2.Foot = Foot;
|
|
13171
13388
|
|
|
13172
13389
|
// src/components/Table/collapsible/CollapsibleRow.tsx
|
|
13173
|
-
var
|
|
13390
|
+
var import_jsx_runtime313 = require("react/jsx-runtime");
|
|
13174
13391
|
var CollapsibleRow = ({
|
|
13175
13392
|
type: _type,
|
|
13176
13393
|
className,
|
|
@@ -13213,40 +13430,40 @@ var CollapsibleRow = ({
|
|
|
13213
13430
|
const collapsedRenderedChildren = isCollapsed && collapsedHeaderValues.length > 0 ? collapsedChildren.map(function(child, index) {
|
|
13214
13431
|
const id = derivativeIdGenerator(prefix2, index.toString());
|
|
13215
13432
|
collapsibleIds.push(id);
|
|
13216
|
-
return /* @__PURE__ */ (0,
|
|
13217
|
-
/* @__PURE__ */ (0,
|
|
13433
|
+
return /* @__PURE__ */ (0, import_jsx_runtime313.jsxs)(import_react90.Fragment, { children: [
|
|
13434
|
+
/* @__PURE__ */ (0, import_jsx_runtime313.jsx)(DescriptionListTerm, { children: collapsedHeaderValues[index].content }),
|
|
13218
13435
|
(0, import_react90.isValidElement)(child) && (0, import_react90.cloneElement)(child, {
|
|
13219
13436
|
collapsibleProps: { isCollapsibleChild: true }
|
|
13220
13437
|
})
|
|
13221
13438
|
] }, `DL-${index}`);
|
|
13222
13439
|
}) : null;
|
|
13223
|
-
const collapsedRows = collapsedRenderedChildren && collapsedRenderedChildren.length > 0 ? /* @__PURE__ */ (0,
|
|
13440
|
+
const collapsedRows = collapsedRenderedChildren && collapsedRenderedChildren.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime313.jsx)(Row, { ...rowProps(), children: /* @__PURE__ */ (0, import_jsx_runtime313.jsx)(Cell, { colSpan: definingColumnIndex.length + 1, children: /* @__PURE__ */ (0, import_jsx_runtime313.jsx)(DescriptionList, { children: collapsedRenderedChildren }) }) }) : null;
|
|
13224
13441
|
const definingColumnCells = childrenArray.slice().filter((column, index) => definingColumnIndex.indexOf(index) > -1).sort((a, b) => {
|
|
13225
13442
|
return definingColumnIndex.indexOf(childrenArray.indexOf(a)) - definingColumnIndex.indexOf(childrenArray.indexOf(b));
|
|
13226
13443
|
});
|
|
13227
13444
|
const headerRow = () => {
|
|
13228
13445
|
if (type !== "head" || !isCollapsed) return null;
|
|
13229
|
-
return /* @__PURE__ */ (0,
|
|
13446
|
+
return /* @__PURE__ */ (0, import_jsx_runtime313.jsx)(Row, { ref, ...rowProps(), children: /* @__PURE__ */ (0, import_jsx_runtime313.jsxs)(import_jsx_runtime313.Fragment, { children: [
|
|
13230
13447
|
definingColumnCells,
|
|
13231
|
-
/* @__PURE__ */ (0,
|
|
13232
|
-
t(
|
|
13233
|
-
/* @__PURE__ */ (0,
|
|
13448
|
+
/* @__PURE__ */ (0, import_jsx_runtime313.jsxs)(Table2.Cell, { type: "head", layout: "center", children: [
|
|
13449
|
+
t(texts29.expand),
|
|
13450
|
+
/* @__PURE__ */ (0, import_jsx_runtime313.jsx)(VisuallyHidden, { children: t(texts29.row) })
|
|
13234
13451
|
] })
|
|
13235
13452
|
] }) });
|
|
13236
13453
|
};
|
|
13237
13454
|
const idList = spaceSeparatedIdListGenerator(collapsibleIds);
|
|
13238
13455
|
const rowWithChevron = () => {
|
|
13239
13456
|
if (type !== "body" || !isCollapsed) return null;
|
|
13240
|
-
return /* @__PURE__ */ (0,
|
|
13457
|
+
return /* @__PURE__ */ (0, import_jsx_runtime313.jsxs)(Row, { ref, ...rowProps(!childrenCollapsed && true), children: [
|
|
13241
13458
|
definingColumnCells,
|
|
13242
|
-
/* @__PURE__ */ (0,
|
|
13459
|
+
/* @__PURE__ */ (0, import_jsx_runtime313.jsx)(Table2.Cell, { children: /* @__PURE__ */ (0, import_jsx_runtime313.jsx)(
|
|
13243
13460
|
StylelessButton,
|
|
13244
13461
|
{
|
|
13245
13462
|
onClick: () => setChildrenCollapsed(!childrenCollapsed),
|
|
13246
13463
|
"aria-expanded": !childrenCollapsed,
|
|
13247
13464
|
"aria-controls": idList,
|
|
13248
13465
|
className: cn(Table_default["collapse-button"], focusable),
|
|
13249
|
-
children: /* @__PURE__ */ (0,
|
|
13466
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime313.jsx)(
|
|
13250
13467
|
AnimatedChevronUpDown,
|
|
13251
13468
|
{
|
|
13252
13469
|
isUp: childrenCollapsed ? false : true,
|
|
@@ -13258,39 +13475,41 @@ var CollapsibleRow = ({
|
|
|
13258
13475
|
) })
|
|
13259
13476
|
] });
|
|
13260
13477
|
};
|
|
13261
|
-
return isCollapsed && collapsedRenderedChildren && collapsedRenderedChildren.length > 0 ? /* @__PURE__ */ (0,
|
|
13478
|
+
return isCollapsed && collapsedRenderedChildren && collapsedRenderedChildren.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime313.jsxs)(import_jsx_runtime313.Fragment, { children: [
|
|
13262
13479
|
headerRow(),
|
|
13263
|
-
type === "body" && /* @__PURE__ */ (0,
|
|
13480
|
+
type === "body" && /* @__PURE__ */ (0, import_jsx_runtime313.jsxs)(import_jsx_runtime313.Fragment, { children: [
|
|
13264
13481
|
rowWithChevron(),
|
|
13265
13482
|
childrenCollapsed ? null : collapsedRows
|
|
13266
13483
|
] })
|
|
13267
|
-
] }) : /* @__PURE__ */ (0,
|
|
13484
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime313.jsx)(Row, { ref, ...rowProps(), children });
|
|
13268
13485
|
};
|
|
13269
13486
|
CollapsibleRow.displayName = "CollapsibleTable.Row";
|
|
13270
|
-
var
|
|
13487
|
+
var texts29 = createTexts({
|
|
13271
13488
|
expand: {
|
|
13272
13489
|
nb: "Utvid",
|
|
13273
13490
|
no: "Utvid",
|
|
13274
13491
|
nn: "Utvid",
|
|
13275
|
-
en: "Expand"
|
|
13492
|
+
en: "Expand",
|
|
13493
|
+
se: "Viiddit"
|
|
13276
13494
|
},
|
|
13277
13495
|
row: {
|
|
13278
13496
|
nb: "raden",
|
|
13279
13497
|
no: "raden",
|
|
13280
13498
|
nn: "rada",
|
|
13281
|
-
en: "row"
|
|
13499
|
+
en: "row",
|
|
13500
|
+
se: "gurgadus"
|
|
13282
13501
|
}
|
|
13283
13502
|
});
|
|
13284
13503
|
|
|
13285
13504
|
// src/components/Table/collapsible/CollapsibleTable.tsx
|
|
13286
|
-
var
|
|
13505
|
+
var import_jsx_runtime314 = require("react/jsx-runtime");
|
|
13287
13506
|
var CollapsibleTable = ({
|
|
13288
13507
|
isCollapsed,
|
|
13289
13508
|
headerValues,
|
|
13290
13509
|
definingColumnIndex = [0],
|
|
13291
13510
|
...rest
|
|
13292
13511
|
}) => {
|
|
13293
|
-
return /* @__PURE__ */ (0,
|
|
13512
|
+
return /* @__PURE__ */ (0, import_jsx_runtime314.jsx)(
|
|
13294
13513
|
CollapsibleTableContext,
|
|
13295
13514
|
{
|
|
13296
13515
|
value: {
|
|
@@ -13298,7 +13517,7 @@ var CollapsibleTable = ({
|
|
|
13298
13517
|
headerValues,
|
|
13299
13518
|
definingColumnIndex
|
|
13300
13519
|
},
|
|
13301
|
-
children: /* @__PURE__ */ (0,
|
|
13520
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime314.jsx)(Table2, { ...rest })
|
|
13302
13521
|
}
|
|
13303
13522
|
);
|
|
13304
13523
|
};
|
|
@@ -13344,13 +13563,13 @@ var Tabs_default = {
|
|
|
13344
13563
|
|
|
13345
13564
|
// src/components/Tabs/TabWidthContext.tsx
|
|
13346
13565
|
var import_react92 = require("react");
|
|
13347
|
-
var
|
|
13566
|
+
var import_jsx_runtime315 = require("react/jsx-runtime");
|
|
13348
13567
|
var TabContext = (0, import_react92.createContext)(null);
|
|
13349
13568
|
function TabWidthContextProvider({
|
|
13350
13569
|
children,
|
|
13351
13570
|
onChangeWidths
|
|
13352
13571
|
}) {
|
|
13353
|
-
return /* @__PURE__ */ (0,
|
|
13572
|
+
return /* @__PURE__ */ (0, import_jsx_runtime315.jsx)(
|
|
13354
13573
|
TabContext,
|
|
13355
13574
|
{
|
|
13356
13575
|
value: {
|
|
@@ -13382,7 +13601,7 @@ function useSetTabWidth(index, width) {
|
|
|
13382
13601
|
}
|
|
13383
13602
|
|
|
13384
13603
|
// src/components/Tabs/AddTabButton.tsx
|
|
13385
|
-
var
|
|
13604
|
+
var import_jsx_runtime316 = require("react/jsx-runtime");
|
|
13386
13605
|
var AddTabButton = ({
|
|
13387
13606
|
ref,
|
|
13388
13607
|
children,
|
|
@@ -13395,7 +13614,7 @@ var AddTabButton = ({
|
|
|
13395
13614
|
const buttonRef = (0, import_react93.useRef)(null);
|
|
13396
13615
|
const combinedRef = useCombinedRef(ref, buttonRef);
|
|
13397
13616
|
const { tabContentDirection, size: size2 } = useTabsContext();
|
|
13398
|
-
return /* @__PURE__ */ (0,
|
|
13617
|
+
return /* @__PURE__ */ (0, import_jsx_runtime316.jsxs)(
|
|
13399
13618
|
"button",
|
|
13400
13619
|
{
|
|
13401
13620
|
...rest,
|
|
@@ -13408,8 +13627,8 @@ var AddTabButton = ({
|
|
|
13408
13627
|
focus_default["focusable--inset"]
|
|
13409
13628
|
),
|
|
13410
13629
|
children: [
|
|
13411
|
-
/* @__PURE__ */ (0,
|
|
13412
|
-
/* @__PURE__ */ (0,
|
|
13630
|
+
/* @__PURE__ */ (0, import_jsx_runtime316.jsx)(Icon, { icon: PlusIcon, iconSize: "inherit" }),
|
|
13631
|
+
/* @__PURE__ */ (0, import_jsx_runtime316.jsx)("span", { children })
|
|
13413
13632
|
]
|
|
13414
13633
|
}
|
|
13415
13634
|
);
|
|
@@ -13418,7 +13637,7 @@ AddTabButton.displayName = "AddTabButton";
|
|
|
13418
13637
|
|
|
13419
13638
|
// src/components/Tabs/Tabs.tsx
|
|
13420
13639
|
var import_react94 = require("react");
|
|
13421
|
-
var
|
|
13640
|
+
var import_jsx_runtime317 = require("react/jsx-runtime");
|
|
13422
13641
|
var TABS_SIZES = createSizes("small", "medium");
|
|
13423
13642
|
var Tabs = ({
|
|
13424
13643
|
id,
|
|
@@ -13448,7 +13667,7 @@ var Tabs = ({
|
|
|
13448
13667
|
setActiveTab(activeTab);
|
|
13449
13668
|
}
|
|
13450
13669
|
}, [activeTab, thisActiveTab]);
|
|
13451
|
-
return /* @__PURE__ */ (0,
|
|
13670
|
+
return /* @__PURE__ */ (0, import_jsx_runtime317.jsx)(
|
|
13452
13671
|
TabsContext,
|
|
13453
13672
|
{
|
|
13454
13673
|
value: {
|
|
@@ -13463,7 +13682,7 @@ var Tabs = ({
|
|
|
13463
13682
|
tabContentDirection,
|
|
13464
13683
|
addTabButtonProps
|
|
13465
13684
|
},
|
|
13466
|
-
children: /* @__PURE__ */ (0,
|
|
13685
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime317.jsx)(
|
|
13467
13686
|
Box,
|
|
13468
13687
|
{
|
|
13469
13688
|
...getBaseHTMLProps(uniqueId, className, htmlProps, rest),
|
|
@@ -13478,7 +13697,7 @@ Tabs.displayName = "Tabs";
|
|
|
13478
13697
|
|
|
13479
13698
|
// src/components/Tabs/Tab.tsx
|
|
13480
13699
|
var import_react95 = require("react");
|
|
13481
|
-
var
|
|
13700
|
+
var import_jsx_runtime318 = require("react/jsx-runtime");
|
|
13482
13701
|
var Tab = ({
|
|
13483
13702
|
active = false,
|
|
13484
13703
|
icon,
|
|
@@ -13520,7 +13739,7 @@ var Tab = ({
|
|
|
13520
13739
|
handleSelect();
|
|
13521
13740
|
onKeyDown == null ? void 0 : onKeyDown(e);
|
|
13522
13741
|
};
|
|
13523
|
-
return /* @__PURE__ */ (0,
|
|
13742
|
+
return /* @__PURE__ */ (0, import_jsx_runtime318.jsxs)(
|
|
13524
13743
|
"button",
|
|
13525
13744
|
{
|
|
13526
13745
|
...getBaseHTMLProps(
|
|
@@ -13544,8 +13763,8 @@ var Tab = ({
|
|
|
13544
13763
|
onKeyDown: handleOnKeyDown,
|
|
13545
13764
|
tabIndex: focus ? 0 : -1,
|
|
13546
13765
|
children: [
|
|
13547
|
-
icon && /* @__PURE__ */ (0,
|
|
13548
|
-
/* @__PURE__ */ (0,
|
|
13766
|
+
icon && /* @__PURE__ */ (0, import_jsx_runtime318.jsx)(Icon, { icon, iconSize: "inherit" }),
|
|
13767
|
+
/* @__PURE__ */ (0, import_jsx_runtime318.jsx)("span", { children })
|
|
13549
13768
|
]
|
|
13550
13769
|
}
|
|
13551
13770
|
);
|
|
@@ -13554,7 +13773,7 @@ Tab.displayName = "Tab";
|
|
|
13554
13773
|
|
|
13555
13774
|
// src/components/Tabs/TabList.tsx
|
|
13556
13775
|
var import_react96 = require("react");
|
|
13557
|
-
var
|
|
13776
|
+
var import_jsx_runtime319 = require("react/jsx-runtime");
|
|
13558
13777
|
var TabList = ({
|
|
13559
13778
|
children,
|
|
13560
13779
|
id,
|
|
@@ -13612,7 +13831,7 @@ var TabList = ({
|
|
|
13612
13831
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
13613
13832
|
["--dds-tab-widths"]: widths.join(" ")
|
|
13614
13833
|
};
|
|
13615
|
-
return /* @__PURE__ */ (0,
|
|
13834
|
+
return /* @__PURE__ */ (0, import_jsx_runtime319.jsx)(TabWidthContextProvider, { onChangeWidths: setWidths, children: /* @__PURE__ */ (0, import_jsx_runtime319.jsxs)(
|
|
13616
13835
|
"div",
|
|
13617
13836
|
{
|
|
13618
13837
|
...rest,
|
|
@@ -13632,7 +13851,7 @@ var TabList = ({
|
|
|
13632
13851
|
style: { ...style, ...customWidths },
|
|
13633
13852
|
children: [
|
|
13634
13853
|
tabListChildren,
|
|
13635
|
-
hasButton && /* @__PURE__ */ (0,
|
|
13854
|
+
hasButton && /* @__PURE__ */ (0, import_jsx_runtime319.jsx)(
|
|
13636
13855
|
AddTabButton,
|
|
13637
13856
|
{
|
|
13638
13857
|
index: tabListChildren ? tabListChildren.length : 0,
|
|
@@ -13646,7 +13865,7 @@ var TabList = ({
|
|
|
13646
13865
|
TabList.displayName = "TabList";
|
|
13647
13866
|
|
|
13648
13867
|
// src/components/Tabs/TabPanel.tsx
|
|
13649
|
-
var
|
|
13868
|
+
var import_jsx_runtime320 = require("react/jsx-runtime");
|
|
13650
13869
|
var TabPanel = ({
|
|
13651
13870
|
active = false,
|
|
13652
13871
|
children,
|
|
@@ -13655,7 +13874,7 @@ var TabPanel = ({
|
|
|
13655
13874
|
htmlProps,
|
|
13656
13875
|
padding = "x0.25",
|
|
13657
13876
|
...rest
|
|
13658
|
-
}) => /* @__PURE__ */ (0,
|
|
13877
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime320.jsx)(
|
|
13659
13878
|
Box,
|
|
13660
13879
|
{
|
|
13661
13880
|
padding,
|
|
@@ -13670,7 +13889,7 @@ TabPanel.displayName = "TabPanel";
|
|
|
13670
13889
|
|
|
13671
13890
|
// src/components/Tabs/TabPanels.tsx
|
|
13672
13891
|
var import_react97 = require("react");
|
|
13673
|
-
var
|
|
13892
|
+
var import_jsx_runtime321 = require("react/jsx-runtime");
|
|
13674
13893
|
var TabPanels = ({ children, ref, ...rest }) => {
|
|
13675
13894
|
const { activeTab, tabsId, tabPanelsRef } = useTabsContext();
|
|
13676
13895
|
const combinedRef = useCombinedRef(ref, tabPanelsRef);
|
|
@@ -13685,7 +13904,7 @@ var TabPanels = ({ children, ref, ...rest }) => {
|
|
|
13685
13904
|
}
|
|
13686
13905
|
});
|
|
13687
13906
|
});
|
|
13688
|
-
return /* @__PURE__ */ (0,
|
|
13907
|
+
return /* @__PURE__ */ (0, import_jsx_runtime321.jsx)(Box, { ref: combinedRef, ...rest, children: panelChildren });
|
|
13689
13908
|
};
|
|
13690
13909
|
TabPanels.displayName = "TabPanels";
|
|
13691
13910
|
|
|
@@ -13706,7 +13925,7 @@ var Tag_default = {
|
|
|
13706
13925
|
};
|
|
13707
13926
|
|
|
13708
13927
|
// src/components/Tag/Tag.tsx
|
|
13709
|
-
var
|
|
13928
|
+
var import_jsx_runtime322 = require("react/jsx-runtime");
|
|
13710
13929
|
var icons3 = {
|
|
13711
13930
|
info: InfoIcon,
|
|
13712
13931
|
danger: ErrorIcon,
|
|
@@ -13726,7 +13945,7 @@ var Tag = ({
|
|
|
13726
13945
|
...rest
|
|
13727
13946
|
}) => {
|
|
13728
13947
|
const icon = icons3[purpose];
|
|
13729
|
-
return /* @__PURE__ */ (0,
|
|
13948
|
+
return /* @__PURE__ */ (0, import_jsx_runtime322.jsxs)(
|
|
13730
13949
|
TextOverflowEllipsisWrapper,
|
|
13731
13950
|
{
|
|
13732
13951
|
...getBaseHTMLProps(
|
|
@@ -13742,8 +13961,8 @@ var Tag = ({
|
|
|
13742
13961
|
rest
|
|
13743
13962
|
),
|
|
13744
13963
|
children: [
|
|
13745
|
-
withIcon && icon && /* @__PURE__ */ (0,
|
|
13746
|
-
/* @__PURE__ */ (0,
|
|
13964
|
+
withIcon && icon && /* @__PURE__ */ (0, import_jsx_runtime322.jsx)(Icon, { icon, iconSize: "small" }),
|
|
13965
|
+
/* @__PURE__ */ (0, import_jsx_runtime322.jsx)(TextOverflowEllipsisInner, { children: children != null ? children : text })
|
|
13747
13966
|
]
|
|
13748
13967
|
}
|
|
13749
13968
|
);
|
|
@@ -13773,7 +13992,7 @@ var TextInput_default = {
|
|
|
13773
13992
|
};
|
|
13774
13993
|
|
|
13775
13994
|
// src/components/TextInput/TextInput.tsx
|
|
13776
|
-
var
|
|
13995
|
+
var import_jsx_runtime323 = require("react/jsx-runtime");
|
|
13777
13996
|
var TextInput = ({
|
|
13778
13997
|
label,
|
|
13779
13998
|
afterLabelContent,
|
|
@@ -13868,8 +14087,8 @@ var TextInput = ({
|
|
|
13868
14087
|
const suffixPaddingInlineEnd = suffixLength ? `calc(var(--dds-spacing-x1) + ${suffixLength}px)` : void 0;
|
|
13869
14088
|
let extendedInput = null;
|
|
13870
14089
|
if (hasIcon) {
|
|
13871
|
-
extendedInput = /* @__PURE__ */ (0,
|
|
13872
|
-
/* @__PURE__ */ (0,
|
|
14090
|
+
extendedInput = /* @__PURE__ */ (0, import_jsx_runtime323.jsxs)(Box, { className: Input_default["input-group"], width: inputWidth, children: [
|
|
14091
|
+
/* @__PURE__ */ (0, import_jsx_runtime323.jsx)(
|
|
13873
14092
|
Icon,
|
|
13874
14093
|
{
|
|
13875
14094
|
icon,
|
|
@@ -13880,7 +14099,7 @@ var TextInput = ({
|
|
|
13880
14099
|
)
|
|
13881
14100
|
}
|
|
13882
14101
|
),
|
|
13883
|
-
/* @__PURE__ */ (0,
|
|
14102
|
+
/* @__PURE__ */ (0, import_jsx_runtime323.jsx)(
|
|
13884
14103
|
StatefulInput,
|
|
13885
14104
|
{
|
|
13886
14105
|
className: cn(
|
|
@@ -13893,7 +14112,7 @@ var TextInput = ({
|
|
|
13893
14112
|
)
|
|
13894
14113
|
] });
|
|
13895
14114
|
} else if (hasAffix) {
|
|
13896
|
-
extendedInput = /* @__PURE__ */ (0,
|
|
14115
|
+
extendedInput = /* @__PURE__ */ (0, import_jsx_runtime323.jsxs)(
|
|
13897
14116
|
Box,
|
|
13898
14117
|
{
|
|
13899
14118
|
position: "relative",
|
|
@@ -13901,7 +14120,7 @@ var TextInput = ({
|
|
|
13901
14120
|
alignItems: "center",
|
|
13902
14121
|
width: inputWidth,
|
|
13903
14122
|
children: [
|
|
13904
|
-
prefix2 && /* @__PURE__ */ (0,
|
|
14123
|
+
prefix2 && /* @__PURE__ */ (0, import_jsx_runtime323.jsx)(
|
|
13905
14124
|
"span",
|
|
13906
14125
|
{
|
|
13907
14126
|
ref: prefixRef,
|
|
@@ -13914,7 +14133,7 @@ var TextInput = ({
|
|
|
13914
14133
|
children: prefix2
|
|
13915
14134
|
}
|
|
13916
14135
|
),
|
|
13917
|
-
/* @__PURE__ */ (0,
|
|
14136
|
+
/* @__PURE__ */ (0, import_jsx_runtime323.jsx)(
|
|
13918
14137
|
StatefulInput,
|
|
13919
14138
|
{
|
|
13920
14139
|
style: {
|
|
@@ -13925,7 +14144,7 @@ var TextInput = ({
|
|
|
13925
14144
|
...generalInputProps
|
|
13926
14145
|
}
|
|
13927
14146
|
),
|
|
13928
|
-
suffix && /* @__PURE__ */ (0,
|
|
14147
|
+
suffix && /* @__PURE__ */ (0, import_jsx_runtime323.jsx)(
|
|
13929
14148
|
"span",
|
|
13930
14149
|
{
|
|
13931
14150
|
ref: suffixRef,
|
|
@@ -13942,7 +14161,7 @@ var TextInput = ({
|
|
|
13942
14161
|
}
|
|
13943
14162
|
);
|
|
13944
14163
|
}
|
|
13945
|
-
return /* @__PURE__ */ (0,
|
|
14164
|
+
return /* @__PURE__ */ (0, import_jsx_runtime323.jsxs)(
|
|
13946
14165
|
"div",
|
|
13947
14166
|
{
|
|
13948
14167
|
className: cn(
|
|
@@ -13961,8 +14180,8 @@ var TextInput = ({
|
|
|
13961
14180
|
readOnly,
|
|
13962
14181
|
afterLabelContent
|
|
13963
14182
|
}),
|
|
13964
|
-
extendedInput ? extendedInput : /* @__PURE__ */ (0,
|
|
13965
|
-
hasBottomContainer && /* @__PURE__ */ (0,
|
|
14183
|
+
extendedInput ? extendedInput : /* @__PURE__ */ (0, import_jsx_runtime323.jsx)(Box, { as: StatefulInput, width: inputWidth, ...generalInputProps }),
|
|
14184
|
+
hasBottomContainer && /* @__PURE__ */ (0, import_jsx_runtime323.jsxs)(
|
|
13966
14185
|
Box,
|
|
13967
14186
|
{
|
|
13968
14187
|
display: "flex",
|
|
@@ -14005,7 +14224,7 @@ var Toggle_default = {
|
|
|
14005
14224
|
};
|
|
14006
14225
|
|
|
14007
14226
|
// src/components/Toggle/Toggle.tsx
|
|
14008
|
-
var
|
|
14227
|
+
var import_jsx_runtime324 = require("react/jsx-runtime");
|
|
14009
14228
|
var TOGGLE_SIZES = createSizes("medium", "large");
|
|
14010
14229
|
var Toggle = ({
|
|
14011
14230
|
id,
|
|
@@ -14030,7 +14249,7 @@ var Toggle = ({
|
|
|
14030
14249
|
defaultValue: defaultChecked != null ? defaultChecked : false,
|
|
14031
14250
|
onChange
|
|
14032
14251
|
});
|
|
14033
|
-
return /* @__PURE__ */ (0,
|
|
14252
|
+
return /* @__PURE__ */ (0, import_jsx_runtime324.jsxs)(
|
|
14034
14253
|
"label",
|
|
14035
14254
|
{
|
|
14036
14255
|
htmlFor: uniqueId,
|
|
@@ -14042,7 +14261,7 @@ var Toggle = ({
|
|
|
14042
14261
|
readOnly && Toggle_default["label--read-only"]
|
|
14043
14262
|
),
|
|
14044
14263
|
children: [
|
|
14045
|
-
/* @__PURE__ */ (0,
|
|
14264
|
+
/* @__PURE__ */ (0, import_jsx_runtime324.jsx)(
|
|
14046
14265
|
HiddenInput,
|
|
14047
14266
|
{
|
|
14048
14267
|
...getBaseHTMLProps(
|
|
@@ -14064,7 +14283,7 @@ var Toggle = ({
|
|
|
14064
14283
|
onClick: readOnlyClickHandler(readOnly || isLoading, htmlProps.onClick)
|
|
14065
14284
|
}
|
|
14066
14285
|
),
|
|
14067
|
-
/* @__PURE__ */ (0,
|
|
14286
|
+
/* @__PURE__ */ (0, import_jsx_runtime324.jsx)("span", { className: cn(Toggle_default.track, focus_default["focus-styled-sibling"]), children: /* @__PURE__ */ (0, import_jsx_runtime324.jsx)("span", { className: Toggle_default.thumb, children: isLoading ? /* @__PURE__ */ (0, import_jsx_runtime324.jsx)(Spinner, { size: `var(--dds-icon-size-${size2})` }) : /* @__PURE__ */ (0, import_jsx_runtime324.jsx)(
|
|
14068
14287
|
Icon,
|
|
14069
14288
|
{
|
|
14070
14289
|
className: Toggle_default.checkmark,
|
|
@@ -14072,8 +14291,8 @@ var Toggle = ({
|
|
|
14072
14291
|
iconSize
|
|
14073
14292
|
}
|
|
14074
14293
|
) }) }),
|
|
14075
|
-
/* @__PURE__ */ (0,
|
|
14076
|
-
readOnly && /* @__PURE__ */ (0,
|
|
14294
|
+
/* @__PURE__ */ (0, import_jsx_runtime324.jsxs)("span", { className: cn(readOnly && Toggle_default["labeltext--readonly"]), children: [
|
|
14295
|
+
readOnly && /* @__PURE__ */ (0, import_jsx_runtime324.jsx)(
|
|
14077
14296
|
Icon,
|
|
14078
14297
|
{
|
|
14079
14298
|
icon: LockIcon,
|
|
@@ -14083,7 +14302,7 @@ var Toggle = ({
|
|
|
14083
14302
|
),
|
|
14084
14303
|
children,
|
|
14085
14304
|
" ",
|
|
14086
|
-
isLoading && /* @__PURE__ */ (0,
|
|
14305
|
+
isLoading && /* @__PURE__ */ (0, import_jsx_runtime324.jsx)(VisuallyHidden, { children: t(commonTexts.loading) })
|
|
14087
14306
|
] })
|
|
14088
14307
|
]
|
|
14089
14308
|
}
|
|
@@ -14117,7 +14336,7 @@ var ToggleBar_default = {
|
|
|
14117
14336
|
};
|
|
14118
14337
|
|
|
14119
14338
|
// src/components/ToggleBar/ToggleBar.tsx
|
|
14120
|
-
var
|
|
14339
|
+
var import_jsx_runtime325 = require("react/jsx-runtime");
|
|
14121
14340
|
var ToggleBar = (props) => {
|
|
14122
14341
|
const {
|
|
14123
14342
|
children,
|
|
@@ -14140,7 +14359,7 @@ var ToggleBar = (props) => {
|
|
|
14140
14359
|
(e) => onChange && onChange(e, e.target.value)
|
|
14141
14360
|
);
|
|
14142
14361
|
const labelId = label && `${uniqueId}-label`;
|
|
14143
|
-
return /* @__PURE__ */ (0,
|
|
14362
|
+
return /* @__PURE__ */ (0, import_jsx_runtime325.jsx)(
|
|
14144
14363
|
ToggleBarContext,
|
|
14145
14364
|
{
|
|
14146
14365
|
value: {
|
|
@@ -14149,7 +14368,7 @@ var ToggleBar = (props) => {
|
|
|
14149
14368
|
name,
|
|
14150
14369
|
value: groupValue
|
|
14151
14370
|
},
|
|
14152
|
-
children: /* @__PURE__ */ (0,
|
|
14371
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime325.jsxs)(
|
|
14153
14372
|
VStack,
|
|
14154
14373
|
{
|
|
14155
14374
|
...getBaseHTMLProps(id, className, htmlProps, rest),
|
|
@@ -14158,8 +14377,8 @@ var ToggleBar = (props) => {
|
|
|
14158
14377
|
role: "radiogroup",
|
|
14159
14378
|
"aria-labelledby": labelId != null ? labelId : htmlProps == null ? void 0 : htmlProps["aria-labelledby"],
|
|
14160
14379
|
children: [
|
|
14161
|
-
label && /* @__PURE__ */ (0,
|
|
14162
|
-
/* @__PURE__ */ (0,
|
|
14380
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime325.jsx)(Typography, { id: labelId, as: "span", typographyType: "labelMedium", children: label }),
|
|
14381
|
+
/* @__PURE__ */ (0, import_jsx_runtime325.jsx)("div", { className: ToggleBar_default.bar, children })
|
|
14163
14382
|
]
|
|
14164
14383
|
}
|
|
14165
14384
|
)
|
|
@@ -14170,7 +14389,7 @@ ToggleBar.displayName = "ToggleBar";
|
|
|
14170
14389
|
|
|
14171
14390
|
// src/components/ToggleBar/ToggleRadio.tsx
|
|
14172
14391
|
var import_react102 = require("react");
|
|
14173
|
-
var
|
|
14392
|
+
var import_jsx_runtime326 = require("react/jsx-runtime");
|
|
14174
14393
|
var typographyTypes3 = {
|
|
14175
14394
|
large: "bodyLarge",
|
|
14176
14395
|
medium: "bodyMedium",
|
|
@@ -14210,8 +14429,8 @@ var ToggleRadio = ({
|
|
|
14210
14429
|
(_a = group == null ? void 0 : group.onChange) == null ? void 0 : _a.call(group, event);
|
|
14211
14430
|
};
|
|
14212
14431
|
const contentTypeCn = label ? "with-text" : "just-icon";
|
|
14213
|
-
return /* @__PURE__ */ (0,
|
|
14214
|
-
/* @__PURE__ */ (0,
|
|
14432
|
+
return /* @__PURE__ */ (0, import_jsx_runtime326.jsxs)("label", { htmlFor: uniqueId, className: ToggleBar_default.label, children: [
|
|
14433
|
+
/* @__PURE__ */ (0, import_jsx_runtime326.jsx)(
|
|
14215
14434
|
HiddenInput,
|
|
14216
14435
|
{
|
|
14217
14436
|
...getBaseHTMLProps(
|
|
@@ -14229,7 +14448,7 @@ var ToggleRadio = ({
|
|
|
14229
14448
|
"aria-labelledby": ariaLabelledBy
|
|
14230
14449
|
}
|
|
14231
14450
|
),
|
|
14232
|
-
/* @__PURE__ */ (0,
|
|
14451
|
+
/* @__PURE__ */ (0, import_jsx_runtime326.jsxs)(
|
|
14233
14452
|
Typography,
|
|
14234
14453
|
{
|
|
14235
14454
|
as: "span",
|
|
@@ -14240,8 +14459,8 @@ var ToggleRadio = ({
|
|
|
14240
14459
|
focus_default["focus-styled-sibling"]
|
|
14241
14460
|
),
|
|
14242
14461
|
children: [
|
|
14243
|
-
icon && /* @__PURE__ */ (0,
|
|
14244
|
-
label && /* @__PURE__ */ (0,
|
|
14462
|
+
icon && /* @__PURE__ */ (0, import_jsx_runtime326.jsx)(Icon, { icon, iconSize: "inherit" }),
|
|
14463
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime326.jsx)("span", { children: label })
|
|
14245
14464
|
]
|
|
14246
14465
|
}
|
|
14247
14466
|
)
|
|
@@ -14261,7 +14480,7 @@ var ToggleButton_default = {
|
|
|
14261
14480
|
};
|
|
14262
14481
|
|
|
14263
14482
|
// src/components/ToggleButton/ToggleButton.tsx
|
|
14264
|
-
var
|
|
14483
|
+
var import_jsx_runtime327 = require("react/jsx-runtime");
|
|
14265
14484
|
var ToggleButton = ({
|
|
14266
14485
|
id,
|
|
14267
14486
|
label,
|
|
@@ -14274,8 +14493,8 @@ var ToggleButton = ({
|
|
|
14274
14493
|
const generatedId = (0, import_react103.useId)();
|
|
14275
14494
|
const uniqueId = id != null ? id : `${generatedId}-toggleButton`;
|
|
14276
14495
|
const hasIcon = !!icon;
|
|
14277
|
-
return /* @__PURE__ */ (0,
|
|
14278
|
-
/* @__PURE__ */ (0,
|
|
14496
|
+
return /* @__PURE__ */ (0, import_jsx_runtime327.jsxs)(Box, { as: "label", htmlFor: uniqueId, width: "fit-content", children: [
|
|
14497
|
+
/* @__PURE__ */ (0, import_jsx_runtime327.jsx)(
|
|
14279
14498
|
HiddenInput,
|
|
14280
14499
|
{
|
|
14281
14500
|
...getBaseHTMLProps(
|
|
@@ -14287,7 +14506,7 @@ var ToggleButton = ({
|
|
|
14287
14506
|
type: "checkbox"
|
|
14288
14507
|
}
|
|
14289
14508
|
),
|
|
14290
|
-
/* @__PURE__ */ (0,
|
|
14509
|
+
/* @__PURE__ */ (0, import_jsx_runtime327.jsxs)(
|
|
14291
14510
|
"span",
|
|
14292
14511
|
{
|
|
14293
14512
|
className: cn(
|
|
@@ -14298,7 +14517,7 @@ var ToggleButton = ({
|
|
|
14298
14517
|
focus_default["focus-styled-sibling"]
|
|
14299
14518
|
),
|
|
14300
14519
|
children: [
|
|
14301
|
-
hasIcon && /* @__PURE__ */ (0,
|
|
14520
|
+
hasIcon && /* @__PURE__ */ (0, import_jsx_runtime327.jsx)(Icon, { icon, iconSize: "inherit" }),
|
|
14302
14521
|
" ",
|
|
14303
14522
|
label
|
|
14304
14523
|
]
|
|
@@ -14310,7 +14529,7 @@ ToggleButton.displayName = "ToggleButton";
|
|
|
14310
14529
|
|
|
14311
14530
|
// src/components/ToggleButton/ToggleButtonGroup.tsx
|
|
14312
14531
|
var import_react104 = require("react");
|
|
14313
|
-
var
|
|
14532
|
+
var import_jsx_runtime328 = require("react/jsx-runtime");
|
|
14314
14533
|
var ToggleButtonGroup = (props) => {
|
|
14315
14534
|
const {
|
|
14316
14535
|
children,
|
|
@@ -14324,7 +14543,7 @@ var ToggleButtonGroup = (props) => {
|
|
|
14324
14543
|
} = props;
|
|
14325
14544
|
const generatedId = (0, import_react104.useId)();
|
|
14326
14545
|
const uniqueLabelId = labelId != null ? labelId : `${generatedId}-ToggleButtonGroupLabel`;
|
|
14327
|
-
return /* @__PURE__ */ (0,
|
|
14546
|
+
return /* @__PURE__ */ (0, import_jsx_runtime328.jsxs)(
|
|
14328
14547
|
"div",
|
|
14329
14548
|
{
|
|
14330
14549
|
...getBaseHTMLProps(id, className, htmlProps, rest),
|
|
@@ -14332,7 +14551,7 @@ var ToggleButtonGroup = (props) => {
|
|
|
14332
14551
|
"aria-labelledby": label ? uniqueLabelId : void 0,
|
|
14333
14552
|
children: [
|
|
14334
14553
|
renderGroupLabel({ label, id: uniqueLabelId }),
|
|
14335
|
-
/* @__PURE__ */ (0,
|
|
14554
|
+
/* @__PURE__ */ (0, import_jsx_runtime328.jsx)(Box, { display: "flex", flexWrap: "wrap", gap: "x0.75", flexDirection: direction, children })
|
|
14336
14555
|
]
|
|
14337
14556
|
}
|
|
14338
14557
|
);
|
|
@@ -14469,6 +14688,16 @@ ToggleButtonGroup.displayName = "ToggleButtonGroup";
|
|
|
14469
14688
|
FooterLogo,
|
|
14470
14689
|
FooterSocialsGroup,
|
|
14471
14690
|
FooterSocialsList,
|
|
14691
|
+
FormSummary,
|
|
14692
|
+
FormSummaryEditButton,
|
|
14693
|
+
FormSummaryEmptyValue,
|
|
14694
|
+
FormSummaryError,
|
|
14695
|
+
FormSummaryField,
|
|
14696
|
+
FormSummaryFields,
|
|
14697
|
+
FormSummaryHeader,
|
|
14698
|
+
FormSummaryHeading,
|
|
14699
|
+
FormSummaryLabel,
|
|
14700
|
+
FormSummaryValue,
|
|
14472
14701
|
FullscreenExitIcon,
|
|
14473
14702
|
FullscreenIcon,
|
|
14474
14703
|
GavelIcon,
|