optimized-react-component-library-xyz123 0.19.14 → 0.19.15

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.mjs CHANGED
@@ -1,11 +1,27 @@
1
+ // src/components/layout/ValidationMessage/ValidationMessage.tsx
2
+ import { jsx, jsxs } from "react/jsx-runtime";
3
+ var ValidationSummary = ({
4
+ validationMessesege,
5
+ validationId,
6
+ activatedLanguage = "sv",
7
+ showValidationSummary = false
8
+ }) => {
9
+ return showValidationSummary && /* @__PURE__ */ jsxs("div", { className: "pts-root-error", id: validationId, children: [
10
+ /* @__PURE__ */ jsx("span", { "aria-hidden": true, className: "errorDot", children: "!" }),
11
+ /* @__PURE__ */ jsx("span", { className: "sr-only", children: activatedLanguage === "sv" ? "Valideringsfel" : "Validation error" }),
12
+ /* @__PURE__ */ jsx("span", { className: "errorText", children: validationMessesege })
13
+ ] });
14
+ };
15
+ var ValidationMessage_default = ValidationSummary;
16
+
1
17
  // src/components/input-components/RadioMultipleStandard/RadioMultipleStandard.tsx
2
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
18
+ import { Fragment, jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
3
19
  var InputRadio = ({
4
20
  question,
5
21
  handleQuestionInputChange,
6
22
  showPreview = false
7
23
  }) => {
8
- var _a;
24
+ var _a, _b, _c;
9
25
  const questionId = `question-${question.id}`;
10
26
  const groupId = `radio-group-${question.id}`;
11
27
  const errorId = `error-${question.id}`;
@@ -13,21 +29,22 @@ var InputRadio = ({
13
29
  const e = { target: { value: event.target.value } };
14
30
  handleQuestionInputChange(e, question);
15
31
  };
16
- return /* @__PURE__ */ jsxs(Fragment, { children: [
17
- !showPreview && question.visible && /* @__PURE__ */ jsx("div", { className: "pts-root-question pts-radioMultiple-container", id: questionId, children: /* @__PURE__ */ jsxs(
32
+ console.log("question", question);
33
+ return /* @__PURE__ */ jsxs2(Fragment, { children: [
34
+ !showPreview && question.visible && /* @__PURE__ */ jsx2("div", { className: "pts-root-question pts-radioMultiple-container", id: questionId, children: /* @__PURE__ */ jsxs2(
18
35
  "fieldset",
19
36
  {
20
37
  "aria-required": question.isQuestionMandatory,
21
38
  "aria-invalid": question.hasValidationError ? question.hasValidationError : void 0,
22
39
  "aria-errormessage": question.hasValidationError ? errorId : void 0,
23
40
  children: [
24
- /* @__PURE__ */ jsxs("legend", { id: `label-${groupId}`, children: [
41
+ /* @__PURE__ */ jsxs2("legend", { id: `label-${groupId}`, children: [
25
42
  question.questionLabel,
26
43
  " ",
27
- question.isQuestionMandatory && /* @__PURE__ */ jsx("span", { "aria-hidden": true, className: "pts-root-mandatoryAsterisk", children: "*" })
44
+ question.isQuestionMandatory && /* @__PURE__ */ jsx2("span", { "aria-hidden": true, className: "pts-root-mandatoryAsterisk", children: "*" })
28
45
  ] }),
29
- (_a = question.options) == null ? void 0 : _a.map((option, index) => /* @__PURE__ */ jsxs("div", { className: "pts-radio-option", children: [
30
- /* @__PURE__ */ jsx(
46
+ (_a = question.options) == null ? void 0 : _a.map((option, index) => /* @__PURE__ */ jsxs2("div", { className: "pts-radio-option", children: [
47
+ /* @__PURE__ */ jsx2(
31
48
  "input",
32
49
  {
33
50
  type: "radio",
@@ -38,27 +55,31 @@ var InputRadio = ({
38
55
  onChange: handleInputChange
39
56
  }
40
57
  ),
41
- /* @__PURE__ */ jsx("label", { htmlFor: `${groupId}-option-${index}`, children: option.label }),
58
+ /* @__PURE__ */ jsx2("label", { htmlFor: `${groupId}-option-${index}`, children: option.label }),
42
59
  " "
43
60
  ] }, index)),
44
- question.hasValidationError && /* @__PURE__ */ jsxs("div", { className: "pts-root-error", id: errorId, children: [
45
- /* @__PURE__ */ jsx("span", { "aria-hidden": true, className: "errorDot", children: "!" }),
46
- /* @__PURE__ */ jsx("span", { className: "sr-only", children: "Valideringsfel" }),
47
- /* @__PURE__ */ jsx("span", { className: "errorText", children: question.validationDefaultMessesege })
48
- ] })
61
+ /* @__PURE__ */ jsx2(
62
+ ValidationMessage_default,
63
+ {
64
+ showValidationSummary: (_b = question.hasValidationError) != null ? _b : false,
65
+ validationId: errorId,
66
+ validationMessesege: (_c = question.validationDefaultMessesege) != null ? _c : "",
67
+ activatedLanguage: "sv"
68
+ }
69
+ )
49
70
  ]
50
71
  }
51
72
  ) }),
52
- showPreview && /* @__PURE__ */ jsx(PreviewRadio, { question })
73
+ showPreview && /* @__PURE__ */ jsx2(PreviewRadio, { question })
53
74
  ] });
54
75
  };
55
76
  var RadioMultipleStandard_default = InputRadio;
56
77
  var PreviewRadio = ({ question }) => {
57
78
  var _a, _b;
58
79
  const previewId = `preview-${question.id}`;
59
- return /* @__PURE__ */ jsxs(Fragment, { children: [
60
- /* @__PURE__ */ jsx("dt", { id: `question-${previewId}`, children: (_a = question.previewLabel) != null ? _a : question.questionLabel }),
61
- ((_b = question.answer) == null ? void 0 : _b.trim()) ? /* @__PURE__ */ jsx("dd", { className: "pts-radioMultiple-preview pts-root-answer", id: `answer-${previewId}`, children: question.answer }) : /* @__PURE__ */ jsx(
80
+ return /* @__PURE__ */ jsxs2(Fragment, { children: [
81
+ /* @__PURE__ */ jsx2("dt", { id: `question-${previewId}`, children: (_a = question.previewLabel) != null ? _a : question.questionLabel }),
82
+ ((_b = question.answer) == null ? void 0 : _b.trim()) ? /* @__PURE__ */ jsx2("dd", { className: "pts-radioMultiple-preview pts-root-answer", id: `answer-${previewId}`, children: question.answer }) : /* @__PURE__ */ jsx2(
62
83
  "dd",
63
84
  {
64
85
  className: "pts-radioMultiple-preview pts-root-answer no-answer-preview-page",
@@ -69,9 +90,87 @@ var PreviewRadio = ({ question }) => {
69
90
  ] });
70
91
  };
71
92
 
72
- // src/components/input-components/CheckboxGroupStandard/CheckboxGroupStandard.tsx
93
+ // src/components/input-components/MultipleCheckboxesStandard/MultipleCheckboxesStandard.tsx
73
94
  import { useEffect, useState } from "react";
74
- import { Fragment as Fragment2, jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
95
+ import { Fragment as Fragment2, jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
96
+ var MultipleCheckboxes = ({
97
+ question,
98
+ handleQuestionInputChange,
99
+ showPreview = false,
100
+ activatedLanguage = "sv"
101
+ }) => {
102
+ var _a;
103
+ const questionId = `question-${question.id}`;
104
+ const [checkedValues, setCheckedValues] = useState([]);
105
+ useEffect(() => {
106
+ var _a2;
107
+ const initialValues = ((_a2 = question.options) == null ? void 0 : _a2.filter((option) => {
108
+ var _a3;
109
+ return (_a3 = question.answer) == null ? void 0 : _a3.includes(option.label);
110
+ }).map((option) => option.label)) || [];
111
+ console.log("Initial values:", initialValues);
112
+ setCheckedValues(initialValues);
113
+ }, [question.answer, question.options]);
114
+ const handleInputChange = (event, optionValue) => {
115
+ let updatedValues = [...checkedValues];
116
+ if (updatedValues.includes(optionValue)) {
117
+ updatedValues = updatedValues.filter((val) => val !== optionValue);
118
+ } else {
119
+ updatedValues.push(optionValue);
120
+ }
121
+ setCheckedValues(updatedValues);
122
+ const e = { target: { value: updatedValues.toString() } };
123
+ handleQuestionInputChange(e, question);
124
+ };
125
+ return /* @__PURE__ */ jsxs3(Fragment2, { children: [
126
+ !showPreview && question.visible && /* @__PURE__ */ jsx3("div", { id: questionId, className: "pts-root-question pts-multipleCheckboxes-container", children: /* @__PURE__ */ jsxs3("fieldset", { children: [
127
+ /* @__PURE__ */ jsxs3("legend", { className: "multipleCheckboxes-legend", id: `label-${questionId}`, children: [
128
+ question.questionLabel,
129
+ " ",
130
+ question.isQuestionMandatory && /* @__PURE__ */ jsx3("span", { "aria-hidden": true, className: "pts-root-mandatoryAsterisk", children: "*" }),
131
+ " "
132
+ ] }),
133
+ /* @__PURE__ */ jsx3("ul", { children: (_a = question.options) == null ? void 0 : _a.map((option, index) => /* @__PURE__ */ jsx3("li", { children: /* @__PURE__ */ jsxs3(Fragment2, { children: [
134
+ " ",
135
+ /* @__PURE__ */ jsx3(
136
+ "input",
137
+ {
138
+ type: "checkbox",
139
+ name: `${question.id}-option`,
140
+ id: `${question.id}-option-${index}`,
141
+ value: option.label,
142
+ checked: checkedValues.includes(option.label),
143
+ onChange: (e) => handleInputChange(e, option.label),
144
+ className: question.hasValidationError ? "pts-root-question-input-error-border" : void 0
145
+ }
146
+ ),
147
+ /* @__PURE__ */ jsx3("label", { htmlFor: `${question.id}-option-${index}`, children: option.label })
148
+ ] }) }, index)) })
149
+ ] }) }),
150
+ " ",
151
+ showPreview && /* @__PURE__ */ jsx3(PrevieMultipleCheckboxes, { activatedLanguage, question })
152
+ ] });
153
+ };
154
+ var MultipleCheckboxesStandard_default = MultipleCheckboxes;
155
+ var PrevieMultipleCheckboxes = ({
156
+ question,
157
+ activatedLanguage
158
+ }) => {
159
+ var _a, _b;
160
+ const previewId = `preview-${question.id}`;
161
+ return /* @__PURE__ */ jsxs3(Fragment2, { children: [
162
+ /* @__PURE__ */ jsx3("dt", { id: `question-${previewId}`, children: (_a = question.previewLabel) != null ? _a : question.questionLabel }),
163
+ question.answer ? question.options && question.options.length === 1 ? /* @__PURE__ */ jsx3("dd", { children: question.options[0].label }) : /* @__PURE__ */ jsx3("dd", { children: /* @__PURE__ */ jsx3("ul", { className: "pts-preview-answer-list", children: (_b = question.options) == null ? void 0 : _b.filter((option) => {
164
+ var _a2;
165
+ return (_a2 = question.answer) == null ? void 0 : _a2.includes(option.label);
166
+ }).map((option, index) => /* @__PURE__ */ jsx3("li", { children: option.label }, index)) }) }) : /* @__PURE__ */ jsx3("dd", { className: "no-answer-preview-page", children: activatedLanguage === "en" ? "No Answer" : "Inget svar" }),
167
+ " "
168
+ ] });
169
+ };
170
+
171
+ // src/components/input-components/CheckboxGroupStandard/CheckboxGroupStandard.tsx
172
+ import { useEffect as useEffect2, useState as useState2 } from "react";
173
+ import { Fragment as Fragment3, jsx as jsx4, jsxs as jsxs4 } from "react/jsx-runtime";
75
174
  var CheckboxGroup = ({
76
175
  question,
77
176
  handleQuestionInputChange,
@@ -82,8 +181,8 @@ var CheckboxGroup = ({
82
181
  const questionId = `question-${question.id}`;
83
182
  const errorId = `error-${question.id}`;
84
183
  const groupId = `checkbox-group-${question.id}`;
85
- const [checkedValues, setCheckedValues] = useState([]);
86
- useEffect(() => {
184
+ const [checkedValues, setCheckedValues] = useState2([]);
185
+ useEffect2(() => {
87
186
  var _a2;
88
187
  const initialValues = ((_a2 = question.options) == null ? void 0 : _a2.filter((option) => {
89
188
  var _a3;
@@ -102,21 +201,21 @@ var CheckboxGroup = ({
102
201
  const e = { target: { value: updatedValues.toString() } };
103
202
  handleQuestionInputChange(e, question);
104
203
  };
105
- return /* @__PURE__ */ jsxs2(Fragment2, { children: [
106
- !showPreview && question.visible && /* @__PURE__ */ jsx2("div", { id: questionId, className: "pts-root-question pts-checkboxGroup-container", children: /* @__PURE__ */ jsxs2(
204
+ return /* @__PURE__ */ jsxs4(Fragment3, { children: [
205
+ !showPreview && question.visible && /* @__PURE__ */ jsx4("div", { id: questionId, className: "pts-root-question pts-checkboxGroup-container", children: /* @__PURE__ */ jsxs4(
107
206
  "fieldset",
108
207
  {
109
208
  "aria-required": question.isQuestionMandatory,
110
209
  "aria-invalid": question.hasValidationError ? question.hasValidationError : void 0,
111
210
  "aria-errormessage": question.hasValidationError ? errorId : void 0,
112
211
  children: [
113
- /* @__PURE__ */ jsxs2("legend", { className: "pts-checkboxGroup-legend", id: `label-${groupId}`, children: [
212
+ /* @__PURE__ */ jsxs4("legend", { className: "pts-checkboxGroup-legend", id: `label-${groupId}`, children: [
114
213
  question.questionLabel,
115
214
  " ",
116
- question.isQuestionMandatory && /* @__PURE__ */ jsx2("span", { "aria-hidden": true, className: "pts-root-mandatoryAsterisk", children: "*" })
215
+ question.isQuestionMandatory && /* @__PURE__ */ jsx4("span", { "aria-hidden": true, className: "pts-root-mandatoryAsterisk", children: "*" })
117
216
  ] }),
118
- (_a = question.options) == null ? void 0 : _a.map((option, index) => /* @__PURE__ */ jsxs2("div", { className: "pts-checkboxGroup-options", children: [
119
- /* @__PURE__ */ jsx2(
217
+ (_a = question.options) == null ? void 0 : _a.map((option, index) => /* @__PURE__ */ jsxs4("div", { className: "pts-checkboxGroup-options", children: [
218
+ /* @__PURE__ */ jsx4(
120
219
  "input",
121
220
  {
122
221
  type: "checkbox",
@@ -128,17 +227,17 @@ var CheckboxGroup = ({
128
227
  className: question.hasValidationError ? "pts-root-question-input-error-border" : void 0
129
228
  }
130
229
  ),
131
- /* @__PURE__ */ jsx2("label", { htmlFor: `${groupId}-option-${index}`, children: option.label })
230
+ /* @__PURE__ */ jsx4("label", { htmlFor: `${groupId}-option-${index}`, children: option.label })
132
231
  ] }, index)),
133
- question.hasValidationError && /* @__PURE__ */ jsxs2("div", { className: "pts-root-error", id: errorId, children: [
134
- /* @__PURE__ */ jsx2("span", { "aria-hidden": true, className: "errorDot", children: "!" }),
135
- /* @__PURE__ */ jsx2("span", { className: "sr-only", children: "Valideringsfel" }),
136
- /* @__PURE__ */ jsx2("span", { className: "errorText", children: question.validationDefaultMessesege })
232
+ question.hasValidationError && /* @__PURE__ */ jsxs4("div", { className: "pts-root-error", id: errorId, children: [
233
+ /* @__PURE__ */ jsx4("span", { "aria-hidden": true, className: "errorDot", children: "!" }),
234
+ /* @__PURE__ */ jsx4("span", { className: "sr-only", children: "Valideringsfel" }),
235
+ /* @__PURE__ */ jsx4("span", { className: "errorText", children: question.validationDefaultMessesege })
137
236
  ] })
138
237
  ]
139
238
  }
140
239
  ) }),
141
- showPreview && /* @__PURE__ */ jsx2(PreviewCheckboxGroup, { activatedLanguage, question })
240
+ showPreview && /* @__PURE__ */ jsx4(PreviewCheckboxGroup, { activatedLanguage, question })
142
241
  ] });
143
242
  };
144
243
  var CheckboxGroupStandard_default = CheckboxGroup;
@@ -148,19 +247,19 @@ var PreviewCheckboxGroup = ({
148
247
  }) => {
149
248
  var _a, _b;
150
249
  const previewId = `preview-${question.id}`;
151
- return /* @__PURE__ */ jsxs2(Fragment2, { children: [
152
- /* @__PURE__ */ jsx2("dt", { id: `question-${previewId}`, children: (_a = question.previewLabel) != null ? _a : question.questionLabel }),
153
- question.answer ? question.options && question.options.length === 1 ? /* @__PURE__ */ jsx2("dd", { children: question.options[0].label }) : /* @__PURE__ */ jsx2("dd", { children: /* @__PURE__ */ jsx2("ul", { className: "pts-preview-answer-list", children: (_b = question.options) == null ? void 0 : _b.filter((option) => {
250
+ return /* @__PURE__ */ jsxs4(Fragment3, { children: [
251
+ /* @__PURE__ */ jsx4("dt", { id: `question-${previewId}`, children: (_a = question.previewLabel) != null ? _a : question.questionLabel }),
252
+ question.answer ? question.options && question.options.length === 1 ? /* @__PURE__ */ jsx4("dd", { children: question.options[0].label }) : /* @__PURE__ */ jsx4("dd", { children: /* @__PURE__ */ jsx4("ul", { className: "pts-preview-answer-list", children: (_b = question.options) == null ? void 0 : _b.filter((option) => {
154
253
  var _a2;
155
254
  return (_a2 = question.answer) == null ? void 0 : _a2.includes(option.label);
156
- }).map((option, index) => /* @__PURE__ */ jsx2("li", { children: option.label }, index)) }) }) : /* @__PURE__ */ jsx2("dd", { className: "no-answer-preview-page", children: activatedLanguage === "en" ? "No Answer" : "Inget svar" }),
255
+ }).map((option, index) => /* @__PURE__ */ jsx4("li", { children: option.label }, index)) }) }) : /* @__PURE__ */ jsx4("dd", { className: "no-answer-preview-page", children: activatedLanguage === "en" ? "No Answer" : "Inget svar" }),
157
256
  " "
158
257
  ] });
159
258
  };
160
259
 
161
260
  // src/components/input-components/TextAreaStandard/TextAreaStandard.tsx
162
261
  import DOMPurify from "dompurify";
163
- import { Fragment as Fragment3, jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
262
+ import { Fragment as Fragment4, jsx as jsx5, jsxs as jsxs5 } from "react/jsx-runtime";
164
263
  var InputTextarea = ({
165
264
  question,
166
265
  handleQuestionInputChange,
@@ -173,19 +272,19 @@ var InputTextarea = ({
173
272
  const aboutId = `about-${question.id}`;
174
273
  const errorId = `error-${question.id}`;
175
274
  const defaultMaxLength = 1e3;
176
- return /* @__PURE__ */ jsxs3(Fragment3, { children: [
177
- !showPreview && question.visible && /* @__PURE__ */ jsxs3(
275
+ return /* @__PURE__ */ jsxs5(Fragment4, { children: [
276
+ !showPreview && question.visible && /* @__PURE__ */ jsxs5(
178
277
  "div",
179
278
  {
180
279
  id: questionId,
181
280
  className: `pts-root-question pts-textArea-container${question.aboutText ? " pts-question-hasAbout" : ""}`,
182
281
  children: [
183
- /* @__PURE__ */ jsxs3("label", { htmlFor: inputId, children: [
282
+ /* @__PURE__ */ jsxs5("label", { htmlFor: inputId, children: [
184
283
  question.questionLabel,
185
284
  " ",
186
- question.isQuestionMandatory && /* @__PURE__ */ jsx3("span", { className: "pts-root-mandatoryAsterisk", "aria-hidden": "true", children: "*" })
285
+ question.isQuestionMandatory && /* @__PURE__ */ jsx5("span", { className: "pts-root-mandatoryAsterisk", "aria-hidden": "true", children: "*" })
187
286
  ] }),
188
- question.aboutText && /* @__PURE__ */ jsx3(
287
+ question.aboutText && /* @__PURE__ */ jsx5(
189
288
  "div",
190
289
  {
191
290
  id: aboutId,
@@ -195,7 +294,7 @@ var InputTextarea = ({
195
294
  }
196
295
  }
197
296
  ),
198
- /* @__PURE__ */ jsx3(
297
+ /* @__PURE__ */ jsx5(
199
298
  "textarea",
200
299
  {
201
300
  className: question.hasValidationError ? "pts-root-question-input-error-border" : void 0,
@@ -209,12 +308,12 @@ var InputTextarea = ({
209
308
  id: inputId
210
309
  }
211
310
  ),
212
- /* @__PURE__ */ jsxs3("div", { className: "pts-textarea-counter-error-container", children: [
213
- question.hasValidationError && /* @__PURE__ */ jsxs3("div", { className: "pts-root-error", id: errorId, children: [
214
- /* @__PURE__ */ jsx3("span", { "aria-label": "Felmeddelande.", className: "errorDot", children: "!" }),
215
- /* @__PURE__ */ jsx3("span", { className: "errorText", children: question.validationDefaultMessesege })
311
+ /* @__PURE__ */ jsxs5("div", { className: "pts-textarea-counter-error-container", children: [
312
+ question.hasValidationError && /* @__PURE__ */ jsxs5("div", { className: "pts-root-error", id: errorId, children: [
313
+ /* @__PURE__ */ jsx5("span", { "aria-label": "Felmeddelande.", className: "errorDot", children: "!" }),
314
+ /* @__PURE__ */ jsx5("span", { className: "errorText", children: question.validationDefaultMessesege })
216
315
  ] }),
217
- !((_b = question.questionExtraAttribute) == null ? void 0 : _b.hideTextCounter) && /* @__PURE__ */ jsxs3(
316
+ !((_b = question.questionExtraAttribute) == null ? void 0 : _b.hideTextCounter) && /* @__PURE__ */ jsxs5(
218
317
  "div",
219
318
  {
220
319
  className: `pts-character-counter ${question.answer && (((_c = question.questionExtraAttribute) == null ? void 0 : _c.answerMaxLength) || defaultMaxLength) && question.answer.length > (((_d = question.questionExtraAttribute) == null ? void 0 : _d.answerMaxLength) || defaultMaxLength) ? "error" : ""}`,
@@ -231,7 +330,7 @@ var InputTextarea = ({
231
330
  ]
232
331
  }
233
332
  ),
234
- showPreview && /* @__PURE__ */ jsx3(PreviewTextarea, { activatedLanguage, question })
333
+ showPreview && /* @__PURE__ */ jsx5(PreviewTextarea, { activatedLanguage, question })
235
334
  ] });
236
335
  };
237
336
  var TextAreaStandard_default = InputTextarea;
@@ -241,9 +340,9 @@ var PreviewTextarea = ({
241
340
  }) => {
242
341
  var _a, _b;
243
342
  const previewId = `preview-${question.id}`;
244
- return /* @__PURE__ */ jsxs3(Fragment3, { children: [
245
- /* @__PURE__ */ jsx3("dt", { id: `question-${previewId}`, children: (_a = question.previewLabel) != null ? _a : question.questionLabel }),
246
- ((_b = question.answer) == null ? void 0 : _b.trim()) ? /* @__PURE__ */ jsx3("dd", { className: "pts-textArea-preview pts-root-answer", id: `answer-${previewId}`, children: question.answer }) : /* @__PURE__ */ jsx3(
343
+ return /* @__PURE__ */ jsxs5(Fragment4, { children: [
344
+ /* @__PURE__ */ jsx5("dt", { id: `question-${previewId}`, children: (_a = question.previewLabel) != null ? _a : question.questionLabel }),
345
+ ((_b = question.answer) == null ? void 0 : _b.trim()) ? /* @__PURE__ */ jsx5("dd", { className: "pts-textArea-preview pts-root-answer", id: `answer-${previewId}`, children: question.answer }) : /* @__PURE__ */ jsx5(
247
346
  "dd",
248
347
  {
249
348
  className: "pts-textArea-preview pts-root-answer no-answer-preview-page",
@@ -256,7 +355,7 @@ var PreviewTextarea = ({
256
355
 
257
356
  // src/components/input-components/TextFieldStandard/TextFieldStandard.tsx
258
357
  import DOMPurify2 from "dompurify";
259
- import { Fragment as Fragment4, jsx as jsx4, jsxs as jsxs4 } from "react/jsx-runtime";
358
+ import { Fragment as Fragment5, jsx as jsx6, jsxs as jsxs6 } from "react/jsx-runtime";
260
359
  var TextFieldStandard = ({
261
360
  question,
262
361
  handleQuestionInputChange,
@@ -269,19 +368,19 @@ var TextFieldStandard = ({
269
368
  const aboutId = `about-${question.id}`;
270
369
  const errorId = `error-${question.id}`;
271
370
  const defaultMaxLength = 1e3;
272
- return /* @__PURE__ */ jsxs4(Fragment4, { children: [
273
- !showPreview && question.visible && /* @__PURE__ */ jsxs4(
371
+ return /* @__PURE__ */ jsxs6(Fragment5, { children: [
372
+ !showPreview && question.visible && /* @__PURE__ */ jsxs6(
274
373
  "div",
275
374
  {
276
375
  id: questionId,
277
376
  className: `pts-root-question pts-textField-container${((_a = question.questionExtraAttribute) == null ? void 0 : _a.disabled) ? " pts-textField-disabled" : ""}${question.aboutText ? " pts-question-hasAbout" : ""}`.trim(),
278
377
  children: [
279
- /* @__PURE__ */ jsxs4("label", { htmlFor: inputId, children: [
378
+ /* @__PURE__ */ jsxs6("label", { htmlFor: inputId, children: [
280
379
  question.questionLabel,
281
380
  " ",
282
- question.isQuestionMandatory && /* @__PURE__ */ jsx4("span", { "aria-hidden": "true", className: "pts-root-mandatoryAsterisk", children: "*" })
381
+ question.isQuestionMandatory && /* @__PURE__ */ jsx6("span", { "aria-hidden": "true", className: "pts-root-mandatoryAsterisk", children: "*" })
283
382
  ] }),
284
- question.aboutText && /* @__PURE__ */ jsx4(
383
+ question.aboutText && /* @__PURE__ */ jsx6(
285
384
  "div",
286
385
  {
287
386
  id: aboutId,
@@ -291,7 +390,7 @@ var TextFieldStandard = ({
291
390
  }
292
391
  }
293
392
  ),
294
- /* @__PURE__ */ jsx4(
393
+ /* @__PURE__ */ jsx6(
295
394
  "input",
296
395
  {
297
396
  type: (_c = (_b = question.questionExtraAttribute) == null ? void 0 : _b.inputType) != null ? _c : "text",
@@ -313,15 +412,15 @@ var TextFieldStandard = ({
313
412
  autoCapitalize: (_m = (_l = question.questionExtraAttribute) == null ? void 0 : _l.autoCapitalize) != null ? _m : void 0
314
413
  }
315
414
  ),
316
- question.hasValidationError && /* @__PURE__ */ jsxs4("div", { className: "pts-root-error", id: errorId, children: [
317
- /* @__PURE__ */ jsx4("span", { "aria-hidden": true, className: "errorDot", children: "!" }),
318
- /* @__PURE__ */ jsx4("span", { className: "sr-only", children: "Valideringsfel" }),
319
- /* @__PURE__ */ jsx4("span", { className: "errorText", children: question.validationDefaultMessesege })
415
+ question.hasValidationError && /* @__PURE__ */ jsxs6("div", { className: "pts-root-error", id: errorId, children: [
416
+ /* @__PURE__ */ jsx6("span", { "aria-hidden": true, className: "errorDot", children: "!" }),
417
+ /* @__PURE__ */ jsx6("span", { className: "sr-only", children: "Valideringsfel" }),
418
+ /* @__PURE__ */ jsx6("span", { className: "errorText", children: question.validationDefaultMessesege })
320
419
  ] })
321
420
  ]
322
421
  }
323
422
  ),
324
- showPreview && /* @__PURE__ */ jsx4(PreviewTextField, { activatedLanguage, question })
423
+ showPreview && /* @__PURE__ */ jsx6(PreviewTextField, { activatedLanguage, question })
325
424
  ] });
326
425
  };
327
426
  var TextFieldStandard_default = TextFieldStandard;
@@ -331,9 +430,9 @@ var PreviewTextField = ({
331
430
  }) => {
332
431
  var _a, _b;
333
432
  const previewId = `preview-${question.id}`;
334
- return /* @__PURE__ */ jsxs4(Fragment4, { children: [
335
- /* @__PURE__ */ jsx4("dt", { id: `question-${previewId}`, children: (_a = question.previewLabel) != null ? _a : question.questionLabel }),
336
- ((_b = question.answer) == null ? void 0 : _b.trim()) ? /* @__PURE__ */ jsx4("dd", { className: "pts-textField-preview pts-root-answer", id: `answer-${previewId}`, children: question.answer }) : /* @__PURE__ */ jsx4(
433
+ return /* @__PURE__ */ jsxs6(Fragment5, { children: [
434
+ /* @__PURE__ */ jsx6("dt", { id: `question-${previewId}`, children: (_a = question.previewLabel) != null ? _a : question.questionLabel }),
435
+ ((_b = question.answer) == null ? void 0 : _b.trim()) ? /* @__PURE__ */ jsx6("dd", { className: "pts-textField-preview pts-root-answer", id: `answer-${previewId}`, children: question.answer }) : /* @__PURE__ */ jsx6(
337
436
  "dd",
338
437
  {
339
438
  className: "pts-textField-preview pts-root-answer no-answer-preview-page",
@@ -345,12 +444,12 @@ var PreviewTextField = ({
345
444
  };
346
445
 
347
446
  // src/components/input-components/AddFilesStandard/AddFilesStandard.tsx
348
- import { useCallback, useEffect as useEffect4, useState as useState4 } from "react";
447
+ import { useCallback, useEffect as useEffect5, useState as useState5 } from "react";
349
448
  import clsx3 from "clsx";
350
449
 
351
450
  // src/components/input-components/AddFilesStandard/DropFilesStandard.tsx
352
451
  import { useDropzone } from "react-dropzone";
353
- import { Fragment as Fragment5, jsx as jsx5, jsxs as jsxs5 } from "react/jsx-runtime";
452
+ import { Fragment as Fragment6, jsx as jsx7, jsxs as jsxs7 } from "react/jsx-runtime";
354
453
  var DropFiles = ({ FilesSelected, DropFilesText = "Dra och sl\xE4pp dina filer h\xE4r", language }) => {
355
454
  const onDrop = FilesSelected;
356
455
  const { getRootProps, getInputProps, isDragActive } = useDropzone({ onDrop, noKeyboard: true });
@@ -358,10 +457,10 @@ var DropFiles = ({ FilesSelected, DropFilesText = "Dra och sl\xE4pp dina filer h
358
457
  event.preventDefault();
359
458
  event.stopPropagation();
360
459
  };
361
- return /* @__PURE__ */ jsx5(Fragment5, { children: /* @__PURE__ */ jsx5("div", { className: "DropZoneContainer", children: /* @__PURE__ */ jsxs5("div", { className: "DropZone", ...getRootProps(), onClick: handleFileExplorer, children: [
362
- /* @__PURE__ */ jsxs5("label", { htmlFor: "fileDropInput", hidden: true, children: [
460
+ return /* @__PURE__ */ jsx7(Fragment6, { children: /* @__PURE__ */ jsx7("div", { className: "DropZoneContainer", children: /* @__PURE__ */ jsxs7("div", { className: "DropZone", ...getRootProps(), onClick: handleFileExplorer, children: [
461
+ /* @__PURE__ */ jsxs7("label", { htmlFor: "fileDropInput", hidden: true, children: [
363
462
  "Dra och sl\xE4pp filer h\xE4r omr\xE5de",
364
- /* @__PURE__ */ jsx5(
463
+ /* @__PURE__ */ jsx7(
365
464
  "input",
366
465
  {
367
466
  ...getInputProps({
@@ -372,8 +471,8 @@ var DropFiles = ({ FilesSelected, DropFilesText = "Dra och sl\xE4pp dina filer h
372
471
  }
373
472
  )
374
473
  ] }),
375
- isDragActive ? /* @__PURE__ */ jsx5("b", { className: "dropFilesNowText", children: language === "sv" ? "Sl\xE4pp filerna, nu ...!" : "Drop files here!" }) : /* @__PURE__ */ jsxs5("div", { className: "DropZone-label-container", children: [
376
- /* @__PURE__ */ jsx5(
474
+ isDragActive ? /* @__PURE__ */ jsx7("b", { className: "dropFilesNowText", children: language === "sv" ? "Sl\xE4pp filerna, nu ...!" : "Drop files here!" }) : /* @__PURE__ */ jsxs7("div", { className: "DropZone-label-container", children: [
475
+ /* @__PURE__ */ jsx7(
377
476
  "svg",
378
477
  {
379
478
  xmlns: "http://www.w3.org/2000/svg",
@@ -381,7 +480,7 @@ var DropFiles = ({ FilesSelected, DropFilesText = "Dra och sl\xE4pp dina filer h
381
480
  height: "2.4rem",
382
481
  viewBox: "0 0 7 15",
383
482
  fill: "#fff",
384
- children: /* @__PURE__ */ jsx5(
483
+ children: /* @__PURE__ */ jsx7(
385
484
  "path",
386
485
  {
387
486
  d: "M0 2.5C0 1.83696 0.263392 1.20107 0.732233 0.732233C1.20107 0.263392 1.83696 0 2.5 0C3.16304 0 3.79893 0.263392 4.26777 0.732233C4.73661 1.20107 5 1.83696 5 2.5V11.5C5 11.8978 4.84196 12.2794 4.56066 12.5607C4.27936 12.842 3.89782 13 3.5 13C3.10218 13 2.72064 12.842 2.43934 12.5607C2.15804 12.2794 2 11.8978 2 11.5V4.5C2 4.36739 2.05268 4.24021 2.14645 4.14645C2.24021 4.05268 2.36739 4 2.5 4C2.63261 4 2.75979 4.05268 2.85355 4.14645C2.94732 4.24021 3 4.36739 3 4.5V11.5C3 11.6326 3.05268 11.7598 3.14645 11.8536C3.24021 11.9473 3.36739 12 3.5 12C3.63261 12 3.75979 11.9473 3.85355 11.8536C3.94732 11.7598 4 11.6326 4 11.5V2.5C4 2.30302 3.9612 2.10796 3.88582 1.92597C3.81044 1.74399 3.69995 1.57863 3.56066 1.43934C3.42137 1.30005 3.25601 1.18956 3.07403 1.11418C2.89204 1.0388 2.69698 1 2.5 1C2.30302 1 2.10796 1.0388 1.92597 1.11418C1.74399 1.18956 1.57863 1.30005 1.43934 1.43934C1.30005 1.57863 1.18956 1.74399 1.11418 1.92597C1.0388 2.10796 1 2.30302 1 2.5V11.5C1 12.163 1.26339 12.7989 1.73223 13.2678C2.20107 13.7366 2.83696 14 3.5 14C4.16304 14 4.79893 13.7366 5.26777 13.2678C5.73661 12.7989 6 12.163 6 11.5V4.5C6 4.36739 6.05268 4.24021 6.14645 4.14645C6.24021 4.05268 6.36739 4 6.5 4C6.63261 4 6.75979 4.05268 6.85355 4.14645C6.94732 4.24021 7 4.36739 7 4.5V11.5C7 12.4283 6.63125 13.3185 5.97487 13.9749C5.3185 14.6313 4.42826 15 3.5 15C2.57174 15 1.6815 14.6313 1.02513 13.9749C0.368749 13.3185 0 12.4283 0 11.5V2.5Z",
@@ -390,7 +489,7 @@ var DropFiles = ({ FilesSelected, DropFilesText = "Dra och sl\xE4pp dina filer h
390
489
  )
391
490
  }
392
491
  ),
393
- /* @__PURE__ */ jsx5("p", { className: "dropFilesText", children: DropFilesText })
492
+ /* @__PURE__ */ jsx7("p", { className: "dropFilesText", children: DropFilesText })
394
493
  ] })
395
494
  ] }) }) });
396
495
  };
@@ -402,7 +501,7 @@ import clsx from "clsx";
402
501
 
403
502
  // src/components/input-components/AddFilesStandard/ScreenReaderErrors.tsx
404
503
  import React from "react";
405
- import { Fragment as Fragment6, jsx as jsx6 } from "react/jsx-runtime";
504
+ import { Fragment as Fragment7, jsx as jsx8 } from "react/jsx-runtime";
406
505
  var ScreenReaderErrors = ({
407
506
  errorMessageAddingFile,
408
507
  activatedLanguage
@@ -421,12 +520,12 @@ var ScreenReaderErrors = ({
421
520
  setActivateErrorMessagesForScreenReader(true);
422
521
  }
423
522
  }, [errorMessageAddingFile]);
424
- return /* @__PURE__ */ jsx6(Fragment6, { children: activateErrorMessagesForScreenReader && /* @__PURE__ */ jsx6("p", { role: "alert", className: "sr-only", "aria-atomic": "true", children: errorMessagesForScreenReader }) });
523
+ return /* @__PURE__ */ jsx8(Fragment7, { children: activateErrorMessagesForScreenReader && /* @__PURE__ */ jsx8("p", { role: "alert", className: "sr-only", "aria-atomic": "true", children: errorMessagesForScreenReader }) });
425
524
  };
426
525
  var ScreenReaderErrors_default = ScreenReaderErrors;
427
526
 
428
527
  // src/components/input-components/AddFilesStandard/ExploreFilesStandard.tsx
429
- import { Fragment as Fragment7, jsx as jsx7, jsxs as jsxs6 } from "react/jsx-runtime";
528
+ import { Fragment as Fragment8, jsx as jsx9, jsxs as jsxs8 } from "react/jsx-runtime";
430
529
  var ExploreFiles = ({
431
530
  FilesSelected,
432
531
  numberOfFiles,
@@ -453,8 +552,8 @@ var ExploreFiles = ({
453
552
  };
454
553
  let addFilesInfoText = numberOfFiles > 0 ? activatedLanguage === "sv" ? `${numberOfFiles} filer valda (max ${allowedNumberOfFiles})` : `${numberOfFiles} files chosed (max ${allowedNumberOfFiles})` : activatedLanguage === "sv" ? "Ingen fil vald" : "No file chosen";
455
554
  const ariaLabelText = `${activatedLanguage === "sv" ? "V\xE4lj fil" : "Choose file"} ${addFilesInfoText}`;
456
- return /* @__PURE__ */ jsx7(Fragment7, { children: /* @__PURE__ */ jsxs6("div", { className: "inputContainer", children: [
457
- /* @__PURE__ */ jsxs6(
555
+ return /* @__PURE__ */ jsx9(Fragment8, { children: /* @__PURE__ */ jsxs8("div", { className: "inputContainer", children: [
556
+ /* @__PURE__ */ jsxs8(
458
557
  "div",
459
558
  {
460
559
  className: clsx(
@@ -464,7 +563,7 @@ var ExploreFiles = ({
464
563
  ),
465
564
  id: labelId,
466
565
  children: [
467
- /* @__PURE__ */ jsx7(
566
+ /* @__PURE__ */ jsx9(
468
567
  "button",
469
568
  {
470
569
  ref: buttonInputRef,
@@ -479,12 +578,12 @@ var ExploreFiles = ({
479
578
  children: activatedLanguage === "sv" ? "V\xE4lj fil" : "Choose file"
480
579
  }
481
580
  ),
482
- /* @__PURE__ */ jsx7("span", { "aria-hidden": true, className: "filePickText", children: addFilesInfoText }),
483
- /* @__PURE__ */ jsx7("label", { htmlFor: inputId, "aria-hidden": true, className: "invisible" })
581
+ /* @__PURE__ */ jsx9("span", { "aria-hidden": true, className: "filePickText", children: addFilesInfoText }),
582
+ /* @__PURE__ */ jsx9("label", { htmlFor: inputId, "aria-hidden": true, className: "invisible" })
484
583
  ]
485
584
  }
486
585
  ),
487
- /* @__PURE__ */ jsx7(
586
+ /* @__PURE__ */ jsx9(
488
587
  "input",
489
588
  {
490
589
  "aria-hidden": true,
@@ -497,7 +596,7 @@ var ExploreFiles = ({
497
596
  id: inputId
498
597
  }
499
598
  ),
500
- /* @__PURE__ */ jsx7(
599
+ /* @__PURE__ */ jsx9(
501
600
  ScreenReaderErrors_default,
502
601
  {
503
602
  errorMessageAddingFile,
@@ -509,22 +608,22 @@ var ExploreFiles = ({
509
608
  var ExploreFilesStandard_default = ExploreFiles;
510
609
 
511
610
  // src/components/input-components/AddFilesStandard/SelectedFilesStandard.tsx
512
- import React4, { useEffect as useEffect3, useState as useState3, useRef as useRef2 } from "react";
611
+ import React4, { useEffect as useEffect4, useState as useState4, useRef as useRef2 } from "react";
513
612
  import { Col, Row } from "react-bootstrap";
514
613
 
515
614
  // src/components/input-components/AddFilesStandard/IndicatorStandard.tsx
516
- import { useState as useState2 } from "react";
615
+ import { useState as useState3 } from "react";
517
616
  import clsx2 from "clsx";
518
- import { Fragment as Fragment8, jsx as jsx8 } from "react/jsx-runtime";
617
+ import { Fragment as Fragment9, jsx as jsx10 } from "react/jsx-runtime";
519
618
  var Indicator = (filename) => {
520
- const [uploadPercentage, setUploadPercentage] = useState2(0);
521
- const [uploadDone, setUploadDone] = useState2(false);
522
- return /* @__PURE__ */ jsx8(Fragment8, { children: /* @__PURE__ */ jsx8("div", { className: clsx2("uploadIndicator", "uploadDone") }) });
619
+ const [uploadPercentage, setUploadPercentage] = useState3(0);
620
+ const [uploadDone, setUploadDone] = useState3(false);
621
+ return /* @__PURE__ */ jsx10(Fragment9, { children: /* @__PURE__ */ jsx10("div", { className: clsx2("uploadIndicator", "uploadDone") }) });
523
622
  };
524
623
  var IndicatorStandard_default = Indicator;
525
624
 
526
625
  // src/components/input-components/AddFilesStandard/SelectedFilesStandard.tsx
527
- import { Fragment as Fragment9, jsx as jsx9, jsxs as jsxs7 } from "react/jsx-runtime";
626
+ import { Fragment as Fragment10, jsx as jsx11, jsxs as jsxs9 } from "react/jsx-runtime";
528
627
  var SelectedFiles = ({
529
628
  questionObject,
530
629
  isTouched,
@@ -546,13 +645,13 @@ var SelectedFiles = ({
546
645
  isTouched(e, questionObject);
547
646
  removeFile(newCountOfFiles);
548
647
  };
549
- useEffect3(() => {
648
+ useEffect4(() => {
550
649
  var _a;
551
650
  numberOfFiles > 0 && ((_a = theDiv.current) == null ? void 0 : _a.scrollIntoView({ behavior: "smooth", block: "end" }));
552
651
  }, [numberOfFiles]);
553
652
  const useWindowWidth = () => {
554
- const [windowWidth2, setWindowWidth] = useState3(window.innerWidth);
555
- useEffect3(() => {
653
+ const [windowWidth2, setWindowWidth] = useState4(window.innerWidth);
654
+ useEffect4(() => {
556
655
  const handleResize = () => {
557
656
  setWindowWidth(window.innerWidth);
558
657
  };
@@ -564,10 +663,10 @@ var SelectedFiles = ({
564
663
  return windowWidth2;
565
664
  };
566
665
  const windowWidth = useWindowWidth();
567
- return /* @__PURE__ */ jsxs7(Fragment9, { children: [
568
- /* @__PURE__ */ jsx9("div", { children: errorMessageAddingFile.length > 0 && /* @__PURE__ */ jsxs7("div", { className: "pts-errorSummary-container pts-addFile-error-container", children: [
569
- /* @__PURE__ */ jsx9("span", { "aria-hidden": "true", className: "errorDot", children: "!" }),
570
- /* @__PURE__ */ jsx9("div", { className: "addFile-error-list-container", children: /* @__PURE__ */ jsxs7("ul", { "aria-hidden": true, className: "fileListUnorderedList", id: "errorSummary-ul", children: [
666
+ return /* @__PURE__ */ jsxs9(Fragment10, { children: [
667
+ /* @__PURE__ */ jsx11("div", { children: errorMessageAddingFile.length > 0 && /* @__PURE__ */ jsxs9("div", { className: "pts-errorSummary-container pts-addFile-error-container", children: [
668
+ /* @__PURE__ */ jsx11("span", { "aria-hidden": "true", className: "errorDot", children: "!" }),
669
+ /* @__PURE__ */ jsx11("div", { className: "addFile-error-list-container", children: /* @__PURE__ */ jsxs9("ul", { "aria-hidden": true, className: "fileListUnorderedList", id: "errorSummary-ul", children: [
571
670
  " ",
572
671
  errorMessageAddingFile.map((errorObj, index) => {
573
672
  const errorFileName = errorObj.FileName;
@@ -575,9 +674,9 @@ var SelectedFiles = ({
575
674
  mobileFirstFileName = mobileFirstFileName.length > 8 ? mobileFirstFileName.substring(0, 8) + ".." : mobileFirstFileName;
576
675
  const fileType = errorObj.FileName.split(".").pop();
577
676
  mobileFirstFileName = mobileFirstFileName + "." + fileType;
578
- return /* @__PURE__ */ jsx9("li", { children: /* @__PURE__ */ jsx9(React4.Fragment, { children: /* @__PURE__ */ jsx9("div", { children: /* @__PURE__ */ jsx9("div", { className: "fileInListContainer", children: /* @__PURE__ */ jsxs7("div", { className: "fileInList", children: [
579
- /* @__PURE__ */ jsx9(Row, { children: /* @__PURE__ */ jsx9(Col, { children: windowWidth < 768 ? /* @__PURE__ */ jsx9("span", { className: "mobileFirstFileName", children: mobileFirstFileName }) : /* @__PURE__ */ jsx9("span", { className: "desktopFileName", children: errorObj.FileName }) }) }),
580
- /* @__PURE__ */ jsx9(Row, { children: /* @__PURE__ */ jsx9(
677
+ return /* @__PURE__ */ jsx11("li", { children: /* @__PURE__ */ jsx11(React4.Fragment, { children: /* @__PURE__ */ jsx11("div", { children: /* @__PURE__ */ jsx11("div", { className: "fileInListContainer", children: /* @__PURE__ */ jsxs9("div", { className: "fileInList", children: [
678
+ /* @__PURE__ */ jsx11(Row, { children: /* @__PURE__ */ jsx11(Col, { children: windowWidth < 768 ? /* @__PURE__ */ jsx11("span", { className: "mobileFirstFileName", children: mobileFirstFileName }) : /* @__PURE__ */ jsx11("span", { className: "desktopFileName", children: errorObj.FileName }) }) }),
679
+ /* @__PURE__ */ jsx11(Row, { children: /* @__PURE__ */ jsx11(
581
680
  Col,
582
681
  {
583
682
  className: "errorMessageAddingFile",
@@ -592,7 +691,7 @@ var SelectedFiles = ({
592
691
  ] }, index) }) }) }, `error-${errorObj.FileName}-${index}`) });
593
692
  })
594
693
  ] }) }),
595
- /* @__PURE__ */ jsx9("div", { className: "addFile-error-close-button", children: /* @__PURE__ */ jsx9(
694
+ /* @__PURE__ */ jsx11("div", { className: "addFile-error-close-button", children: /* @__PURE__ */ jsx11(
596
695
  "button",
597
696
  {
598
697
  className: "selectedFilesLinkButton error-close",
@@ -600,7 +699,7 @@ var SelectedFiles = ({
600
699
  removeError();
601
700
  },
602
701
  "aria-label": activatedLanguage === "sv" ? `St\xE4ng felmeddelande` : `Close error message`,
603
- children: /* @__PURE__ */ jsx9(
702
+ children: /* @__PURE__ */ jsx11(
604
703
  "svg",
605
704
  {
606
705
  xmlns: "http://www.w3.org/2000/svg",
@@ -608,7 +707,7 @@ var SelectedFiles = ({
608
707
  height: "14",
609
708
  viewBox: "0 0 14 14",
610
709
  fill: "none",
611
- children: /* @__PURE__ */ jsx9(
710
+ children: /* @__PURE__ */ jsx11(
612
711
  "path",
613
712
  {
614
713
  d: "M0.75 12.75L12.75 0.75M0.75 0.75L12.75 12.75",
@@ -622,15 +721,15 @@ var SelectedFiles = ({
622
721
  }
623
722
  ) })
624
723
  ] }) }),
625
- questionObject.files.length > 0 && /* @__PURE__ */ jsx9("ul", { className: "fileListUnorderedList", "aria-label": "Uppladdade filer", children: questionObject.files.map((file, index) => {
724
+ questionObject.files.length > 0 && /* @__PURE__ */ jsx11("ul", { className: "fileListUnorderedList", "aria-label": "Uppladdade filer", children: questionObject.files.map((file, index) => {
626
725
  const indicatorfileName = file.FileName;
627
726
  let mobileFirstFileName = file.FileName.split(".").shift();
628
727
  mobileFirstFileName = mobileFirstFileName.length > 8 ? mobileFirstFileName.substring(0, 8) + ".." : mobileFirstFileName;
629
728
  const fileType = file.FileName.split(".").pop();
630
729
  mobileFirstFileName = mobileFirstFileName + "." + fileType;
631
- return /* @__PURE__ */ jsx9("li", { children: /* @__PURE__ */ jsx9(React4.Fragment, { children: /* @__PURE__ */ jsx9("div", { children: /* @__PURE__ */ jsx9("div", { className: "fileInListContainer", children: /* @__PURE__ */ jsxs7("div", { className: "fileInList", children: [
632
- /* @__PURE__ */ jsxs7("div", { className: "fileItem", children: [
633
- /* @__PURE__ */ jsx9(Col, { style: { maxWidth: "30px" }, children: /* @__PURE__ */ jsx9("span", { "aria-hidden": "true", className: "uploadedDot", children: /* @__PURE__ */ jsx9(
730
+ return /* @__PURE__ */ jsx11("li", { children: /* @__PURE__ */ jsx11(React4.Fragment, { children: /* @__PURE__ */ jsx11("div", { children: /* @__PURE__ */ jsx11("div", { className: "fileInListContainer", children: /* @__PURE__ */ jsxs9("div", { className: "fileInList", children: [
731
+ /* @__PURE__ */ jsxs9("div", { className: "fileItem", children: [
732
+ /* @__PURE__ */ jsx11(Col, { style: { maxWidth: "30px" }, children: /* @__PURE__ */ jsx11("span", { "aria-hidden": "true", className: "uploadedDot", children: /* @__PURE__ */ jsx11(
634
733
  "svg",
635
734
  {
636
735
  xmlns: "http://www.w3.org/2000/svg",
@@ -638,7 +737,7 @@ var SelectedFiles = ({
638
737
  height: "8",
639
738
  viewBox: "0 0 8 8",
640
739
  fill: "none",
641
- children: /* @__PURE__ */ jsx9(
740
+ children: /* @__PURE__ */ jsx11(
642
741
  "path",
643
742
  {
644
743
  d: "M1 4.65913L2.8 6.45913L7 1.35913",
@@ -649,20 +748,20 @@ var SelectedFiles = ({
649
748
  )
650
749
  }
651
750
  ) }) }),
652
- /* @__PURE__ */ jsx9(Col, { children: windowWidth < 768 ? /* @__PURE__ */ jsxs7("span", { className: "mobileFirstFileName", children: [
751
+ /* @__PURE__ */ jsx11(Col, { children: windowWidth < 768 ? /* @__PURE__ */ jsxs9("span", { className: "mobileFirstFileName", children: [
653
752
  mobileFirstFileName,
654
753
  " (",
655
754
  Math.ceil(file.FileSize / (1024 * 1024)),
656
755
  " ",
657
756
  "MB)"
658
- ] }) : /* @__PURE__ */ jsxs7("span", { className: "desktopFileName", children: [
757
+ ] }) : /* @__PURE__ */ jsxs9("span", { className: "desktopFileName", children: [
659
758
  file.FileName,
660
759
  " (",
661
- /* @__PURE__ */ jsx9("span", { className: "fileSizeText", children: file.FileSize < 1024 * 1024 ? `${Math.round(file.FileSize / 1024)} kB` : `${(file.FileSize / (1024 * 1024)).toFixed(1)} MB` }),
760
+ /* @__PURE__ */ jsx11("span", { className: "fileSizeText", children: file.FileSize < 1024 * 1024 ? `${Math.round(file.FileSize / 1024)} kB` : `${(file.FileSize / (1024 * 1024)).toFixed(1)} MB` }),
662
761
  " ",
663
762
  ")"
664
763
  ] }) }),
665
- /* @__PURE__ */ jsx9(Col, { className: "lastCol", children: /* @__PURE__ */ jsx9(
764
+ /* @__PURE__ */ jsx11(Col, { className: "lastCol", children: /* @__PURE__ */ jsx11(
666
765
  "button",
667
766
  {
668
767
  className: "selectedFilesLinkButton",
@@ -672,17 +771,17 @@ var SelectedFiles = ({
672
771
  }
673
772
  ) })
674
773
  ] }),
675
- showIndicator && /* @__PURE__ */ jsx9(Row, { children: /* @__PURE__ */ jsx9(Col, { style: { width: "100%", padding: 0 }, children: /* @__PURE__ */ jsx9(IndicatorStandard_default, { filename: indicatorfileName }) }) }),
676
- /* @__PURE__ */ jsx9(Row, { style: { marginTop: "12px", marginBottom: "12px" }, children: /* @__PURE__ */ jsx9(Col, { className: "makeSpace" }) })
774
+ showIndicator && /* @__PURE__ */ jsx11(Row, { children: /* @__PURE__ */ jsx11(Col, { style: { width: "100%", padding: 0 }, children: /* @__PURE__ */ jsx11(IndicatorStandard_default, { filename: indicatorfileName }) }) }),
775
+ /* @__PURE__ */ jsx11(Row, { style: { marginTop: "12px", marginBottom: "12px" }, children: /* @__PURE__ */ jsx11(Col, { className: "makeSpace" }) })
677
776
  ] }, index) }) }) }, `file-${file.FileName}-${index}`) });
678
777
  }) }),
679
- /* @__PURE__ */ jsx9("div", { ref: theDiv, className: "pts-clipboard-container" })
778
+ /* @__PURE__ */ jsx11("div", { ref: theDiv, className: "pts-clipboard-container" })
680
779
  ] });
681
780
  };
682
781
  var SelectedFilesStandard_default = SelectedFiles;
683
782
 
684
783
  // src/components/input-components/AddFilesStandard/AddFilesStandard.tsx
685
- import { Fragment as Fragment10, jsx as jsx10, jsxs as jsxs8 } from "react/jsx-runtime";
784
+ import { Fragment as Fragment11, jsx as jsx12, jsxs as jsxs10 } from "react/jsx-runtime";
686
785
  var AddFiles = ({
687
786
  questionObject,
688
787
  handleQuestionInputChange = (e, questionObject2) => {
@@ -720,19 +819,19 @@ var AddFiles = ({
720
819
  const errorId = `error-${questionObject.id}`;
721
820
  const labelId = `label-${questionObject.id}`;
722
821
  const maxSizeMB = Math.round(allowedTotalFileSize / 1048576);
723
- const [numberOfFiles, setNumberOfFiles] = useState4(0);
724
- const [totalFileSize, setTotalFileSize] = useState4(0);
725
- const [errorMessageAddingFile, setErrorMessageAddingFile] = useState4([]);
726
- const [newFiles, setNewFiles] = useState4([]);
727
- const [dropFilesText, setDropFilesText] = useState4("Dra och sl\xE4pp dina filer h\xE4r");
728
- useEffect4(() => {
822
+ const [numberOfFiles, setNumberOfFiles] = useState5(0);
823
+ const [totalFileSize, setTotalFileSize] = useState5(0);
824
+ const [errorMessageAddingFile, setErrorMessageAddingFile] = useState5([]);
825
+ const [newFiles, setNewFiles] = useState5([]);
826
+ const [dropFilesText, setDropFilesText] = useState5("Dra och sl\xE4pp dina filer h\xE4r");
827
+ useEffect5(() => {
729
828
  if (activatedLanguage === "sv") {
730
829
  setDropFilesText("Dra och sl\xE4pp dina filer h\xE4r");
731
830
  } else {
732
831
  setDropFilesText("Drag and drop your files here");
733
832
  }
734
833
  }, [activatedLanguage]);
735
- useEffect4(() => {
834
+ useEffect5(() => {
736
835
  if (questionObject.files && questionObject.files.length > 0) {
737
836
  setNumberOfFiles(questionObject.files.length);
738
837
  }
@@ -827,7 +926,7 @@ var AddFiles = ({
827
926
  reader.readAsDataURL(file);
828
927
  });
829
928
  };
830
- useEffect4(() => {
929
+ useEffect5(() => {
831
930
  if (newFiles.length > 0) {
832
931
  const currentFiles = questionObject.files ? questionObject.files : [];
833
932
  const e = {
@@ -854,9 +953,9 @@ var AddFiles = ({
854
953
  const handleRemoveErrors = () => {
855
954
  setErrorMessageAddingFile([]);
856
955
  };
857
- return /* @__PURE__ */ jsxs8(Fragment10, { children: [
858
- !showPreview && visible && /* @__PURE__ */ jsx10("div", { className: "root-question addFile-question-container", children: /* @__PURE__ */ jsxs8("div", { role: "group", children: [
859
- questionObject.aboutText && /* @__PURE__ */ jsxs8(
956
+ return /* @__PURE__ */ jsxs10(Fragment11, { children: [
957
+ !showPreview && visible && /* @__PURE__ */ jsx12("div", { className: "root-question addFile-question-container", id: `question-${questionObject.id}`, children: /* @__PURE__ */ jsxs10("div", { role: "group", children: [
958
+ questionObject.aboutText && /* @__PURE__ */ jsxs10(
860
959
  "p",
861
960
  {
862
961
  id: aboutId,
@@ -866,19 +965,19 @@ var AddFiles = ({
866
965
  ),
867
966
  children: [
868
967
  questionObject.aboutText,
869
- questionObject.isQuestionMandatory && /* @__PURE__ */ jsxs8("span", { className: "pts-root-mandatoryAsterisk", "aria-hidden": "true", children: [
968
+ questionObject.isQuestionMandatory && /* @__PURE__ */ jsxs10("span", { className: "pts-root-mandatoryAsterisk", "aria-label": "Obligatorisk fr\xE5ga", children: [
870
969
  " ",
871
970
  "*"
872
971
  ] })
873
972
  ]
874
973
  }
875
974
  ),
876
- questionObject.hasValidationError && /* @__PURE__ */ jsxs8("div", { className: "pts-root-error error addfileserror", id: errorId, children: [
877
- /* @__PURE__ */ jsx10("span", { "aria-hidden": true, className: "errorDot", children: "!" }),
878
- /* @__PURE__ */ jsx10("span", { className: "sr-only", children: "Valideringsfel" }),
879
- /* @__PURE__ */ jsx10("span", { className: "errorText", children: questionObject.validationDefaultMessesege })
975
+ questionObject.hasValidationError && /* @__PURE__ */ jsxs10("div", { className: "pts-root-error error addfileserror", id: errorId, children: [
976
+ /* @__PURE__ */ jsx12("span", { "aria-hidden": true, className: "errorDot", children: "!" }),
977
+ /* @__PURE__ */ jsx12("span", { className: "sr-only", children: "Valideringsfel" }),
978
+ /* @__PURE__ */ jsx12("span", { className: "errorText", children: questionObject.validationDefaultMessesege })
880
979
  ] }),
881
- /* @__PURE__ */ jsx10(
980
+ /* @__PURE__ */ jsx12(
882
981
  ExploreFilesStandard_default,
883
982
  {
884
983
  FilesSelected: onDrop,
@@ -894,7 +993,7 @@ var AddFiles = ({
894
993
  removeUploadErrors: handleRemoveErrors
895
994
  }
896
995
  ),
897
- /* @__PURE__ */ jsx10(
996
+ /* @__PURE__ */ jsx12(
898
997
  DropFilesStandard_default,
899
998
  {
900
999
  FilesSelected: onDrop,
@@ -902,7 +1001,7 @@ var AddFiles = ({
902
1001
  language: activatedLanguage
903
1002
  }
904
1003
  ),
905
- /* @__PURE__ */ jsx10(
1004
+ /* @__PURE__ */ jsx12(
906
1005
  SelectedFilesStandard_default,
907
1006
  {
908
1007
  questionObject,
@@ -917,7 +1016,7 @@ var AddFiles = ({
917
1016
  }
918
1017
  )
919
1018
  ] }) }),
920
- showPreview && /* @__PURE__ */ jsx10(PreviewAddFiles, { activatedLanguage, questionObject })
1019
+ showPreview && /* @__PURE__ */ jsx12(PreviewAddFiles, { activatedLanguage, questionObject })
921
1020
  ] });
922
1021
  };
923
1022
  var AddFilesStandard_default = AddFiles;
@@ -926,17 +1025,17 @@ var PreviewAddFiles = ({
926
1025
  activatedLanguage
927
1026
  }) => {
928
1027
  const previewId = `preview-${questionObject.Id}`;
929
- return /* @__PURE__ */ jsxs8(Fragment10, { children: [
930
- /* @__PURE__ */ jsx10("dt", { id: `question-${previewId}`, children: questionObject.questionLabel ? questionObject.questionLabel : activatedLanguage === "en" ? "Attached files" : "Bifogade filer" }),
931
- questionObject.files && questionObject.files.length > 0 ? /* @__PURE__ */ jsx10("dd", { className: "pts-addFiles-answer", children: /* @__PURE__ */ jsx10("ul", { "aria-labelledby": previewId, className: "pts-preview-answer-list", children: questionObject.files.map((file, index) => {
932
- return /* @__PURE__ */ jsx10("li", { children: file.FileName }, `file-${index}-${file.FileName}`);
933
- }) }) }) : /* @__PURE__ */ jsx10("dd", { className: "no-answer-preview-page", children: activatedLanguage === "en" ? "No attached files" : "Inga bifogade filer" })
1028
+ return /* @__PURE__ */ jsxs10(Fragment11, { children: [
1029
+ /* @__PURE__ */ jsx12("dt", { id: `question-${previewId}`, children: questionObject.questionLabel ? questionObject.questionLabel : activatedLanguage === "en" ? "Attached files" : "Bifogade filer" }),
1030
+ questionObject.files && questionObject.files.length > 0 ? /* @__PURE__ */ jsx12("dd", { className: "pts-addFiles-answer", children: /* @__PURE__ */ jsx12("ul", { "aria-labelledby": previewId, className: "pts-preview-answer-list", children: questionObject.files.map((file, index) => {
1031
+ return /* @__PURE__ */ jsx12("li", { children: file.FileName }, `file-${index}-${file.FileName}`);
1032
+ }) }) }) : /* @__PURE__ */ jsx12("dd", { className: "no-answer-preview-page", children: activatedLanguage === "en" ? "No attached files" : "Inga bifogade filer" })
934
1033
  ] });
935
1034
  };
936
1035
 
937
1036
  // src/components/input-components/SingleCheckboxStandard/SingleCheckboxStandard.tsx
938
- import { useEffect as useEffect5, useState as useState5 } from "react";
939
- import { Fragment as Fragment11, jsx as jsx11, jsxs as jsxs9 } from "react/jsx-runtime";
1037
+ import { useEffect as useEffect6, useState as useState6 } from "react";
1038
+ import { Fragment as Fragment12, jsx as jsx13, jsxs as jsxs11 } from "react/jsx-runtime";
940
1039
  var SingleCheckbox = ({
941
1040
  question,
942
1041
  handleQuestionInputChange,
@@ -948,8 +1047,8 @@ var SingleCheckbox = ({
948
1047
  const inputId = `checkbox-${question.id}`;
949
1048
  const aboutId = `about-${question.id}`;
950
1049
  const errorId = `error-${question.id}`;
951
- const [checked, setChecked] = useState5(false);
952
- useEffect5(() => {
1050
+ const [checked, setChecked] = useState6(false);
1051
+ useEffect6(() => {
953
1052
  if (question.answer && question.answer === "true") {
954
1053
  setChecked(true);
955
1054
  } else {
@@ -962,10 +1061,10 @@ var SingleCheckbox = ({
962
1061
  const e = { target: { value: answer } };
963
1062
  handleQuestionInputChange(e, question);
964
1063
  };
965
- return /* @__PURE__ */ jsxs9(Fragment11, { children: [
966
- !showPreview && question.visible && /* @__PURE__ */ jsxs9("div", { id: questionId, className: "pts-root-question pts-singleCheckbox-container", children: [
967
- /* @__PURE__ */ jsxs9("div", { className: "pts-singleCheckbox-row", children: [
968
- /* @__PURE__ */ jsx11(
1064
+ return /* @__PURE__ */ jsxs11(Fragment12, { children: [
1065
+ !showPreview && question.visible && /* @__PURE__ */ jsxs11("div", { id: questionId, className: "pts-root-question pts-singleCheckbox-container", children: [
1066
+ /* @__PURE__ */ jsxs11("div", { className: "pts-singleCheckbox-row", children: [
1067
+ /* @__PURE__ */ jsx13(
969
1068
  "input",
970
1069
  {
971
1070
  type: "checkbox",
@@ -983,11 +1082,11 @@ var SingleCheckbox = ({
983
1082
  "aria-errormessage": question.hasValidationError ? errorId : void 0
984
1083
  }
985
1084
  ),
986
- /* @__PURE__ */ jsx11("label", { htmlFor: `${inputId}`, children: question.questionLabel }),
987
- question.isQuestionMandatory && /* @__PURE__ */ jsx11("span", { "aria-hidden": true, className: "pts-root-mandatoryAsterisk", children: "*" }),
1085
+ /* @__PURE__ */ jsx13("label", { htmlFor: `${inputId}`, children: question.questionLabel }),
1086
+ question.isQuestionMandatory && /* @__PURE__ */ jsx13("span", { "aria-hidden": true, className: "pts-root-mandatoryAsterisk", children: "*" }),
988
1087
  " "
989
1088
  ] }),
990
- question.aboutText && /* @__PURE__ */ jsx11(
1089
+ question.aboutText && /* @__PURE__ */ jsx13(
991
1090
  "div",
992
1091
  {
993
1092
  id: aboutId,
@@ -996,15 +1095,15 @@ var SingleCheckbox = ({
996
1095
  }
997
1096
  ),
998
1097
  " ",
999
- question.hasValidationError && /* @__PURE__ */ jsxs9("div", { className: "pts-root-error", id: errorId, children: [
1000
- /* @__PURE__ */ jsx11("span", { "aria-hidden": true, className: "errorDot", children: "!" }),
1001
- /* @__PURE__ */ jsx11("span", { className: "sr-only", children: "Valideringsfel" }),
1002
- /* @__PURE__ */ jsx11("span", { className: "errorText", children: question.validationDefaultMessesege })
1098
+ question.hasValidationError && /* @__PURE__ */ jsxs11("div", { className: "pts-root-error", id: errorId, children: [
1099
+ /* @__PURE__ */ jsx13("span", { "aria-hidden": true, className: "errorDot", children: "!" }),
1100
+ /* @__PURE__ */ jsx13("span", { className: "sr-only", children: "Valideringsfel" }),
1101
+ /* @__PURE__ */ jsx13("span", { className: "errorText", children: question.validationDefaultMessesege })
1003
1102
  ] }),
1004
1103
  " "
1005
1104
  ] }),
1006
1105
  " ",
1007
- showPreview && /* @__PURE__ */ jsx11(PreviewSingleCheckbox, { activatedLanguage, question })
1106
+ showPreview && /* @__PURE__ */ jsx13(PreviewSingleCheckbox, { activatedLanguage, question })
1008
1107
  ] });
1009
1108
  };
1010
1109
  var SingleCheckboxStandard_default = SingleCheckbox;
@@ -1014,9 +1113,9 @@ var PreviewSingleCheckbox = ({
1014
1113
  }) => {
1015
1114
  var _a, _b;
1016
1115
  const previewId = `preview-${question.id}`;
1017
- return /* @__PURE__ */ jsxs9(Fragment11, { children: [
1018
- /* @__PURE__ */ jsx11("dt", { id: `question-${previewId}`, children: (_a = question.previewLabel) != null ? _a : question.questionLabel }),
1019
- ((_b = question.answer) == null ? void 0 : _b.trim()) ? /* @__PURE__ */ jsx11("dd", { className: "pts-singleCheckbox-preview pts-root-answer", id: `answer-${previewId}`, children: question.answer === "false" ? activatedLanguage === "sv" ? "Nej" : "No" : activatedLanguage === "sv" ? "Ja" : "Yes" }) : /* @__PURE__ */ jsx11(
1116
+ return /* @__PURE__ */ jsxs11(Fragment12, { children: [
1117
+ /* @__PURE__ */ jsx13("dt", { id: `question-${previewId}`, children: (_a = question.previewLabel) != null ? _a : question.questionLabel }),
1118
+ ((_b = question.answer) == null ? void 0 : _b.trim()) ? /* @__PURE__ */ jsx13("dd", { className: "pts-singleCheckbox-preview pts-root-answer", id: `answer-${previewId}`, children: question.answer === "false" ? activatedLanguage === "sv" ? "Nej" : "No" : activatedLanguage === "sv" ? "Ja" : "Yes" }) : /* @__PURE__ */ jsx13(
1020
1119
  "dd",
1021
1120
  {
1022
1121
  className: "pts-singleCheckbox-preview pts-root-answer",
@@ -1027,154 +1126,6 @@ var PreviewSingleCheckbox = ({
1027
1126
  ] });
1028
1127
  };
1029
1128
 
1030
- // src/components/input-components/DropdownStandard/DropdownStandard.tsx
1031
- import { Fragment as Fragment12, jsx as jsx12, jsxs as jsxs10 } from "react/jsx-runtime";
1032
- var CustomDropdownStandard = ({
1033
- question,
1034
- handleQuestionInputChange,
1035
- showPreview = false
1036
- }) => {
1037
- var _a;
1038
- const questionId = `question-${question.id}`;
1039
- const selectId = `select-${question.id}`;
1040
- const errorId = `error-${question.id}`;
1041
- const handleInputChange = (event) => {
1042
- const e = { target: { value: event.target.value } };
1043
- handleQuestionInputChange(e, question);
1044
- };
1045
- return /* @__PURE__ */ jsxs10(Fragment12, { children: [
1046
- !showPreview && question.visible && /* @__PURE__ */ jsxs10("div", { className: "pts-root-question pts-dropdown-container", id: questionId, children: [
1047
- /* @__PURE__ */ jsxs10("label", { htmlFor: selectId, children: [
1048
- question.questionLabel,
1049
- " ",
1050
- question.isQuestionMandatory && /* @__PURE__ */ jsx12("span", { "aria-hidden": true, className: "pts-root-mandatoryAsterisk", children: "*" })
1051
- ] }),
1052
- /* @__PURE__ */ jsxs10(
1053
- "select",
1054
- {
1055
- id: selectId,
1056
- name: `name-${question.id}`,
1057
- value: question.answer || "",
1058
- onChange: handleInputChange,
1059
- "aria-required": question.isQuestionMandatory,
1060
- "aria-invalid": question.hasValidationError ? question.hasValidationError : void 0,
1061
- "aria-errormessage": question.hasValidationError ? errorId : void 0,
1062
- children: [
1063
- /* @__PURE__ */ jsx12("option", { value: "", children: "V\xE4lj ett alternativ" }),
1064
- (_a = question.options) == null ? void 0 : _a.map((option, index) => {
1065
- if (option.value === question.answer) {
1066
- return /* @__PURE__ */ jsx12("option", { value: option.value, selected: true, children: option.label }, index);
1067
- } else {
1068
- return /* @__PURE__ */ jsx12("option", { value: option.value, children: option.label }, index);
1069
- }
1070
- })
1071
- ]
1072
- }
1073
- ),
1074
- question.hasValidationError && /* @__PURE__ */ jsxs10("div", { className: "pts-root-error", id: errorId, children: [
1075
- /* @__PURE__ */ jsx12("span", { "aria-hidden": true, className: "errorDot", children: "!" }),
1076
- /* @__PURE__ */ jsx12("span", { className: "sr-only", children: "Valideringsfel" }),
1077
- /* @__PURE__ */ jsx12("span", { className: "errorText", children: question.validationDefaultMessesege })
1078
- ] })
1079
- ] }),
1080
- showPreview && /* @__PURE__ */ jsx12(PreviewDropdown, { question })
1081
- ] });
1082
- };
1083
- var DropdownStandard_default = CustomDropdownStandard;
1084
- var PreviewDropdown = ({ question }) => {
1085
- var _a, _b;
1086
- const previewId = `preview-${question.id}`;
1087
- return /* @__PURE__ */ jsxs10(Fragment12, { children: [
1088
- /* @__PURE__ */ jsx12("dt", { id: `question-${previewId}`, children: (_a = question.previewLabel) != null ? _a : question.questionLabel }),
1089
- ((_b = question.answer) == null ? void 0 : _b.trim()) ? /* @__PURE__ */ jsx12("dd", { className: "pts-dropdown-preview pts-root-answer", id: `answer-${previewId}`, children: question.answer }) : /* @__PURE__ */ jsx12(
1090
- "dd",
1091
- {
1092
- className: "pts-dropdown-preview pts-root-answer no-answer-preview-page",
1093
- id: `answer-${previewId}`,
1094
- children: "Inget svar"
1095
- }
1096
- )
1097
- ] });
1098
- };
1099
-
1100
- // src/components/input-components/MultipleCheckboxesStandard/MultipleCheckboxesStandard.tsx
1101
- import { useEffect as useEffect6, useState as useState6 } from "react";
1102
- import { Fragment as Fragment13, jsx as jsx13, jsxs as jsxs11 } from "react/jsx-runtime";
1103
- var MultipleCheckboxes = ({
1104
- question,
1105
- handleQuestionInputChange,
1106
- showPreview = false,
1107
- activatedLanguage = "sv"
1108
- }) => {
1109
- var _a;
1110
- const questionId = `question-${question.id}`;
1111
- const [checkedValues, setCheckedValues] = useState6([]);
1112
- useEffect6(() => {
1113
- var _a2;
1114
- const initialValues = ((_a2 = question.options) == null ? void 0 : _a2.filter((option) => {
1115
- var _a3;
1116
- return (_a3 = question.answer) == null ? void 0 : _a3.includes(option.label);
1117
- }).map((option) => option.label)) || [];
1118
- console.log("Initial values:", initialValues);
1119
- setCheckedValues(initialValues);
1120
- }, [question.answer, question.options]);
1121
- const handleInputChange = (event, optionValue) => {
1122
- let updatedValues = [...checkedValues];
1123
- if (updatedValues.includes(optionValue)) {
1124
- updatedValues = updatedValues.filter((val) => val !== optionValue);
1125
- } else {
1126
- updatedValues.push(optionValue);
1127
- }
1128
- setCheckedValues(updatedValues);
1129
- const e = { target: { value: updatedValues.toString() } };
1130
- handleQuestionInputChange(e, question);
1131
- };
1132
- return /* @__PURE__ */ jsxs11(Fragment13, { children: [
1133
- !showPreview && question.visible && /* @__PURE__ */ jsx13("div", { id: questionId, className: "pts-root-question pts-multipleCheckboxes-container", children: /* @__PURE__ */ jsxs11("fieldset", { children: [
1134
- /* @__PURE__ */ jsxs11("legend", { className: "multipleCheckboxes-legend", id: `label-${questionId}`, children: [
1135
- question.questionLabel,
1136
- " ",
1137
- question.isQuestionMandatory && /* @__PURE__ */ jsx13("span", { "aria-hidden": true, className: "pts-root-mandatoryAsterisk", children: "*" }),
1138
- " "
1139
- ] }),
1140
- /* @__PURE__ */ jsx13("ul", { children: (_a = question.options) == null ? void 0 : _a.map((option, index) => /* @__PURE__ */ jsx13("li", { children: /* @__PURE__ */ jsxs11(Fragment13, { children: [
1141
- " ",
1142
- /* @__PURE__ */ jsx13(
1143
- "input",
1144
- {
1145
- type: "checkbox",
1146
- name: `${question.id}-option`,
1147
- id: `${question.id}-option-${index}`,
1148
- value: option.label,
1149
- checked: checkedValues.includes(option.label),
1150
- onChange: (e) => handleInputChange(e, option.label),
1151
- className: question.hasValidationError ? "pts-root-question-input-error-border" : void 0
1152
- }
1153
- ),
1154
- /* @__PURE__ */ jsx13("label", { htmlFor: `${question.id}-option-${index}`, children: option.label })
1155
- ] }) }, index)) })
1156
- ] }) }),
1157
- " ",
1158
- showPreview && /* @__PURE__ */ jsx13(PrevieMultipleCheckboxes, { activatedLanguage, question })
1159
- ] });
1160
- };
1161
- var MultipleCheckboxesStandard_default = MultipleCheckboxes;
1162
- var PrevieMultipleCheckboxes = ({
1163
- question,
1164
- activatedLanguage
1165
- }) => {
1166
- var _a, _b;
1167
- const previewId = `preview-${question.id}`;
1168
- return /* @__PURE__ */ jsxs11(Fragment13, { children: [
1169
- /* @__PURE__ */ jsx13("dt", { id: `question-${previewId}`, children: (_a = question.previewLabel) != null ? _a : question.questionLabel }),
1170
- question.answer ? question.options && question.options.length === 1 ? /* @__PURE__ */ jsx13("dd", { children: question.options[0].label }) : /* @__PURE__ */ jsx13("dd", { children: /* @__PURE__ */ jsx13("ul", { className: "pts-preview-answer-list", children: (_b = question.options) == null ? void 0 : _b.filter((option) => {
1171
- var _a2;
1172
- return (_a2 = question.answer) == null ? void 0 : _a2.includes(option.label);
1173
- }).map((option, index) => /* @__PURE__ */ jsx13("li", { children: option.label }, index)) }) }) : /* @__PURE__ */ jsx13("dd", { className: "no-answer-preview-page", children: activatedLanguage === "en" ? "No Answer" : "Inget svar" }),
1174
- " "
1175
- ] });
1176
- };
1177
-
1178
1129
  // src/helpers/hasQuestionValidationError/hasQuestionValidationError.tsx
1179
1130
  import { isValid, parseISO } from "date-fns";
1180
1131
  var hasQuestionValidationError = (question, questions) => {
@@ -1884,14 +1835,14 @@ var useCookieConsent = ({
1884
1835
  };
1885
1836
 
1886
1837
  // src/components/question-rendering/QuestionRenderer/QuestionRenderer.tsx
1887
- import { Fragment as Fragment14, jsx as jsx14, jsxs as jsxs12 } from "react/jsx-runtime";
1838
+ import { Fragment as Fragment13, jsx as jsx14, jsxs as jsxs12 } from "react/jsx-runtime";
1888
1839
  var QuestionRenderer = ({
1889
1840
  question,
1890
1841
  handleQuestionInputChange,
1891
1842
  activatedLanguage = "sv",
1892
1843
  showPreview = false
1893
1844
  }) => {
1894
- return /* @__PURE__ */ jsxs12(Fragment14, { children: [
1845
+ return /* @__PURE__ */ jsxs12(Fragment13, { children: [
1895
1846
  question.questionType === "Radio" && /* @__PURE__ */ jsx14(
1896
1847
  RadioMultipleStandard_default,
1897
1848
  {
@@ -1953,22 +1904,14 @@ var QuestionRenderer = ({
1953
1904
  handleQuestionInputChange,
1954
1905
  showPreview
1955
1906
  }
1956
- ),
1957
- question.questionType === "Dropdown" && /* @__PURE__ */ jsx14(
1958
- DropdownStandard_default,
1959
- {
1960
- question,
1961
- handleQuestionInputChange,
1962
- showPreview
1963
- }
1964
1907
  )
1965
1908
  ] });
1966
1909
  };
1967
1910
  var QuestionRenderer_default = QuestionRenderer;
1968
1911
 
1969
1912
  // src/components/question-rendering/QuestionGroup/QuestionGroup.tsx
1970
- import { useEffect as useEffect11, Fragment as Fragment15 } from "react";
1971
- import { Fragment as Fragment16, jsx as jsx15, jsxs as jsxs13 } from "react/jsx-runtime";
1913
+ import { useEffect as useEffect11, Fragment as Fragment14 } from "react";
1914
+ import { Fragment as Fragment15, jsx as jsx15, jsxs as jsxs13 } from "react/jsx-runtime";
1972
1915
  var QuestionGroup = ({
1973
1916
  questions,
1974
1917
  wrapperElement = "none",
@@ -1991,8 +1934,8 @@ var QuestionGroup = ({
1991
1934
  }
1992
1935
  });
1993
1936
  }, [questions]);
1994
- const groupQuestions = /* @__PURE__ */ jsx15(Fragment16, { children: questions.map((question, index) => {
1995
- return /* @__PURE__ */ jsx15(Fragment15, { children: /* @__PURE__ */ jsx15(
1937
+ const groupQuestions = /* @__PURE__ */ jsx15(Fragment15, { children: questions.map((question, index) => {
1938
+ return /* @__PURE__ */ jsx15(Fragment14, { children: /* @__PURE__ */ jsx15(
1996
1939
  QuestionRenderer_default,
1997
1940
  {
1998
1941
  question,
@@ -2014,7 +1957,7 @@ var QuestionGroup = ({
2014
1957
  "aria-describedby": firstQuestion.hasValidationError ? `${firstQuestion.id}-error` : void 0,
2015
1958
  children: [
2016
1959
  legendLabel && /* @__PURE__ */ jsxs13("legend", { children: [
2017
- /* @__PURE__ */ jsxs13("span", { className: "pts-legend", children: [
1960
+ /* @__PURE__ */ jsxs13("span", { children: [
2018
1961
  legendLabel,
2019
1962
  groupMandatory && /* @__PURE__ */ jsx15("span", { "aria-hidden": true, className: "pts-root-mandatoryAsterisk", children: "*" })
2020
1963
  ] }),
@@ -2037,7 +1980,7 @@ var QuestionGroup = ({
2037
1980
  return /* @__PURE__ */ jsx15("div", { className: "pts-root-question-group-div", children: groupQuestions });
2038
1981
  case "none":
2039
1982
  default:
2040
- return /* @__PURE__ */ jsx15(Fragment15, { children: groupQuestions });
1983
+ return /* @__PURE__ */ jsx15(Fragment14, { children: groupQuestions });
2041
1984
  }
2042
1985
  };
2043
1986
  var QuestionGroup_default = QuestionGroup;
@@ -2123,86 +2066,89 @@ var CookieBanner_default = CookieBanner;
2123
2066
  // src/components/layout/FooterStandard/FooterStandard.tsx
2124
2067
  import { jsx as jsx17, jsxs as jsxs15 } from "react/jsx-runtime";
2125
2068
  var Footer = ({ activatedLanguage = "sv" }) => {
2126
- return /* @__PURE__ */ jsx17("footer", { className: "pts-footer-container", children: /* @__PURE__ */ jsxs15("div", { className: "pts-footer-content", children: [
2127
- /* @__PURE__ */ jsxs15(
2128
- "svg",
2129
- {
2130
- "aria-label": activatedLanguage === "en" ? "PTS logotype" : "PTS logotyp",
2131
- className: "pts-footer-logo",
2132
- xmlns: "http://www.w3.org/2000/svg",
2133
- width: "278",
2134
- height: "72",
2135
- viewBox: "0 0 278 72",
2136
- fill: "none",
2137
- children: [
2138
- /* @__PURE__ */ jsx17(
2139
- "path",
2140
- {
2141
- d: "M54 43C54 47.2 51.5 51.1 47.6 52.3C45.8 52.8 44 53 41 53H24.5C21.4 53 21 53.5 21 56.5V63C21 65.4 19.5 67 17.5 67C15.5 67 14 65.4 14 63V58.5C14 56.5 14 54.8 14.2 53.9C14.8 50.5 16.8 47.9 20.1 46.7C21.4 46.2 23.6 45.9 27.9 45.9H42C43.2 45.9 44.4 45.8 44.9 45.6C46.4 45 46.9 44 46.9 42.9C46.9 41.8 46.5 40.7 44.9 40.2C44.4 40 43.2 39.9 42 39.9H19.4C18.5 39.9 17.7 39.9 17.3 39.7C15.8 39.2 14.9 37.8 14.9 36.4C14.9 35 15.8 33.6 17.3 33.1C17.8 32.9 18.3 32.9 19.3 32.9H40.9C44 32.9 46.4 33.1 47.9 33.7C51.8 35.2 53.9 38.4 53.9 42.9L54 43ZM95.7 33.3C95.2 33.1 94.4 33 93.3 33H61.6C60.8 33 60.1 33 59.7 33.2C58 33.7 57 35 57 36.5C57 38 57.8 39.2 59.4 39.7C59.9 39.9 60.7 40 61.6 40H74V63.4C74 65.8 75.6 67 77.5 67C79.4 67 81 65.8 81 63.4V40H93.3C94.5 40 95.1 40 95.5 39.8C97.1 39.3 98 38 98 36.5C98 35 97.2 33.8 95.7 33.3ZM133.5 47.4C131.8 46.5 129.6 46 124.1 46H113.5C111.8 46 110.9 45.9 110.3 45.7C108.6 45.1 108 44 108 43C108 42 108.4 40.8 110.2 40.2C110.7 40 111.6 40 112.5 40H132C132.4 40 133.5 40 133.8 40C135.6 39.7 137 38.6 137 36.6C137 34.6 135.6 33.6 133.9 33.2C133.6 33.2 132.9 33.1 132 33.1H113.5C110.2 33.1 107.8 33.5 106.2 34.2C102.9 35.8 101 39.2 101 43.1C101 47 102.8 50.5 106.4 52.1C108 52.8 110.4 53.1 113.5 53.1H127C128.7 53.1 129.6 53.3 130.2 53.5C131.6 54 132 55.4 132 56.6C132 57.8 131.6 59.3 129.9 59.8C129.3 60 128.1 60.1 126.1 60.1H106.5C105.7 60.1 104.9 60.1 104.5 60.3C102.9 60.7 102 62 102 63.6C102 65.2 103 66.2 104.3 66.7C104.8 66.9 105.9 67.1 106.7 67.1H124C127.7 67.1 130.7 66.9 132.5 66.3C136.6 65.1 138.9 61.2 138.9 56.6C138.9 52 136.8 49.2 133.4 47.5L133.5 47.4Z",
2142
- fill: "white"
2143
- }
2144
- ),
2145
- /* @__PURE__ */ jsx17(
2146
- "path",
2147
- {
2148
- d: "M92.1 15.7L92.5 15C90 11.6 84.1 9.2 78.1 9H76.9C70.9 9.2 65 11.6 62.5 15L62.9 15.7C61.8 15.7 61 16.4 61 17.3L63.3 27C63.5 27.6 63.7 27.9 64.5 27.9H90.5C91.2 27.9 91.5 27.5 91.6 27L93.9 17.3C93.9 16.4 93.1 15.7 92 15.7H92.1ZM69.3 18.8C69.1 18.8 68.8 18.7 68.6 18.7C67.6 18.7 66.9 19.4 66.9 20.3C66.9 21.2 67.6 21.8 68.5 21.8C69.4 21.8 69.3 21.7 69.5 21.4C69.5 22.2 68.6 24 67.4 24H64.9C63.2 24 63 21.7 63 21.5C63.2 21.7 63.7 21.8 64.1 21.8C64.9 21.8 65.6 21.2 65.6 20.3C65.6 19.4 64.9 18.7 63.9 18.7C62.9 18.7 63.5 18.7 63.4 18.7C63.8 18.4 64.2 17.9 64.2 17.3C64.2 16.7 63.9 16.4 63.5 16.1L65.8 15C67.3 12.5 70 10.7 73.3 10C71.5 11.3 70 12.9 68.8 15L69.6 15.7C68.8 15.8 68.2 16.5 68.2 17.3C68.2 18.1 68.6 18.5 69.2 18.8H69.3ZM76.8 18.9C76.6 18.8 76.2 18.7 76 18.7C75 18.7 74.3 19.4 74.3 20.3C74.3 21.2 75 21.8 75.9 21.8C76.8 21.8 76.7 21.7 77 21.5C77 22.3 76.4 24 75 24H72.5C70.9 24 70.5 22 70.5 21.4C70.7 21.6 71.1 21.8 71.6 21.8C72.4 21.8 73.2 21.2 73.2 20.3C73.2 19.4 72.5 18.7 71.5 18.7C70.5 18.7 70.9 18.7 70.8 18.8C71.4 18.5 71.8 18 71.8 17.3C71.8 16.6 71.4 16.1 70.8 15.9L72.6 15C73.1 13.2 74.7 10.6 76.4 9.7C76.2 10.6 76.1 12.5 76.1 15C76.1 15 76.6 15.5 77.1 15.8C76.4 16 75.9 16.6 75.9 17.3C75.9 18 76.3 18.5 76.9 18.8L76.8 18.9ZM82.5 24H80C78.6 24 78 22.3 78 21.5C78.2 21.7 78.6 21.8 79.1 21.8C80 21.8 80.7 21.2 80.7 20.3C80.7 19.4 80 18.7 79 18.7C78 18.7 78.4 18.7 78.2 18.9C78.8 18.7 79.3 18.1 79.3 17.4C79.3 16.7 78.8 16.1 78.1 15.9C78.6 15.6 79.1 15.1 79.1 15.1C79.1 12.6 79 10.7 78.7 9.8C80.5 10.7 82.1 13.2 82.6 15.1L84.4 16C83.9 16.2 83.4 16.8 83.4 17.4C83.4 18 83.8 18.6 84.4 18.9C84.2 18.9 83.9 18.8 83.7 18.8C82.7 18.8 82 19.5 82 20.4C82 21.3 82.7 21.9 83.6 21.9C84.5 21.9 84.4 21.8 84.7 21.5C84.7 22 84.3 24.1 82.7 24.1L82.5 24ZM90 24H87.5C86.2 24 85.4 22.3 85.4 21.4C85.6 21.7 86 21.8 86.5 21.8C87.3 21.8 88 21.2 88 20.3C88 19.4 87.3 18.7 86.3 18.7C85.3 18.7 85.7 18.7 85.6 18.8C86.2 18.5 86.6 18 86.6 17.3C86.6 16.6 86 15.8 85.1 15.7L86 15C84.8 12.9 83.3 11.4 81.5 10C84.7 10.7 87.5 12.4 89 15L91.4 16.1C91 16.4 90.7 16.8 90.7 17.4C90.7 18 91.1 18.6 91.6 18.9C91.5 18.9 91.2 18.8 91 18.8C90 18.8 89.3 19.5 89.3 20.4C89.3 21.3 90 21.9 90.8 21.9C91.6 21.9 91.7 21.8 91.9 21.6C91.9 21.8 91.6 24.1 90 24.1V24ZM77.5 9C76.1 9 75 7.9 75 6.5C75 5.1 75.9 4.3 77 4.1V3H76V2H77V1H78V2H79V3H78V4.1C79.1 4.3 80 5.3 80 6.6C80 7.9 78.9 9.1 77.5 9.1V9Z",
2149
- fill: "white"
2150
- }
2151
- )
2152
- ]
2153
- }
2154
- ),
2155
- /* @__PURE__ */ jsx17("nav", { className: "pts-footer-linkList", children: /* @__PURE__ */ jsxs15("ul", { children: [
2156
- /* @__PURE__ */ jsx17("li", { children: /* @__PURE__ */ jsxs15(
2157
- "a",
2158
- {
2159
- href: activatedLanguage === "en" ? "https://pts.se/en/contact/" : "https://www.pts.se/kontakt/",
2160
- target: "_blank",
2161
- rel: "noopener noreferrer",
2162
- children: [
2163
- /* @__PURE__ */ jsx17("span", { className: "sr-only", children: activatedLanguage === "en" ? "PTS Contact (opens in new tab)" : "PTS Kontakt (\xF6ppnas i ny flik)" }),
2164
- /* @__PURE__ */ jsx17("span", { "aria-hidden": "true", children: activatedLanguage === "en" ? "Contact" : "Kontakt" })
2165
- ]
2166
- }
2167
- ) }),
2168
- /* @__PURE__ */ jsx17("li", { children: /* @__PURE__ */ jsxs15(
2169
- "a",
2170
- {
2171
- href: activatedLanguage === "en" ? "https://pts.se/en/gdpr" : "https://www.pts.se/gdpr/",
2172
- target: "_blank",
2173
- rel: "noopener noreferrer",
2174
- children: [
2175
- /* @__PURE__ */ jsx17("span", { className: "sr-only", children: activatedLanguage === "en" ? "PTS Processing of personal data (opens in new tab)" : "PTS Behandling av personuppgifter (\xF6ppnas i ny flik)" }),
2176
- /* @__PURE__ */ jsx17("span", { "aria-hidden": "true", children: activatedLanguage === "en" ? "Processing of personal data" : "Behandling av personuppgifter" })
2177
- ]
2178
- }
2179
- ) }),
2180
- /* @__PURE__ */ jsx17("li", { children: /* @__PURE__ */ jsxs15(
2181
- "a",
2182
- {
2183
- href: activatedLanguage === "en" ? "https://pts.se/en/accessibility-eservices" : "https://www.pts.se/tillganglighet-etjanster",
2184
- target: "_blank",
2185
- rel: "noopener noreferrer",
2186
- children: [
2187
- /* @__PURE__ */ jsx17("span", { className: "sr-only", children: activatedLanguage === "en" ? "PTS Accessibility (opens in new tab)" : "PTS Tillg\xE4nglighetsredog\xF6relse (\xF6ppnas i ny flik)" }),
2188
- /* @__PURE__ */ jsx17("span", { "aria-hidden": "true", children: activatedLanguage === "en" ? "Accessibility" : "Tillg\xE4nglighetsredog\xF6relse" })
2189
- ]
2190
- }
2191
- ) }),
2192
- /* @__PURE__ */ jsx17("li", { children: /* @__PURE__ */ jsxs15(
2193
- "a",
2069
+ return /* @__PURE__ */ jsxs15("footer", { className: "pts-footer-container", children: [
2070
+ /* @__PURE__ */ jsx17("div", { className: "pts-footer-slogan-text-container", children: /* @__PURE__ */ jsx17("p", { className: "pts-footer-slogan-text", children: activatedLanguage === "sv" ? "S\xE4ker och tillg\xE4nglig kommunikation f\xF6r Sverige" : "Secure and accessible communication for Sweden" }) }),
2071
+ /* @__PURE__ */ jsxs15("div", { className: "pts-footer-content", children: [
2072
+ /* @__PURE__ */ jsxs15(
2073
+ "svg",
2194
2074
  {
2195
- href: activatedLanguage === "en" ? "https://pts.se/en/cookies-eservices" : "https://www.pts.se/kakor-etjanster",
2196
- target: "_blank",
2197
- rel: "noopener noreferrer",
2075
+ "aria-label": activatedLanguage === "en" ? "PTS logotype" : "PTS logotyp",
2076
+ className: "pts-footer-logo",
2077
+ xmlns: "http://www.w3.org/2000/svg",
2078
+ width: "278",
2079
+ height: "72",
2080
+ viewBox: "0 0 278 72",
2081
+ fill: "none",
2198
2082
  children: [
2199
- /* @__PURE__ */ jsx17("span", { className: "sr-only", children: activatedLanguage === "en" ? "PTS Cookies (opens in new tab)" : "PTS Kakor (\xF6ppnas i ny flik)" }),
2200
- /* @__PURE__ */ jsx17("span", { "aria-hidden": "true", children: activatedLanguage === "en" ? "Cookies" : "Kakor" })
2083
+ /* @__PURE__ */ jsx17(
2084
+ "path",
2085
+ {
2086
+ d: "M54 43C54 47.2 51.5 51.1 47.6 52.3C45.8 52.8 44 53 41 53H24.5C21.4 53 21 53.5 21 56.5V63C21 65.4 19.5 67 17.5 67C15.5 67 14 65.4 14 63V58.5C14 56.5 14 54.8 14.2 53.9C14.8 50.5 16.8 47.9 20.1 46.7C21.4 46.2 23.6 45.9 27.9 45.9H42C43.2 45.9 44.4 45.8 44.9 45.6C46.4 45 46.9 44 46.9 42.9C46.9 41.8 46.5 40.7 44.9 40.2C44.4 40 43.2 39.9 42 39.9H19.4C18.5 39.9 17.7 39.9 17.3 39.7C15.8 39.2 14.9 37.8 14.9 36.4C14.9 35 15.8 33.6 17.3 33.1C17.8 32.9 18.3 32.9 19.3 32.9H40.9C44 32.9 46.4 33.1 47.9 33.7C51.8 35.2 53.9 38.4 53.9 42.9L54 43ZM95.7 33.3C95.2 33.1 94.4 33 93.3 33H61.6C60.8 33 60.1 33 59.7 33.2C58 33.7 57 35 57 36.5C57 38 57.8 39.2 59.4 39.7C59.9 39.9 60.7 40 61.6 40H74V63.4C74 65.8 75.6 67 77.5 67C79.4 67 81 65.8 81 63.4V40H93.3C94.5 40 95.1 40 95.5 39.8C97.1 39.3 98 38 98 36.5C98 35 97.2 33.8 95.7 33.3ZM133.5 47.4C131.8 46.5 129.6 46 124.1 46H113.5C111.8 46 110.9 45.9 110.3 45.7C108.6 45.1 108 44 108 43C108 42 108.4 40.8 110.2 40.2C110.7 40 111.6 40 112.5 40H132C132.4 40 133.5 40 133.8 40C135.6 39.7 137 38.6 137 36.6C137 34.6 135.6 33.6 133.9 33.2C133.6 33.2 132.9 33.1 132 33.1H113.5C110.2 33.1 107.8 33.5 106.2 34.2C102.9 35.8 101 39.2 101 43.1C101 47 102.8 50.5 106.4 52.1C108 52.8 110.4 53.1 113.5 53.1H127C128.7 53.1 129.6 53.3 130.2 53.5C131.6 54 132 55.4 132 56.6C132 57.8 131.6 59.3 129.9 59.8C129.3 60 128.1 60.1 126.1 60.1H106.5C105.7 60.1 104.9 60.1 104.5 60.3C102.9 60.7 102 62 102 63.6C102 65.2 103 66.2 104.3 66.7C104.8 66.9 105.9 67.1 106.7 67.1H124C127.7 67.1 130.7 66.9 132.5 66.3C136.6 65.1 138.9 61.2 138.9 56.6C138.9 52 136.8 49.2 133.4 47.5L133.5 47.4Z",
2087
+ fill: "white"
2088
+ }
2089
+ ),
2090
+ /* @__PURE__ */ jsx17(
2091
+ "path",
2092
+ {
2093
+ d: "M92.1 15.7L92.5 15C90 11.6 84.1 9.2 78.1 9H76.9C70.9 9.2 65 11.6 62.5 15L62.9 15.7C61.8 15.7 61 16.4 61 17.3L63.3 27C63.5 27.6 63.7 27.9 64.5 27.9H90.5C91.2 27.9 91.5 27.5 91.6 27L93.9 17.3C93.9 16.4 93.1 15.7 92 15.7H92.1ZM69.3 18.8C69.1 18.8 68.8 18.7 68.6 18.7C67.6 18.7 66.9 19.4 66.9 20.3C66.9 21.2 67.6 21.8 68.5 21.8C69.4 21.8 69.3 21.7 69.5 21.4C69.5 22.2 68.6 24 67.4 24H64.9C63.2 24 63 21.7 63 21.5C63.2 21.7 63.7 21.8 64.1 21.8C64.9 21.8 65.6 21.2 65.6 20.3C65.6 19.4 64.9 18.7 63.9 18.7C62.9 18.7 63.5 18.7 63.4 18.7C63.8 18.4 64.2 17.9 64.2 17.3C64.2 16.7 63.9 16.4 63.5 16.1L65.8 15C67.3 12.5 70 10.7 73.3 10C71.5 11.3 70 12.9 68.8 15L69.6 15.7C68.8 15.8 68.2 16.5 68.2 17.3C68.2 18.1 68.6 18.5 69.2 18.8H69.3ZM76.8 18.9C76.6 18.8 76.2 18.7 76 18.7C75 18.7 74.3 19.4 74.3 20.3C74.3 21.2 75 21.8 75.9 21.8C76.8 21.8 76.7 21.7 77 21.5C77 22.3 76.4 24 75 24H72.5C70.9 24 70.5 22 70.5 21.4C70.7 21.6 71.1 21.8 71.6 21.8C72.4 21.8 73.2 21.2 73.2 20.3C73.2 19.4 72.5 18.7 71.5 18.7C70.5 18.7 70.9 18.7 70.8 18.8C71.4 18.5 71.8 18 71.8 17.3C71.8 16.6 71.4 16.1 70.8 15.9L72.6 15C73.1 13.2 74.7 10.6 76.4 9.7C76.2 10.6 76.1 12.5 76.1 15C76.1 15 76.6 15.5 77.1 15.8C76.4 16 75.9 16.6 75.9 17.3C75.9 18 76.3 18.5 76.9 18.8L76.8 18.9ZM82.5 24H80C78.6 24 78 22.3 78 21.5C78.2 21.7 78.6 21.8 79.1 21.8C80 21.8 80.7 21.2 80.7 20.3C80.7 19.4 80 18.7 79 18.7C78 18.7 78.4 18.7 78.2 18.9C78.8 18.7 79.3 18.1 79.3 17.4C79.3 16.7 78.8 16.1 78.1 15.9C78.6 15.6 79.1 15.1 79.1 15.1C79.1 12.6 79 10.7 78.7 9.8C80.5 10.7 82.1 13.2 82.6 15.1L84.4 16C83.9 16.2 83.4 16.8 83.4 17.4C83.4 18 83.8 18.6 84.4 18.9C84.2 18.9 83.9 18.8 83.7 18.8C82.7 18.8 82 19.5 82 20.4C82 21.3 82.7 21.9 83.6 21.9C84.5 21.9 84.4 21.8 84.7 21.5C84.7 22 84.3 24.1 82.7 24.1L82.5 24ZM90 24H87.5C86.2 24 85.4 22.3 85.4 21.4C85.6 21.7 86 21.8 86.5 21.8C87.3 21.8 88 21.2 88 20.3C88 19.4 87.3 18.7 86.3 18.7C85.3 18.7 85.7 18.7 85.6 18.8C86.2 18.5 86.6 18 86.6 17.3C86.6 16.6 86 15.8 85.1 15.7L86 15C84.8 12.9 83.3 11.4 81.5 10C84.7 10.7 87.5 12.4 89 15L91.4 16.1C91 16.4 90.7 16.8 90.7 17.4C90.7 18 91.1 18.6 91.6 18.9C91.5 18.9 91.2 18.8 91 18.8C90 18.8 89.3 19.5 89.3 20.4C89.3 21.3 90 21.9 90.8 21.9C91.6 21.9 91.7 21.8 91.9 21.6C91.9 21.8 91.6 24.1 90 24.1V24ZM77.5 9C76.1 9 75 7.9 75 6.5C75 5.1 75.9 4.3 77 4.1V3H76V2H77V1H78V2H79V3H78V4.1C79.1 4.3 80 5.3 80 6.6C80 7.9 78.9 9.1 77.5 9.1V9Z",
2094
+ fill: "white"
2095
+ }
2096
+ )
2201
2097
  ]
2202
2098
  }
2203
- ) })
2204
- ] }) })
2205
- ] }) });
2099
+ ),
2100
+ /* @__PURE__ */ jsx17("nav", { className: "pts-footer-linkList", children: /* @__PURE__ */ jsxs15("ul", { children: [
2101
+ /* @__PURE__ */ jsx17("li", { children: /* @__PURE__ */ jsxs15(
2102
+ "a",
2103
+ {
2104
+ href: activatedLanguage === "en" ? "https://pts.se/en/contact/" : "https://www.pts.se/kontakt/",
2105
+ target: "_blank",
2106
+ rel: "noopener noreferrer",
2107
+ children: [
2108
+ /* @__PURE__ */ jsx17("span", { className: "sr-only", children: activatedLanguage === "en" ? "PTS Contact (opens in new tab)" : "PTS Kontakt (\xF6ppnas i ny flik)" }),
2109
+ /* @__PURE__ */ jsx17("span", { "aria-hidden": "true", children: activatedLanguage === "en" ? "Contact" : "Kontakt" })
2110
+ ]
2111
+ }
2112
+ ) }),
2113
+ /* @__PURE__ */ jsx17("li", { children: /* @__PURE__ */ jsxs15(
2114
+ "a",
2115
+ {
2116
+ href: activatedLanguage === "en" ? "https://pts.se/en/gdpr" : "https://www.pts.se/gdpr/",
2117
+ target: "_blank",
2118
+ rel: "noopener noreferrer",
2119
+ children: [
2120
+ /* @__PURE__ */ jsx17("span", { className: "sr-only", children: activatedLanguage === "en" ? "PTS Processing of personal data (opens in new tab)" : "PTS Behandling av personuppgifter (\xF6ppnas i ny flik)" }),
2121
+ /* @__PURE__ */ jsx17("span", { "aria-hidden": "true", children: activatedLanguage === "en" ? "Processing of personal data" : "Behandling av personuppgifter" })
2122
+ ]
2123
+ }
2124
+ ) }),
2125
+ /* @__PURE__ */ jsx17("li", { children: /* @__PURE__ */ jsxs15(
2126
+ "a",
2127
+ {
2128
+ href: activatedLanguage === "en" ? "https://pts.se/en/accessibility-eservices" : "https://www.pts.se/tillganglighet-etjanster",
2129
+ target: "_blank",
2130
+ rel: "noopener noreferrer",
2131
+ children: [
2132
+ /* @__PURE__ */ jsx17("span", { className: "sr-only", children: activatedLanguage === "en" ? "PTS Accessibility (opens in new tab)" : "PTS Tillg\xE4nglighetsredog\xF6relse (\xF6ppnas i ny flik)" }),
2133
+ /* @__PURE__ */ jsx17("span", { "aria-hidden": "true", children: activatedLanguage === "en" ? "Accessibility" : "Tillg\xE4nglighetsredog\xF6relse" })
2134
+ ]
2135
+ }
2136
+ ) }),
2137
+ /* @__PURE__ */ jsx17("li", { children: /* @__PURE__ */ jsxs15(
2138
+ "a",
2139
+ {
2140
+ href: activatedLanguage === "en" ? "https://pts.se/en/cookies-eservices" : "https://www.pts.se/kakor-etjanster",
2141
+ target: "_blank",
2142
+ rel: "noopener noreferrer",
2143
+ children: [
2144
+ /* @__PURE__ */ jsx17("span", { className: "sr-only", children: activatedLanguage === "en" ? "PTS Cookies (opens in new tab)" : "PTS Kakor (\xF6ppnas i ny flik)" }),
2145
+ /* @__PURE__ */ jsx17("span", { "aria-hidden": "true", children: activatedLanguage === "en" ? "Cookies" : "Kakor" })
2146
+ ]
2147
+ }
2148
+ ) })
2149
+ ] }) })
2150
+ ] })
2151
+ ] });
2206
2152
  };
2207
2153
  var FooterStandard_default = Footer;
2208
2154
 
@@ -2603,7 +2549,7 @@ var Header = ({
2603
2549
  if (activatedLanguage === "sv") return "English";
2604
2550
  else return "Svenska";
2605
2551
  };
2606
- return /* @__PURE__ */ jsxs17("header", { className: "pts-header-container", children: [
2552
+ return /* @__PURE__ */ jsx19("header", { className: "pts-header-container", children: /* @__PURE__ */ jsxs17("div", { className: "pts-header-content", children: [
2607
2553
  /* @__PURE__ */ jsx19("div", { className: "pts-header-logo-container", children: /* @__PURE__ */ jsx19(
2608
2554
  "a",
2609
2555
  {
@@ -2614,7 +2560,7 @@ var Header = ({
2614
2560
  children: activatedLanguage === "en" ? /* @__PURE__ */ jsx19("span", { "aria-hidden": "true", children: /* @__PURE__ */ jsx19(Logo_en, {}) }) : /* @__PURE__ */ jsx19("span", { "aria-hidden": "true", children: /* @__PURE__ */ jsx19(Logo_sv, {}) })
2615
2561
  }
2616
2562
  ) }),
2617
- useLanguage && /* @__PURE__ */ jsxs17(
2563
+ /* @__PURE__ */ jsx19("div", { className: "pts-header-navigation-container", children: useLanguage && /* @__PURE__ */ jsxs17(
2618
2564
  "button",
2619
2565
  {
2620
2566
  lang: activatedLanguage === "en" ? "en" : "sv",
@@ -2627,8 +2573,8 @@ var Header = ({
2627
2573
  activatedLanguage === "sv" && /* @__PURE__ */ jsx19("span", { className: "sr-only", children: "Change language to English" })
2628
2574
  ]
2629
2575
  }
2630
- )
2631
- ] });
2576
+ ) })
2577
+ ] }) });
2632
2578
  };
2633
2579
  var HeaderStandard_default = Header;
2634
2580
 
@@ -2880,13 +2826,13 @@ var TextBody = ({ data }) => {
2880
2826
  var TextBody_default = TextBody;
2881
2827
 
2882
2828
  // src/components/stepper/EditPreviewLinkStandard/EditPreviewLinkStandard.tsx
2883
- import { jsx as jsx25, jsxs as jsxs21 } from "react/jsx-runtime";
2829
+ import { jsx as jsx25 } from "react/jsx-runtime";
2884
2830
  var EditPreviewLink = ({
2885
2831
  step,
2886
2832
  changeStepHandler,
2887
2833
  activatedLanguage = "sv"
2888
2834
  }) => {
2889
- return /* @__PURE__ */ jsx25("div", { className: "pts-editPreviewLink-container", children: /* @__PURE__ */ jsxs21(
2835
+ return /* @__PURE__ */ jsx25("div", { className: "pts-editPreviewLink-container", children: /* @__PURE__ */ jsx25(
2890
2836
  "a",
2891
2837
  {
2892
2838
  href: "#",
@@ -2895,30 +2841,7 @@ var EditPreviewLink = ({
2895
2841
  e.preventDefault();
2896
2842
  changeStepHandler(step.step);
2897
2843
  },
2898
- children: [
2899
- /* @__PURE__ */ jsx25(
2900
- "svg",
2901
- {
2902
- "aria-hidden": "true",
2903
- focusable: "false",
2904
- xmlns: "http://www.w3.org/2000/svg",
2905
- width: "16",
2906
- height: "16",
2907
- viewBox: "0 0 16 16",
2908
- fill: "none",
2909
- children: /* @__PURE__ */ jsx25(
2910
- "path",
2911
- {
2912
- d: "M10.0001 3.99996L12.0001 5.99996M8.66675 13.3333H14.0001M3.33341 10.6666L2.66675 13.3333L5.33341 12.6666L13.0574 4.94263C13.3074 4.69259 13.4478 4.35351 13.4478 3.99996C13.4478 3.64641 13.3074 3.30733 13.0574 3.05729L12.9427 2.94263C12.6927 2.69267 12.3536 2.55225 12.0001 2.55225C11.6465 2.55225 11.3075 2.69267 11.0574 2.94263L3.33341 10.6666Z",
2913
- stroke: "#6E3282",
2914
- strokeLinecap: "round",
2915
- strokeLinejoin: "round"
2916
- }
2917
- )
2918
- }
2919
- ),
2920
- /* @__PURE__ */ jsx25("span", { className: "pts-edit-step-text", children: activatedLanguage === "en" ? `Edit step ${step.step}` : `Redigera steg ${step.step}` })
2921
- ]
2844
+ children: /* @__PURE__ */ jsx25("span", { className: "pts-edit-step-text", children: activatedLanguage === "en" ? `Edit step ${step.step}` : `Redigera steg ${step.step}` })
2922
2845
  }
2923
2846
  ) });
2924
2847
  };
@@ -2944,7 +2867,7 @@ var StartApplicationButton = ({
2944
2867
  var StartApplicationButton_default = StartApplicationButton;
2945
2868
 
2946
2869
  // src/components/stepper/StepperButtonsStandard/StepperButtonsStandard.tsx
2947
- import { jsx as jsx27, jsxs as jsxs22 } from "react/jsx-runtime";
2870
+ import { jsx as jsx27, jsxs as jsxs21 } from "react/jsx-runtime";
2948
2871
  var StepperButtons = ({
2949
2872
  globalLanguageState,
2950
2873
  changeStepHandler,
@@ -2954,7 +2877,7 @@ var StepperButtons = ({
2954
2877
  activeStep
2955
2878
  }) => {
2956
2879
  const totalSteps = steps ? steps.length : "";
2957
- return /* @__PURE__ */ jsxs22("div", { className: "pts-stepperButtons-container", children: [
2880
+ return /* @__PURE__ */ jsxs21("div", { className: "pts-stepperButtons-container", children: [
2958
2881
  activeStep !== 0 && /* @__PURE__ */ jsx27(
2959
2882
  "button",
2960
2883
  {
@@ -2964,7 +2887,7 @@ var StepperButtons = ({
2964
2887
  children: globalLanguageState ? globalLanguageState.backButton : "<<"
2965
2888
  }
2966
2889
  ),
2967
- /* @__PURE__ */ jsxs22(
2890
+ /* @__PURE__ */ jsxs21(
2968
2891
  "button",
2969
2892
  {
2970
2893
  type: activeStep === totalSteps ? "submit" : "button",
@@ -2982,14 +2905,14 @@ var StepperButtonsStandard_default = StepperButtons;
2982
2905
 
2983
2906
  // src/components/stepper/StepperStandard/StepperStandard.tsx
2984
2907
  import React9 from "react";
2985
- import { jsx as jsx28, jsxs as jsxs23 } from "react/jsx-runtime";
2908
+ import { jsx as jsx28, jsxs as jsxs22 } from "react/jsx-runtime";
2986
2909
  var Stepper = ({ arraySteps = [], activeStep = 1 }) => {
2987
2910
  return /* @__PURE__ */ jsx28("div", { className: "pts-stepper-container", "aria-hidden": "true", children: arraySteps.map((step, index) => {
2988
2911
  const isActive = step.step === activeStep;
2989
2912
  const lastElement = arraySteps.length;
2990
2913
  const isDone = step.step < activeStep;
2991
- return /* @__PURE__ */ jsxs23(React9.Fragment, { children: [
2992
- /* @__PURE__ */ jsxs23("div", { className: "pts-stepper-step", children: [
2914
+ return /* @__PURE__ */ jsxs22(React9.Fragment, { children: [
2915
+ /* @__PURE__ */ jsxs22("div", { className: "pts-stepper-step", children: [
2993
2916
  /* @__PURE__ */ jsx28(
2994
2917
  "div",
2995
2918
  {
@@ -3024,7 +2947,7 @@ var Stepper = ({ arraySteps = [], activeStep = 1 }) => {
3024
2947
  var StepperStandard_default = Stepper;
3025
2948
 
3026
2949
  // src/components/validation-and-status/ValidationErrorSummaryList/ValidationErrorSummaryList.tsx
3027
- import { Fragment as Fragment17, jsx as jsx29, jsxs as jsxs24 } from "react/jsx-runtime";
2950
+ import { Fragment as Fragment16, jsx as jsx29, jsxs as jsxs23 } from "react/jsx-runtime";
3028
2951
  var ValidationErrorSummaryList = ({
3029
2952
  validationErrorsList,
3030
2953
  questions,
@@ -3054,14 +2977,14 @@ var ValidationErrorSummaryList = ({
3054
2977
  if (container) {
3055
2978
  container.scrollIntoView({ behavior: "smooth", block: "center" });
3056
2979
  setTimeout(() => {
3057
- const input = container.querySelector("input, textarea, select");
2980
+ const input = container.querySelector("input, textarea, select, button");
3058
2981
  if (input) {
3059
2982
  input.focus();
3060
2983
  }
3061
2984
  }, 300);
3062
2985
  }
3063
2986
  }
3064
- if (!validationErrorsList.length) return /* @__PURE__ */ jsx29(Fragment17, {});
2987
+ if (!validationErrorsList.length) return /* @__PURE__ */ jsx29(Fragment16, {});
3065
2988
  const filteredIds = filterIdsByGroupCheck(validationErrorsList, questions);
3066
2989
  const count = filteredIds.length;
3067
2990
  const title = summaryText.replace("{count}", count.toString()).replace(
@@ -3073,9 +2996,9 @@ var ValidationErrorSummaryList = ({
3073
2996
  const found = questions.find((item) => item.id === id);
3074
2997
  return (_a = found == null ? void 0 : found.validationSummaryLabel) != null ? _a : found == null ? void 0 : found.questionLabel;
3075
2998
  }
3076
- return /* @__PURE__ */ jsxs24("div", { className: `pts-errorSummary-container pts-root-error ${validationErrorsList.length === 0 ? "cleanPadding" : ""}`, children: [
2999
+ return /* @__PURE__ */ jsxs23("div", { className: `pts-errorSummary-container pts-root-error ${validationErrorsList.length === 0 ? "cleanPadding" : ""}`, children: [
3077
3000
  /* @__PURE__ */ jsx29("span", { "aria-hidden": "true", className: "errorDot", children: "!" }),
3078
- /* @__PURE__ */ jsxs24("div", { className: "errorSummary-content", id: "pts-errorSummary-content", children: [
3001
+ /* @__PURE__ */ jsxs23("div", { className: "errorSummary-content", id: "pts-errorSummary-content", children: [
3079
3002
  /* @__PURE__ */ jsx29("h2", { id: "errorSummary-headline", children: title }),
3080
3003
  /* @__PURE__ */ jsx29("ul", { id: "errorSummary-ul", children: filteredIds.map((questionId, i) => /* @__PURE__ */ jsx29("li", { children: /* @__PURE__ */ jsx29(
3081
3004
  "a",
@@ -3095,10 +3018,10 @@ var ValidationErrorSummaryList = ({
3095
3018
  var ValidationErrorSummaryList_default = ValidationErrorSummaryList;
3096
3019
 
3097
3020
  // src/components/validation-and-status/FormStatusMessagesScreenReader/FormStatusMessagesScreenReader.tsx
3098
- import { Fragment as Fragment18, jsx as jsx30, jsxs as jsxs25 } from "react/jsx-runtime";
3021
+ import { Fragment as Fragment17, jsx as jsx30, jsxs as jsxs24 } from "react/jsx-runtime";
3099
3022
  var FormStatusMessagesScreenReader = ({ formStatus }) => {
3100
- return /* @__PURE__ */ jsxs25(Fragment18, { children: [
3101
- /* @__PURE__ */ jsx30("p", { "aria-live": "assertive", children: formStatus === "failed" && /* @__PURE__ */ jsx30("span", { className: "mandatoryAsterisk", children: "N\xE5got gick fel, f\xF6rs\xF6k igen senare eller kontakta oss!" }) }),
3023
+ return /* @__PURE__ */ jsxs24(Fragment17, { children: [
3024
+ /* @__PURE__ */ jsx30("p", { "aria-live": "assertive", children: formStatus === "failed" && /* @__PURE__ */ jsx30("span", { className: "pts-root-mandatoryAsterisk", children: "N\xE5got gick fel, f\xF6rs\xF6k igen senare eller kontakta oss!" }) }),
3102
3025
  /* @__PURE__ */ jsx30("div", { "aria-live": "polite", className: "visually-hidden", children: formStatus === "loading" ? "Ditt \xE4rende registreras. Uppdatera eller st\xE4ng inte sidan." : "" })
3103
3026
  ] });
3104
3027
  };
@@ -3107,7 +3030,6 @@ export {
3107
3030
  AddFilesStandard_default as AddFilesStandard,
3108
3031
  CheckboxGroupStandard_default as CheckboxGroupStandard,
3109
3032
  CookieBanner_default as CookieBanner,
3110
- DropdownStandard_default as DropdownStandard,
3111
3033
  EditPreviewLinkStandard_default as EditPreviewLinkStandard,
3112
3034
  FooterStandard_default as FooterStandard,
3113
3035
  FormStatusMessagesScreenReader_default as FormStatusMessagesScreenReader,