optimized-react-component-library-xyz123 0.19.7 → 0.19.9
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.d.mts +0 -2
- package/dist/index.d.ts +0 -2
- package/dist/index.js +71 -76
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +71 -76
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/css/mobileView.css +1 -2
- package/src/css/styles.css +2 -33
package/dist/index.d.mts
CHANGED
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -992,7 +992,7 @@ var AddFiles = ({
|
|
|
992
992
|
const currentFiles = questionObject.files ? questionObject.files : [];
|
|
993
993
|
const e = {
|
|
994
994
|
target: {
|
|
995
|
-
value: `${currentFiles.length + newFiles.length} files
|
|
995
|
+
value: currentFiles.length + newFiles.length > 0 ? `${currentFiles.length + newFiles.length} files` : "",
|
|
996
996
|
files: [...currentFiles, ...newFiles]
|
|
997
997
|
}
|
|
998
998
|
};
|
|
@@ -1015,68 +1015,75 @@ var AddFiles = ({
|
|
|
1015
1015
|
setErrorMessageAddingFile([]);
|
|
1016
1016
|
};
|
|
1017
1017
|
return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(import_jsx_runtime11.Fragment, { children: [
|
|
1018
|
-
!showPreview && visible && /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1018
|
+
!showPreview && visible && /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
1019
|
+
"div",
|
|
1020
|
+
{
|
|
1021
|
+
className: "root-question addFile-question-container",
|
|
1022
|
+
id: `question-${questionObject.id}`,
|
|
1023
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("div", { role: "group", children: [
|
|
1024
|
+
questionObject.aboutText && /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
|
|
1025
|
+
"p",
|
|
1026
|
+
{
|
|
1027
|
+
id: aboutId,
|
|
1028
|
+
className: (0, import_clsx3.default)(
|
|
1029
|
+
"addFilesMandatory",
|
|
1030
|
+
questionObject.hasValidationError ? " error" : ""
|
|
1031
|
+
),
|
|
1032
|
+
children: [
|
|
1033
|
+
questionObject.aboutText,
|
|
1034
|
+
questionObject.isQuestionMandatory && /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("span", { className: "pts-root-mandatoryAsterisk", "aria-label": "Obligatorisk fr\xE5ga", children: [
|
|
1035
|
+
" ",
|
|
1036
|
+
"*"
|
|
1037
|
+
] })
|
|
1038
|
+
]
|
|
1039
|
+
}
|
|
1026
1040
|
),
|
|
1027
|
-
children: [
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
activatedLanguage,
|
|
1074
|
-
numberOfFiles,
|
|
1075
|
-
setNumberOfFiles,
|
|
1076
|
-
removeUploadErrors: handleRemoveErrors
|
|
1077
|
-
}
|
|
1078
|
-
)
|
|
1079
|
-
] }) }),
|
|
1041
|
+
questionObject.hasValidationError && /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("div", { className: "pts-root-error error addfileserror", id: errorId, children: [
|
|
1042
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("span", { "aria-hidden": true, className: "errorDot", children: "!" }),
|
|
1043
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("span", { className: "sr-only", children: "Valideringsfel" }),
|
|
1044
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)("span", { className: "errorText", children: questionObject.validationDefaultMessesege })
|
|
1045
|
+
] }),
|
|
1046
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
1047
|
+
ExploreFilesStandard_default,
|
|
1048
|
+
{
|
|
1049
|
+
FilesSelected: onDrop,
|
|
1050
|
+
numberOfFiles,
|
|
1051
|
+
allowedNumberOfFiles,
|
|
1052
|
+
activatedLanguage,
|
|
1053
|
+
inputId,
|
|
1054
|
+
labelId,
|
|
1055
|
+
aboutId,
|
|
1056
|
+
errorId,
|
|
1057
|
+
questionObject,
|
|
1058
|
+
errorMessageAddingFile,
|
|
1059
|
+
removeUploadErrors: handleRemoveErrors
|
|
1060
|
+
}
|
|
1061
|
+
),
|
|
1062
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
1063
|
+
DropFilesStandard_default,
|
|
1064
|
+
{
|
|
1065
|
+
FilesSelected: onDrop,
|
|
1066
|
+
DropFilesText: dropFilesText,
|
|
1067
|
+
language: activatedLanguage
|
|
1068
|
+
}
|
|
1069
|
+
),
|
|
1070
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
1071
|
+
SelectedFilesStandard_default,
|
|
1072
|
+
{
|
|
1073
|
+
questionObject,
|
|
1074
|
+
isTouched: handleQuestionInputChange,
|
|
1075
|
+
removeFile: removeFileFromNumberOfFiles,
|
|
1076
|
+
removeError,
|
|
1077
|
+
errorMessageAddingFile,
|
|
1078
|
+
activatedLanguage,
|
|
1079
|
+
numberOfFiles,
|
|
1080
|
+
setNumberOfFiles,
|
|
1081
|
+
removeUploadErrors: handleRemoveErrors
|
|
1082
|
+
}
|
|
1083
|
+
)
|
|
1084
|
+
] })
|
|
1085
|
+
}
|
|
1086
|
+
),
|
|
1080
1087
|
showPreview && /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(PreviewAddFiles, { activatedLanguage, questionObject })
|
|
1081
1088
|
] });
|
|
1082
1089
|
};
|
|
@@ -2123,7 +2130,7 @@ var CookieBanner_default = CookieBanner;
|
|
|
2123
2130
|
|
|
2124
2131
|
// src/components/layout/FooterStandard/FooterStandard.tsx
|
|
2125
2132
|
var import_jsx_runtime16 = require("react/jsx-runtime");
|
|
2126
|
-
var Footer = ({ activatedLanguage = "sv"
|
|
2133
|
+
var Footer = ({ activatedLanguage = "sv" }) => {
|
|
2127
2134
|
return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("footer", { className: "pts-footer-container", children: [
|
|
2128
2135
|
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)("div", { className: "pts-footer-slogan-text-container", children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("p", { className: "pts-footer-slogan-text", children: activatedLanguage === "sv" ? "S\xE4ker och tillg\xE4nglig kommunikation f\xF6r Sverige" : "Secure and accessible communication for Sweden" }) }),
|
|
2129
2136
|
/* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("div", { className: "pts-footer-content", children: [
|
|
@@ -2192,19 +2199,7 @@ var Footer = ({ activatedLanguage = "sv", appUsesCookies = false, openCookieBann
|
|
|
2192
2199
|
]
|
|
2193
2200
|
}
|
|
2194
2201
|
) }),
|
|
2195
|
-
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)("li", { children:
|
|
2196
|
-
"button",
|
|
2197
|
-
{
|
|
2198
|
-
"aria-expanded": "false",
|
|
2199
|
-
"aria-controls": "cookie-banner",
|
|
2200
|
-
"aria-haspopup": "dialog",
|
|
2201
|
-
onClick: openCookieBanner,
|
|
2202
|
-
children: [
|
|
2203
|
-
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)("span", { className: "sr-only", children: activatedLanguage === "en" ? "PTS Cookies (opens)" : "PTS Kakor (\xF6ppnas)" }),
|
|
2204
|
-
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)("span", { "aria-hidden": "true", children: activatedLanguage === "en" ? "Cookies" : "Kakor" })
|
|
2205
|
-
]
|
|
2206
|
-
}
|
|
2207
|
-
) : /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(
|
|
2202
|
+
/* @__PURE__ */ (0, import_jsx_runtime16.jsx)("li", { children: /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(
|
|
2208
2203
|
"a",
|
|
2209
2204
|
{
|
|
2210
2205
|
href: activatedLanguage === "en" ? "https://pts.se/en/cookies-eservices" : "https://www.pts.se/kakor-etjanster",
|