@prokodo/ui 1.0.4 → 1.0.6
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/components/RTE/RTE.css +2 -0
- package/dist/components/accordion/Accordion.css +4 -0
- package/dist/components/animatedText/AnimatedText.server.js +2 -2
- package/dist/components/autocomplete/Autocomplete.css +2 -0
- package/dist/components/avatar/Avatar.css +3 -0
- package/dist/components/button/Button.css +4 -0
- package/dist/components/calendly/Calendly.css +2 -0
- package/dist/components/card/Card.client.js +0 -2
- package/dist/components/card/Card.css +7 -0
- package/dist/components/carousel/Carousel.client.js +14 -9
- package/dist/components/carousel/Carousel.css +2 -0
- package/dist/components/datePicker/DatePicker.client.js +36 -3
- package/dist/components/datePicker/DatePicker.css +4 -2
- package/dist/components/datePicker/DatePicker.module.css +2 -2
- package/dist/components/datePicker/DatePicker.view.js +3 -1
- package/dist/components/datePicker/DatePickerDialog.view.js +3 -1
- package/dist/components/dialog/Dialog.client.js +8 -0
- package/dist/components/dialog/Dialog.css +5 -5
- package/dist/components/dialog/Dialog.module.css +3 -5
- package/dist/components/dialog/Dialog.module.scss.js +1 -1
- package/dist/components/drawer/Drawer.css +3 -0
- package/dist/components/dynamic-list/DynamicList.css +5 -0
- package/dist/components/form/Form.css +184 -0
- package/dist/components/form/FormField.client.js +7 -5
- package/dist/components/headline/Headline.css +2 -0
- package/dist/components/image/Image.client.js +8 -4
- package/dist/components/image/Image.server.js +6 -3
- package/dist/components/image-text/ImageText.css +8 -0
- package/dist/components/input/Input.css +3 -1
- package/dist/components/input/Input.module.css +1 -1
- package/dist/components/input/Input.view.js +3 -3
- package/dist/components/inputOTP/InputOTP.css +2 -0
- package/dist/components/list/List.css +4 -3
- package/dist/components/list/List.module.css +0 -3
- package/dist/components/map/Map.css +2 -0
- package/dist/components/post-item/PostItem.css +165 -0
- package/dist/components/post-teaser/PostTeaser.css +8 -0
- package/dist/components/post-widget/PostWidget.css +5 -0
- package/dist/components/post-widget-carousel/PostWidgetCarousel.css +7 -0
- package/dist/components/quote/Quote.css +5 -0
- package/dist/components/rating/Rating.css +2 -0
- package/dist/components/rich-text/RichText.css +5 -0
- package/dist/components/select/Select.client.js +13 -3
- package/dist/components/select/Select.css +12 -27
- package/dist/components/select/Select.module.css +10 -27
- package/dist/components/sidenav/SideNav.css +4 -0
- package/dist/components/slider/Slider.css +2 -0
- package/dist/components/snackbar/Snackbar.css +38 -0
- package/dist/components/snackbar/Snackbar.module.css +36 -0
- package/dist/components/snackbar/Snackbar.module.scss.js +6 -0
- package/dist/components/stepper/Stepper.css +13 -31
- package/dist/components/stepper/Stepper.module.css +11 -31
- package/dist/components/switch/Switch.css +2 -0
- package/dist/components/table/Table.css +15 -0
- package/dist/components/table/Table.js +2 -1
- package/dist/components/table/Table.module.css +9 -0
- package/dist/components/table/Table.module.scss.js +2 -0
- package/dist/components/tabs/Tabs.css +2 -0
- package/dist/components/teaser/Teaser.css +8 -0
- package/dist/components/tooltip/Tooltip.client.js +6 -2
- package/dist/constants/project.js +1 -1
- package/dist/theme-tokens.css +723 -0
- package/dist/theme.css +75 -71
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/dist/types/components/datePicker/DatePicker.model.d.ts +2 -1
- package/dist/types/components/datePicker/DatePicker.view.d.ts +3 -2
- package/dist/types/components/datePicker/DatePickerDialog.view.d.ts +1 -1
- package/dist/types/components/form/Form.model.d.ts +5 -0
- package/dist/types/components/input/Input.view.d.ts +1 -1
- package/dist/types/components/select/Select.model.d.ts +2 -0
- package/package.json +3 -2
|
@@ -3,8 +3,8 @@ var __name = (target, value) => __defProp(target, "name", { value, configurable:
|
|
|
3
3
|
import { jsx } from "react/jsx-runtime";
|
|
4
4
|
import { AnimatedTextView } from "./AnimatedText.view.js";
|
|
5
5
|
function AnimatedTextServer(props) {
|
|
6
|
-
const { children
|
|
7
|
-
return /* @__PURE__ */ jsx(AnimatedTextView, { ...rest, text:
|
|
6
|
+
const { children, ...rest } = props;
|
|
7
|
+
return /* @__PURE__ */ jsx(AnimatedTextView, { ...rest, text: children });
|
|
8
8
|
}
|
|
9
9
|
__name(AnimatedTextServer, "AnimatedTextServer");
|
|
10
10
|
export {
|
|
@@ -31,7 +31,6 @@ function CardClient({
|
|
|
31
31
|
},
|
|
32
32
|
[onClick, onKeyDown, disabled]
|
|
33
33
|
);
|
|
34
|
-
const linkRole = isString(redirect == null ? void 0 : redirect.href) && !Boolean(disabled) ? "link" : void 0;
|
|
35
34
|
const linkTabIndex = isString(redirect == null ? void 0 : redirect.href) && !Boolean(disabled) ? 0 : void 0;
|
|
36
35
|
return /* @__PURE__ */ jsx(
|
|
37
36
|
CardView,
|
|
@@ -40,7 +39,6 @@ function CardClient({
|
|
|
40
39
|
disabled,
|
|
41
40
|
isClickable,
|
|
42
41
|
redirect,
|
|
43
|
-
role: linkRole,
|
|
44
42
|
tabIndex: linkTabIndex,
|
|
45
43
|
onClick: !Boolean(disabled) ? handleClickVoid : void 0,
|
|
46
44
|
onKeyDown: handleKey,
|
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
@import "../animated/Animated.css";
|
|
2
|
+
@import "../headline/Headline.css";
|
|
3
|
+
@import "../image/Image.css";
|
|
4
|
+
@import "../link/Link.css";
|
|
5
|
+
@import "../rich-text/RichText.css";
|
|
6
|
+
@import "../skeleton/Skeleton.css";
|
|
7
|
+
|
|
1
8
|
/* stylelint-disable */
|
|
2
9
|
/**
|
|
3
10
|
* Calculates a rem-based value by a given pixel size.
|
|
@@ -180,15 +180,20 @@ function CarouselClient(props) {
|
|
|
180
180
|
transform: getTransformValue(),
|
|
181
181
|
transition: transitioning ? "transform 0.3s ease-in-out" : "none"
|
|
182
182
|
},
|
|
183
|
-
children: items.map((child, i) =>
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
183
|
+
children: items.map((child, i) => {
|
|
184
|
+
const isClone = i < effectiveItemsToShow || i >= effectiveItemsToShow + num;
|
|
185
|
+
return /* @__PURE__ */ jsx(
|
|
186
|
+
"div",
|
|
187
|
+
{
|
|
188
|
+
"aria-hidden": isClone || void 0,
|
|
189
|
+
className: bem("item", void 0, classNameItem),
|
|
190
|
+
inert: isClone || void 0,
|
|
191
|
+
style: { width: `${100 / effectiveItemsToShow}%` },
|
|
192
|
+
children: child
|
|
193
|
+
},
|
|
194
|
+
`cl-${i}`
|
|
195
|
+
);
|
|
196
|
+
})
|
|
192
197
|
}
|
|
193
198
|
),
|
|
194
199
|
/* @__PURE__ */ jsx(
|
|
@@ -46,6 +46,7 @@ const DatePickerClient = /* @__PURE__ */ __name(({
|
|
|
46
46
|
const [isOpen, setIsOpen] = useState(false);
|
|
47
47
|
const [isMobile, setIsMobile] = useState(false);
|
|
48
48
|
const [viewMode, setViewMode] = useState("days");
|
|
49
|
+
const [triggerRect, setTriggerRect] = useState(null);
|
|
49
50
|
const viewModeRef = useRef("days");
|
|
50
51
|
viewModeRef.current = viewMode;
|
|
51
52
|
const swipeTouchStart = useRef(null);
|
|
@@ -100,7 +101,12 @@ const DatePickerClient = /* @__PURE__ */ __name(({
|
|
|
100
101
|
useEffect(() => {
|
|
101
102
|
if (!isOpen || isMobile) return;
|
|
102
103
|
function handlePointerDown(e) {
|
|
103
|
-
|
|
104
|
+
var _a;
|
|
105
|
+
const target = e.target;
|
|
106
|
+
const inRoot = (_a = rootRef.current) == null ? void 0 : _a.contains(target);
|
|
107
|
+
const dialogEl = document.getElementById(`${name}-dialog`);
|
|
108
|
+
const inDialog = dialogEl == null ? void 0 : dialogEl.contains(target);
|
|
109
|
+
if (!inRoot && !inDialog) {
|
|
104
110
|
setIsOpen(false);
|
|
105
111
|
setDraft(date);
|
|
106
112
|
}
|
|
@@ -108,7 +114,23 @@ const DatePickerClient = /* @__PURE__ */ __name(({
|
|
|
108
114
|
__name(handlePointerDown, "handlePointerDown");
|
|
109
115
|
document.addEventListener("pointerdown", handlePointerDown);
|
|
110
116
|
return () => document.removeEventListener("pointerdown", handlePointerDown);
|
|
111
|
-
}, [isOpen, isMobile, date]);
|
|
117
|
+
}, [isOpen, isMobile, date, name]);
|
|
118
|
+
useEffect(() => {
|
|
119
|
+
if (!isOpen || isMobile || !rootRef.current) return;
|
|
120
|
+
function sync() {
|
|
121
|
+
const el = rootRef.current;
|
|
122
|
+
if (!el) return;
|
|
123
|
+
const r = el.getBoundingClientRect();
|
|
124
|
+
setTriggerRect({ top: r.bottom, left: r.left, width: r.width });
|
|
125
|
+
}
|
|
126
|
+
__name(sync, "sync");
|
|
127
|
+
document.addEventListener("scroll", sync, true);
|
|
128
|
+
window.addEventListener("resize", sync);
|
|
129
|
+
return () => {
|
|
130
|
+
document.removeEventListener("scroll", sync, true);
|
|
131
|
+
window.removeEventListener("resize", sync);
|
|
132
|
+
};
|
|
133
|
+
}, [isOpen, isMobile]);
|
|
112
134
|
const validateDate = useCallback(
|
|
113
135
|
(d) => {
|
|
114
136
|
if (isNull(d)) {
|
|
@@ -143,6 +165,10 @@ const DatePickerClient = /* @__PURE__ */ __name(({
|
|
|
143
165
|
setViewingMonth(date ?? dayjs());
|
|
144
166
|
setDraft(date);
|
|
145
167
|
setViewMode("days");
|
|
168
|
+
if (rootRef.current) {
|
|
169
|
+
const r = rootRef.current.getBoundingClientRect();
|
|
170
|
+
setTriggerRect({ top: r.bottom, left: r.left, width: r.width });
|
|
171
|
+
}
|
|
146
172
|
}
|
|
147
173
|
return !prev;
|
|
148
174
|
});
|
|
@@ -218,6 +244,12 @@ const DatePickerClient = /* @__PURE__ */ __name(({
|
|
|
218
244
|
},
|
|
219
245
|
[]
|
|
220
246
|
);
|
|
247
|
+
const dialogStyle = !isMobile && triggerRect ? {
|
|
248
|
+
position: "fixed",
|
|
249
|
+
top: triggerRect.top + 8,
|
|
250
|
+
left: triggerRect.left,
|
|
251
|
+
zIndex: 1400
|
|
252
|
+
} : void 0;
|
|
221
253
|
return /* @__PURE__ */ jsx(
|
|
222
254
|
"div",
|
|
223
255
|
{
|
|
@@ -228,7 +260,8 @@ const DatePickerClient = /* @__PURE__ */ __name(({
|
|
|
228
260
|
{
|
|
229
261
|
...rest,
|
|
230
262
|
color,
|
|
231
|
-
dialogPortalTarget:
|
|
263
|
+
dialogPortalTarget: document.body,
|
|
264
|
+
dialogStyle,
|
|
232
265
|
errorText: error,
|
|
233
266
|
format: fmt,
|
|
234
267
|
helperText,
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
@import "../input/Input.css";
|
|
2
|
+
|
|
1
3
|
/* stylelint-disable */
|
|
2
4
|
/**
|
|
3
5
|
* Calculates a rem-based value by a given pixel size.
|
|
@@ -280,7 +282,7 @@ html[data-theme=dark] .prokodo-DatePicker--info, [data-theme=dark] .prokodo-Date
|
|
|
280
282
|
position: absolute;
|
|
281
283
|
top: calc(100% + var(--pk-space-xs));
|
|
282
284
|
left: 0;
|
|
283
|
-
z-index:
|
|
285
|
+
z-index: var(--pk-z-popover, 1400);
|
|
284
286
|
min-width: var(--pk-dp-dialog-min-width);
|
|
285
287
|
width: -moz-max-content;
|
|
286
288
|
width: max-content;
|
|
@@ -340,7 +342,7 @@ html[data-theme=dark] .prokodo-DatePicker__dialog, [data-theme=dark] .prokodo-Da
|
|
|
340
342
|
display: block;
|
|
341
343
|
position: fixed;
|
|
342
344
|
inset: 0;
|
|
343
|
-
z-index:
|
|
345
|
+
z-index: var(--pk-z-popover, 1400);
|
|
344
346
|
background: rgba(0, 0, 0, 0.5);
|
|
345
347
|
backdrop-filter: blur(4px);
|
|
346
348
|
-webkit-backdrop-filter: blur(4px);
|
|
@@ -280,7 +280,7 @@ html[data-theme=dark] .prokodo-DatePicker--info, [data-theme=dark] .prokodo-Date
|
|
|
280
280
|
position: absolute;
|
|
281
281
|
top: calc(100% + var(--pk-space-xs));
|
|
282
282
|
left: 0;
|
|
283
|
-
z-index:
|
|
283
|
+
z-index: var(--pk-z-popover, 1400);
|
|
284
284
|
min-width: var(--pk-dp-dialog-min-width);
|
|
285
285
|
width: -moz-max-content;
|
|
286
286
|
width: max-content;
|
|
@@ -340,7 +340,7 @@ html[data-theme=dark] .prokodo-DatePicker__dialog, [data-theme=dark] .prokodo-Da
|
|
|
340
340
|
display: block;
|
|
341
341
|
position: fixed;
|
|
342
342
|
inset: 0;
|
|
343
|
-
z-index:
|
|
343
|
+
z-index: var(--pk-z-popover, 1400);
|
|
344
344
|
background: rgba(0, 0, 0, 0.5);
|
|
345
345
|
backdrop-filter: blur(4px);
|
|
346
346
|
-webkit-backdrop-filter: blur(4px);
|
|
@@ -52,7 +52,8 @@ function DatePickerView({
|
|
|
52
52
|
viewMode,
|
|
53
53
|
onViewModeChange,
|
|
54
54
|
onMonthSelect,
|
|
55
|
-
onYearSelect
|
|
55
|
+
onYearSelect,
|
|
56
|
+
dialogStyle
|
|
56
57
|
}) {
|
|
57
58
|
const effectiveFormat = format ?? (withTime ? "YYYY-MM-DDTHH:mm" : "YYYY-MM-DD");
|
|
58
59
|
const displayValue = (selectedDate == null ? void 0 : selectedDate.format(effectiveFormat)) ?? "";
|
|
@@ -103,6 +104,7 @@ function DatePickerView({
|
|
|
103
104
|
prevAriaLabel,
|
|
104
105
|
prevIcon,
|
|
105
106
|
selectedDate,
|
|
107
|
+
style: dialogStyle,
|
|
106
108
|
timeLabel,
|
|
107
109
|
todayLabel,
|
|
108
110
|
viewingMonth,
|
|
@@ -42,7 +42,8 @@ function DatePickerDialog({
|
|
|
42
42
|
viewMode = "days",
|
|
43
43
|
onViewModeChange,
|
|
44
44
|
onMonthSelect,
|
|
45
|
-
onYearSelect
|
|
45
|
+
onYearSelect,
|
|
46
|
+
style
|
|
46
47
|
}) {
|
|
47
48
|
const calendarDays = buildCalendarGrid(viewingMonth, minDate, maxDate);
|
|
48
49
|
const hours = buildHours();
|
|
@@ -63,6 +64,7 @@ function DatePickerDialog({
|
|
|
63
64
|
"aria-modal": "true",
|
|
64
65
|
id: `${name}-dialog`,
|
|
65
66
|
role: "dialog",
|
|
67
|
+
style,
|
|
66
68
|
className: [
|
|
67
69
|
bem("dialog"),
|
|
68
70
|
dialogColor ? bem(void 0, { [dialogColor]: true }) : ""
|
|
@@ -45,6 +45,14 @@ function DialogClient({
|
|
|
45
45
|
useEffect(() => {
|
|
46
46
|
if (open) openDialog();
|
|
47
47
|
}, [open, openDialog]);
|
|
48
|
+
useEffect(() => {
|
|
49
|
+
if (!isOpen) return;
|
|
50
|
+
const prev = document.body.style.overflow;
|
|
51
|
+
document.body.style.overflow = "hidden";
|
|
52
|
+
return () => {
|
|
53
|
+
document.body.style.overflow = prev;
|
|
54
|
+
};
|
|
55
|
+
}, [isOpen]);
|
|
48
56
|
useEffect(() => {
|
|
49
57
|
if (!isOpen) return;
|
|
50
58
|
const handleKey = /* @__PURE__ */ __name((e) => {
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
@import "../button/Button.css";
|
|
2
|
+
|
|
1
3
|
/* stylelint-disable */
|
|
2
4
|
/**
|
|
3
5
|
* Calculates a rem-based value by a given pixel size.
|
|
@@ -150,6 +152,9 @@
|
|
|
150
152
|
align-items: center;
|
|
151
153
|
z-index: var(--pk-z-modal);
|
|
152
154
|
}
|
|
155
|
+
.prokodo-Dialog--is-visible {
|
|
156
|
+
display: flex;
|
|
157
|
+
}
|
|
153
158
|
.prokodo-Dialog__backdrop {
|
|
154
159
|
display: none;
|
|
155
160
|
position: fixed;
|
|
@@ -158,16 +163,11 @@
|
|
|
158
163
|
align-items: center;
|
|
159
164
|
z-index: var(--pk-z-modal);
|
|
160
165
|
background-color: rgb(var(--pk-color-overlay-rgb)/var(--pk-color-overlay-alpha));
|
|
161
|
-
}
|
|
162
|
-
.prokodo-Dialog__backdrop {
|
|
163
166
|
animation: Dialog_backdropFadeIn var(--pk-timing-normal) ease;
|
|
164
167
|
}
|
|
165
168
|
.prokodo-Dialog__backdrop--is-visible {
|
|
166
169
|
display: flex;
|
|
167
170
|
}
|
|
168
|
-
.prokodo-Dialog--is-visible {
|
|
169
|
-
display: flex;
|
|
170
|
-
}
|
|
171
171
|
.prokodo-Dialog__backdrop .prokodo-Dialog, .prokodo-Dialog__backdrop .prokodo-Dialog--is-visible {
|
|
172
172
|
position: static;
|
|
173
173
|
inset: auto;
|
|
@@ -150,6 +150,9 @@
|
|
|
150
150
|
align-items: center;
|
|
151
151
|
z-index: var(--pk-z-modal);
|
|
152
152
|
}
|
|
153
|
+
.prokodo-Dialog--is-visible {
|
|
154
|
+
display: flex;
|
|
155
|
+
}
|
|
153
156
|
.prokodo-Dialog__backdrop {
|
|
154
157
|
display: none;
|
|
155
158
|
position: fixed;
|
|
@@ -158,16 +161,11 @@
|
|
|
158
161
|
align-items: center;
|
|
159
162
|
z-index: var(--pk-z-modal);
|
|
160
163
|
background-color: rgb(var(--pk-color-overlay-rgb)/var(--pk-color-overlay-alpha));
|
|
161
|
-
}
|
|
162
|
-
.prokodo-Dialog__backdrop {
|
|
163
164
|
animation: Dialog_backdropFadeIn var(--pk-timing-normal) ease;
|
|
164
165
|
}
|
|
165
166
|
.prokodo-Dialog__backdrop--is-visible {
|
|
166
167
|
display: flex;
|
|
167
168
|
}
|
|
168
|
-
.prokodo-Dialog--is-visible {
|
|
169
|
-
display: flex;
|
|
170
|
-
}
|
|
171
169
|
.prokodo-Dialog__backdrop .prokodo-Dialog, .prokodo-Dialog__backdrop .prokodo-Dialog--is-visible {
|
|
172
170
|
position: static;
|
|
173
171
|
inset: auto;
|
|
@@ -2,10 +2,10 @@ const Dialog_backdropFadeIn = "Dialog_backdropFadeIn";
|
|
|
2
2
|
const Dialog_fadeIn = "Dialog_fadeIn";
|
|
3
3
|
const styles = {
|
|
4
4
|
"prokodo-Dialog": "prokodo-Dialog",
|
|
5
|
+
"prokodo-Dialog--is-visible": "prokodo-Dialog--is-visible",
|
|
5
6
|
"prokodo-Dialog__backdrop": "prokodo-Dialog__backdrop",
|
|
6
7
|
Dialog_backdropFadeIn,
|
|
7
8
|
"prokodo-Dialog__backdrop--is-visible": "prokodo-Dialog__backdrop--is-visible",
|
|
8
|
-
"prokodo-Dialog--is-visible": "prokodo-Dialog--is-visible",
|
|
9
9
|
"prokodo-Dialog__container": "prokodo-Dialog__container",
|
|
10
10
|
Dialog_fadeIn,
|
|
11
11
|
"prokodo-Dialog__container--fullScreen": "prokodo-Dialog__container--fullScreen",
|
|
@@ -1,3 +1,18 @@
|
|
|
1
|
+
@import "../autocomplete/Autocomplete.css";
|
|
2
|
+
@import "../button/Button.css";
|
|
3
|
+
@import "../checkbox/Checkbox.css";
|
|
4
|
+
@import "../checkbox-group/CheckboxGroup.css";
|
|
5
|
+
@import "../datePicker/DatePicker.css";
|
|
6
|
+
@import "../dynamic-list/DynamicList.css";
|
|
7
|
+
@import "../grid/Grid.css";
|
|
8
|
+
@import "../headline/Headline.css";
|
|
9
|
+
@import "../input/Input.css";
|
|
10
|
+
@import "../inputOTP/InputOTP.css";
|
|
11
|
+
@import "../rating/Rating.css";
|
|
12
|
+
@import "../select/Select.css";
|
|
13
|
+
@import "../slider/Slider.css";
|
|
14
|
+
@import "../switch/Switch.css";
|
|
15
|
+
|
|
1
16
|
/* stylelint-disable */
|
|
2
17
|
/**
|
|
3
18
|
* Calculates a rem-based value by a given pixel size.
|
|
@@ -151,4 +166,173 @@
|
|
|
151
166
|
|
|
152
167
|
.prokodo-FormField {
|
|
153
168
|
padding-bottom: 1rem;
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
/* stylelint-disable */
|
|
172
|
+
/**
|
|
173
|
+
* Calculates a rem-based value by a given pixel size.
|
|
174
|
+
*/
|
|
175
|
+
/* stylelint-disable */
|
|
176
|
+
/**
|
|
177
|
+
* Applies flex-column and gap.
|
|
178
|
+
*/
|
|
179
|
+
/*
|
|
180
|
+
As example (light, primary)
|
|
181
|
+
See defined modes in designsystem/config/gradients
|
|
182
|
+
*/
|
|
183
|
+
/**
|
|
184
|
+
* Mixin that renders a media query that target screens that are larger than the
|
|
185
|
+
* given size.
|
|
186
|
+
*/
|
|
187
|
+
/**
|
|
188
|
+
* Mixin that renders a media query that target screens that are smaller than the
|
|
189
|
+
* given size.
|
|
190
|
+
*/
|
|
191
|
+
/**
|
|
192
|
+
* Mixin that renders a media query that target screens in between the given range.
|
|
193
|
+
*/
|
|
194
|
+
/**
|
|
195
|
+
* Mixin that renders a media query that target screens that have height larger than the
|
|
196
|
+
* given size.
|
|
197
|
+
*/
|
|
198
|
+
/**
|
|
199
|
+
* Mixin that renders a media query that target screens that have height smaller than the
|
|
200
|
+
* given size.
|
|
201
|
+
*/
|
|
202
|
+
/* stylelint-disable */
|
|
203
|
+
/* M3/Elevation Light/1 */
|
|
204
|
+
/* M3/Elevation Light/2 */
|
|
205
|
+
/* M3/Elevation/5 */
|
|
206
|
+
/* M3/Elevation/1 Text */
|
|
207
|
+
/* Inner elevations */
|
|
208
|
+
/* stylelint-disable */
|
|
209
|
+
/**
|
|
210
|
+
* Visually hides an element but not removes them for screen readers.
|
|
211
|
+
*/
|
|
212
|
+
/**
|
|
213
|
+
* The inverse of the `hidden` helper to reset a previously hidden element to be
|
|
214
|
+
* visible for users.
|
|
215
|
+
*/
|
|
216
|
+
/**
|
|
217
|
+
* Creates a selector for :hover effects depending on the current user input
|
|
218
|
+
* device. If the input device is a mouse, this hover effect will appear.
|
|
219
|
+
* Keyboard and touch inputs are ignored.
|
|
220
|
+
*
|
|
221
|
+
* Example usage:
|
|
222
|
+
* .link {
|
|
223
|
+
* color: blue;
|
|
224
|
+
*
|
|
225
|
+
* @include when-hovered() {
|
|
226
|
+
* color: green;
|
|
227
|
+
* }
|
|
228
|
+
* }
|
|
229
|
+
*/
|
|
230
|
+
/**
|
|
231
|
+
* Creates a selector for :active effects depending on the current user input
|
|
232
|
+
* device. The state applies when the input device is a mouse or keyboard. Touch
|
|
233
|
+
* devices will not show a pressed state.
|
|
234
|
+
*
|
|
235
|
+
* Example usage:
|
|
236
|
+
* .link {
|
|
237
|
+
* box-shadow: none;
|
|
238
|
+
*
|
|
239
|
+
* @include when-pressed() {
|
|
240
|
+
* box-shadow: inset 0 2px 4px grey;
|
|
241
|
+
* }
|
|
242
|
+
* }
|
|
243
|
+
*/
|
|
244
|
+
/**
|
|
245
|
+
* Creates a selector for :focus effects depending on the current user input
|
|
246
|
+
* device. When the user navigates using a keyboard, the focus effect defined in
|
|
247
|
+
* here is applied. For other input devices they don't show up.
|
|
248
|
+
*
|
|
249
|
+
* Example usage:
|
|
250
|
+
* .link {
|
|
251
|
+
* text-decoration: none;
|
|
252
|
+
*
|
|
253
|
+
* @include when-focused() {
|
|
254
|
+
* text-decoration: underline;
|
|
255
|
+
* }
|
|
256
|
+
* }
|
|
257
|
+
*/
|
|
258
|
+
/**
|
|
259
|
+
* Creates a selector for :focus-within effects depending on the current user
|
|
260
|
+
* input device. When the user navigates using a keyboard, the focus effect
|
|
261
|
+
* defined in here is applied. For other input devices they don't show up.
|
|
262
|
+
*
|
|
263
|
+
* Example usage:
|
|
264
|
+
* .link {
|
|
265
|
+
* img {
|
|
266
|
+
* opacity: 0.75;
|
|
267
|
+
*
|
|
268
|
+
* @include when-focused-within() {
|
|
269
|
+
* opacity: 1;
|
|
270
|
+
* }
|
|
271
|
+
* }
|
|
272
|
+
* }
|
|
273
|
+
*/
|
|
274
|
+
/**
|
|
275
|
+
* Wrapper for media query "prefers-reduced-motion".
|
|
276
|
+
*/
|
|
277
|
+
/**
|
|
278
|
+
* This helper hides the outline but still makes it visible for
|
|
279
|
+
* Windows high-contrast users. Use this instead of `outline: 0;`.
|
|
280
|
+
*/
|
|
281
|
+
/**
|
|
282
|
+
* This helper hides the outline but still makes it visible for
|
|
283
|
+
* Windows high-contrast users. Use this instead of `outline: 0;`.
|
|
284
|
+
*/
|
|
285
|
+
/**
|
|
286
|
+
* Renders an alternative, but application consistent focus-ring.
|
|
287
|
+
*/
|
|
288
|
+
/**
|
|
289
|
+
* Specifies the outer layout for all contents across breakpoints. Apply this
|
|
290
|
+
* mixin to the container element, to center the contents on the screen within
|
|
291
|
+
* the layout offsets.
|
|
292
|
+
*/
|
|
293
|
+
/**
|
|
294
|
+
* This mixin specifies basic text-styles for components that render a richtext
|
|
295
|
+
* content.
|
|
296
|
+
*/
|
|
297
|
+
.prokodo-FormResponse {
|
|
298
|
+
padding: 0 1rem;
|
|
299
|
+
}
|
|
300
|
+
.prokodo-FormResponse__success {
|
|
301
|
+
color: var(--color-success);
|
|
302
|
+
font-weight: 700;
|
|
303
|
+
}
|
|
304
|
+
.prokodo-FormResponse__errors {
|
|
305
|
+
display: block;
|
|
306
|
+
margin-bottom: 0.75rem;
|
|
307
|
+
color: var(--color-grey-300);
|
|
308
|
+
}
|
|
309
|
+
.prokodo-FormResponse__errors__item {
|
|
310
|
+
display: block;
|
|
311
|
+
padding-bottom: 1rem;
|
|
312
|
+
font-weight: 500;
|
|
313
|
+
font-size: 1.125rem;
|
|
314
|
+
font-family: var(--font-secondary), -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
|
|
315
|
+
font-style: normal;
|
|
316
|
+
line-height: 1.55;
|
|
317
|
+
letter-spacing: 0.03em;
|
|
318
|
+
text-transform: none;
|
|
319
|
+
text-align: left;
|
|
320
|
+
text-decoration: none;
|
|
321
|
+
}
|
|
322
|
+
@media screen and (min-width: 480px) {
|
|
323
|
+
.prokodo-FormResponse__errors__item {
|
|
324
|
+
font-size: 1.125rem;
|
|
325
|
+
line-height: 1.5;
|
|
326
|
+
}
|
|
327
|
+
}
|
|
328
|
+
@media screen and (min-width: 960px) {
|
|
329
|
+
.prokodo-FormResponse__errors__item {
|
|
330
|
+
font-size: 1.125rem;
|
|
331
|
+
line-height: 1.5;
|
|
332
|
+
}
|
|
333
|
+
}
|
|
334
|
+
.prokodo-FormResponse__errors__desc {
|
|
335
|
+
display: block;
|
|
336
|
+
padding: 0;
|
|
337
|
+
color: var(--color-error);
|
|
154
338
|
}
|
|
@@ -26,7 +26,7 @@ function FormFieldClient({
|
|
|
26
26
|
onValidate,
|
|
27
27
|
...props
|
|
28
28
|
}) {
|
|
29
|
-
var _a, _b, _c, _d;
|
|
29
|
+
var _a, _b, _c, _d, _e, _f;
|
|
30
30
|
const renderFieldContainer = useCallback(
|
|
31
31
|
(children) => /* @__PURE__ */ jsx(GridRow, { className: bem(), xs: 12, children }),
|
|
32
32
|
[]
|
|
@@ -66,6 +66,8 @@ function FormFieldClient({
|
|
|
66
66
|
priority: true,
|
|
67
67
|
color,
|
|
68
68
|
...props,
|
|
69
|
+
closeAriaLabel: props.closeAriaLabel ?? ((_a = messagesFields == null ? void 0 : messagesFields.select) == null ? void 0 : _a.closeAriaLabel),
|
|
70
|
+
doneLabel: props.doneLabel ?? ((_b = messagesFields == null ? void 0 : messagesFields.select) == null ? void 0 : _b.doneLabel),
|
|
69
71
|
onChange: (
|
|
70
72
|
/* istanbul ignore next */
|
|
71
73
|
/* @__PURE__ */ __name((_, value) => onChange == null ? void 0 : onChange(props, value ?? void 0), "onChange")
|
|
@@ -80,7 +82,7 @@ function FormFieldClient({
|
|
|
80
82
|
{
|
|
81
83
|
priority: true,
|
|
82
84
|
color,
|
|
83
|
-
errorTranslations: (
|
|
85
|
+
errorTranslations: (_c = messagesFields == null ? void 0 : messagesFields.errors) == null ? void 0 : _c.input,
|
|
84
86
|
onValidate: /* @__PURE__ */ __name((_, err) => onValidate == null ? void 0 : onValidate(props, err), "onValidate"),
|
|
85
87
|
onChange: /* @__PURE__ */ __name((e) => onChange == null ? void 0 : onChange(props, e.target.value), "onChange"),
|
|
86
88
|
...props
|
|
@@ -95,7 +97,7 @@ function FormFieldClient({
|
|
|
95
97
|
priority: true,
|
|
96
98
|
color,
|
|
97
99
|
...props,
|
|
98
|
-
translations: (
|
|
100
|
+
translations: (_d = messagesFields == null ? void 0 : messagesFields.errors) == null ? void 0 : _d.date,
|
|
99
101
|
onValidate: /* @__PURE__ */ __name((_, err) => onValidate == null ? void 0 : onValidate(props, err), "onValidate"),
|
|
100
102
|
onChange: /* @__PURE__ */ __name((value) => onChange == null ? void 0 : onChange(
|
|
101
103
|
props,
|
|
@@ -117,7 +119,7 @@ function FormFieldClient({
|
|
|
117
119
|
color,
|
|
118
120
|
...p,
|
|
119
121
|
value: p == null ? void 0 : p.value,
|
|
120
|
-
fields: (
|
|
122
|
+
fields: (_e = p == null ? void 0 : p.fields) == null ? void 0 : _e.map((field) => ({
|
|
121
123
|
...field,
|
|
122
124
|
onValidate: /* @__PURE__ */ __name((_, err) => onValidate == null ? void 0 : onValidate(p, err), "onValidate")
|
|
123
125
|
})),
|
|
@@ -133,7 +135,7 @@ function FormFieldClient({
|
|
|
133
135
|
priority: true,
|
|
134
136
|
color,
|
|
135
137
|
...props,
|
|
136
|
-
errorTranslations: (
|
|
138
|
+
errorTranslations: (_f = messagesFields == null ? void 0 : messagesFields.errors) == null ? void 0 : _f.input,
|
|
137
139
|
onValidate: /* @__PURE__ */ __name((_, err) => onValidate == null ? void 0 : onValidate(props, err), "onValidate"),
|
|
138
140
|
onChange: /* @__PURE__ */ __name((e) => {
|
|
139
141
|
var _a2;
|