math-main-components 0.0.132 → 0.0.135
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/README.md +13 -0
- package/dist/components/Button/Button.d.ts +8 -0
- package/dist/components/Button/index.d.ts +1 -0
- package/dist/components/EmptyCard/index.d.ts +8 -0
- package/dist/components/Table/Table.d.ts +4 -1
- package/dist/components/index.d.ts +1 -1
- package/dist/index.cjs.js +104 -88
- package/dist/index.d.ts +1 -1
- package/dist/index.esm.js +104 -88
- package/dist/types/Feedback.d.ts +1 -0
- package/package.json +3 -1
package/README.md
CHANGED
@@ -5,6 +5,19 @@ Component Library for math-main-app
|
|
5
5
|
- reusable ui components
|
6
6
|
- math components
|
7
7
|
|
8
|
+
### Run Locally
|
9
|
+
|
10
|
+
Install [`yalc`](https://github.com/wclr/yalc) globally by running `yarn global add yalc`
|
11
|
+
|
12
|
+
In order to make the workflow more efficient, you can link the local package to the main app.
|
13
|
+
1. Go to `math-main-components` and run `yalc publish`. (only need to do this once)
|
14
|
+
2. Then go to `math-main-components` and run `yarn dev`.
|
15
|
+
3. Then go to `math-main-app` and run `yalc link math-main-components`.
|
16
|
+
|
17
|
+
No need to change anything in the `package.json` file.
|
18
|
+
|
19
|
+
In order to unlink the packages, run `yarn retreat math-main-components` in app directory.
|
20
|
+
|
8
21
|
## Notes
|
9
22
|
- Do not use any of next.js features like next/link
|
10
23
|
|
@@ -0,0 +1,8 @@
|
|
1
|
+
import React, { MouseEvent } from 'react';
|
2
|
+
export declare function Button({ text, iconName, iconFill, type, onClick }: {
|
3
|
+
text?: string;
|
4
|
+
iconName?: string;
|
5
|
+
iconFill?: string;
|
6
|
+
type?: string;
|
7
|
+
onClick?: (event: MouseEvent<HTMLButtonElement>) => void;
|
8
|
+
}): React.JSX.Element;
|
@@ -0,0 +1 @@
|
|
1
|
+
export { Button } from './Button';
|
@@ -13,7 +13,7 @@ export type TableItemAction<DataType> = {
|
|
13
13
|
onClick: (event: MouseEvent<HTMLDivElement>, item: TableItem<DataType>, index: number) => void;
|
14
14
|
type: TableActionType;
|
15
15
|
};
|
16
|
-
export declare function Table<DataType>({ items, title, actions, moreActions, selected, style, marginTop }: {
|
16
|
+
export declare function Table<DataType>({ items, title, actions, moreActions, selected, style, marginTop, emptyTitle, emptySubtitle, emptyIconName }: {
|
17
17
|
items: TableItem<DataType>[];
|
18
18
|
title: string;
|
19
19
|
selected?: number;
|
@@ -21,4 +21,7 @@ export declare function Table<DataType>({ items, title, actions, moreActions, se
|
|
21
21
|
actions?: TableItemAction<DataType>[];
|
22
22
|
moreActions?: ((data: DataType, index: number) => ReactNode)[];
|
23
23
|
marginTop?: number;
|
24
|
+
emptyTitle?: string;
|
25
|
+
emptySubtitle?: string;
|
26
|
+
emptyIconName?: string;
|
24
27
|
}): React.JSX.Element;
|
@@ -1,5 +1,6 @@
|
|
1
1
|
export * from './Accordeon';
|
2
2
|
export * from './AuthButton';
|
3
|
+
export * from './Button';
|
3
4
|
export * from './CardButton';
|
4
5
|
export * from './Checkbox';
|
5
6
|
export * from './ChooseRole';
|
@@ -17,7 +18,6 @@ export * from './InputPin';
|
|
17
18
|
export * from './InputText';
|
18
19
|
export * from './OptionField';
|
19
20
|
export * from './OptionFieldHorizontal';
|
20
|
-
export * from './PrimaryButton';
|
21
21
|
export * from './ProgressBar';
|
22
22
|
export * from './RadioButtons';
|
23
23
|
export * from './RedirectButton';
|
package/dist/index.cjs.js
CHANGED
@@ -40,30 +40,46 @@ function styleInject(css, ref) {
|
|
40
40
|
}
|
41
41
|
}
|
42
42
|
|
43
|
-
var css_248z$
|
44
|
-
var styles$
|
45
|
-
styleInject(css_248z$
|
43
|
+
var css_248z$v = ".styles-module_container__3IVfB {\n margin-bottom: 20px;\n background: var(--background-1);\n border-radius: 30px;\n transition: 0.2s ease-in-out;\n color: var(--foreground-1);\n}\n.styles-module_container__3IVfB .styles-module_head__xFYQb {\n display: flex;\n flex-direction: row;\n align-items: center;\n padding: 16px 20px;\n color: var(--foreground-3);\n background: var(--background-2);\n border-radius: 30px;\n cursor: pointer;\n user-select: none;\n -webkit-user-select: none;\n transition: 0.2s ease-in-out;\n gap: 10px;\n}\n.styles-module_container__3IVfB .styles-module_head__xFYQb span {\n transition: 0.2s ease-in-out;\n}\n.styles-module_container__3IVfB .styles-module_head__xFYQb h3 {\n margin: 0;\n font-weight: 400;\n font-size: 16px;\n user-select: none;\n -webkit-user-select: none;\n}\n.styles-module_container__3IVfB .styles-module_head__xFYQb:hover {\n filter: brightness(0.95);\n}\n.styles-module_container__3IVfB.styles-module_active__soD8R {\n box-shadow: rgba(0, 0, 0, 0.05) 0px 6px 24px 0px, rgba(0, 0, 0, 0.08) 0px 0px 0px 1px;\n}\n.styles-module_container__3IVfB.styles-module_active__soD8R .styles-module_head__xFYQb span {\n rotate: 180deg;\n}\n.styles-module_container__3IVfB .styles-module_content__XAf02 {\n transition: all 0.3s ease-in-out;\n line-height: 1.5;\n}\n.styles-module_container__3IVfB.styles-module_not_active__JcVLz .styles-module_content__XAf02 {\n height: 0;\n max-height: 0;\n overflow: hidden;\n opacity: 0;\n}\n.styles-module_container__3IVfB.styles-module_active__soD8R .styles-module_content__XAf02 {\n max-height: auto;\n overflow: visible;\n opacity: 1;\n padding: 10px 0px;\n}";
|
44
|
+
var styles$v = {"container":"styles-module_container__3IVfB","head":"styles-module_head__xFYQb","active":"styles-module_active__soD8R","content":"styles-module_content__XAf02","not_active":"styles-module_not_active__JcVLz"};
|
45
|
+
styleInject(css_248z$v);
|
46
46
|
|
47
47
|
function Accordeon({ title, children }) {
|
48
48
|
const [isActive, setActive] = React.useState(false);
|
49
|
-
return (React__default["default"].createElement("div", { className: [styles$
|
50
|
-
React__default["default"].createElement("div", { className: styles$
|
49
|
+
return (React__default["default"].createElement("div", { className: [styles$v.container, isActive ? styles$v.active : styles$v.not_active].join(" ") },
|
50
|
+
React__default["default"].createElement("div", { className: styles$v.head, onClick: () => setActive(!isActive) },
|
51
51
|
React__default["default"].createElement(SvgIcon, { iconName: "expand_more" }),
|
52
52
|
React__default["default"].createElement("h3", null, title)),
|
53
|
-
React__default["default"].createElement("div", { className: styles$
|
53
|
+
React__default["default"].createElement("div", { className: styles$v.content }, children)));
|
54
54
|
}
|
55
55
|
|
56
|
-
var css_248z$
|
57
|
-
var styles$
|
58
|
-
styleInject(css_248z$
|
56
|
+
var css_248z$u = ".styles-module_container__4978M {\n max-width: 100%;\n width: 350px;\n transition: all 0.2s ease-in-out;\n box-sizing: border-box;\n}\n.styles-module_container__4978M.styles-module_visible__uvQwq {\n max-height: 100px;\n opacity: 1;\n}\n.styles-module_container__4978M.styles-module_hidden__Oruyx {\n overflow: hidden;\n max-height: 0;\n opacity: 0;\n}\n\n.styles-module_container__4978M.styles-module_rotate__mmYPQ .styles-module_button__BWOOi:hover span {\n rotate: -45deg;\n}\n\n.styles-module_button__BWOOi {\n padding: 12px 20px;\n background: linear-gradient(60deg, #0075FF, #0056b8);\n background-position-x: right;\n color: white;\n display: flex;\n flex-direction: row;\n width: 100%;\n align-items: center;\n justify-content: center;\n border-radius: 14px;\n border: none;\n cursor: pointer;\n font-size: 16px;\n font-weight: 400;\n gap: 10px;\n position: relative;\n transition: all 0.5s ease-in-out;\n}\n.styles-module_button__BWOOi span {\n transition: 0.1s ease-in-out;\n}\n.styles-module_button__BWOOi:hover {\n background-position-x: left;\n}\n.styles-module_button__BWOOi.styles-module_secondary__Eoik3 {\n background: var(--background-2);\n color: var(--primary-1);\n border: 1px solid var(--primary-1);\n}\n.styles-module_button__BWOOi.styles-module_secondary__Eoik3 svg {\n fill: var(--primary-1);\n}\n\n@media (max-width: 450px) {\n .styles-module_button__BWOOi {\n font-size: 14px;\n }\n}";
|
57
|
+
var styles$u = {"container":"styles-module_container__4978M","visible":"styles-module_visible__uvQwq","hidden":"styles-module_hidden__Oruyx","rotate":"styles-module_rotate__mmYPQ","button":"styles-module_button__BWOOi","secondary":"styles-module_secondary__Eoik3"};
|
58
|
+
styleInject(css_248z$u);
|
59
59
|
|
60
60
|
function AuthButton({ text, type = "submit", theme = "primary", iconName = "arrow_forward", isVisible = true, onClick }) {
|
61
|
-
return (React__default["default"].createElement("div", { className: [styles$
|
62
|
-
React__default["default"].createElement("button", { type: type, className: `${styles$
|
61
|
+
return (React__default["default"].createElement("div", { className: [styles$u.container, isVisible ? styles$u.visible : styles$u.hidden, ["arrow_forward"].includes(iconName) ? styles$u.rotate : null].join(" ") },
|
62
|
+
React__default["default"].createElement("button", { type: type, className: `${styles$u.button} ${styles$u[theme]}`, onClick: onClick },
|
63
63
|
text,
|
64
64
|
React__default["default"].createElement(SvgIcon, { iconName: iconName }))));
|
65
65
|
}
|
66
66
|
|
67
|
+
var css_248z$t = ".styles-module_container__TP0rp {\n max-width: 100%;\n}\n.styles-module_container__TP0rp .styles-module_button__Sh-fr {\n padding: 10px 18px;\n background: var(--primary-1);\n border-radius: 40px;\n cursor: pointer;\n display: flex;\n flex-direction: row;\n gap: 10px;\n font-size: 15px;\n font-weight: 400;\n color: white;\n align-items: center;\n border: none;\n}\n.styles-module_container__TP0rp .styles-module_button__Sh-fr.styles-module_onlyIcon__bNVnI {\n width: 44px;\n height: 44px;\n padding: 0;\n align-items: center;\n justify-content: center;\n}\n.styles-module_container__TP0rp .styles-module_button__Sh-fr.styles-module_onlyIcon__bNVnI span {\n font-size: 22px !important;\n}\n.styles-module_container__TP0rp .styles-module_button__Sh-fr.styles-module_red__EhImH {\n background: var(--red-1);\n color: white;\n}\n.styles-module_container__TP0rp .styles-module_button__Sh-fr.styles-module_grey__kAVD1 {\n background: var(--background-1);\n color: var(--foreground-2);\n}";
|
68
|
+
var styles$t = {"container":"styles-module_container__TP0rp","button":"styles-module_button__Sh-fr","onlyIcon":"styles-module_onlyIcon__bNVnI","red":"styles-module_red__EhImH","grey":"styles-module_grey__kAVD1"};
|
69
|
+
styleInject(css_248z$t);
|
70
|
+
|
71
|
+
function Button({ text, iconName, iconFill = "white", type = "blue", onClick = () => { } }) {
|
72
|
+
function onClickButton(event) {
|
73
|
+
event.preventDefault();
|
74
|
+
if (onClick)
|
75
|
+
onClick(event);
|
76
|
+
}
|
77
|
+
return (React__default["default"].createElement("div", { className: styles$t.container },
|
78
|
+
React__default["default"].createElement("button", { className: [styles$t.button, styles$t[type], (text && !iconName) ? styles$t.onlyText : "", (!text && iconName) ? styles$t.onlyIcon : ""].join(" "), onClick: onClickButton },
|
79
|
+
text,
|
80
|
+
iconName && React__default["default"].createElement(SvgIcon, { iconName: iconName, fill: iconFill }))));
|
81
|
+
}
|
82
|
+
|
67
83
|
var css_248z$s = ".styles-module_card__bOd85 {\n background: var(--background-2);\n border: 1px solid var(--border-2);\n border-radius: 18px;\n transition: 0.2s ease;\n padding: 18px 14px;\n box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.2509803922);\n cursor: pointer;\n text-align: center;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n gap: 10px;\n padding-top: 30px;\n}\n.styles-module_card__bOd85 span {\n color: var(--foreground-3);\n}\n.styles-module_card__bOd85:hover {\n transform: scale(1.01);\n box-shadow: none;\n background: none;\n}\n.styles-module_card__bOd85 h2 {\n margin-top: 0;\n color: var(--foreground-3);\n font-weight: 400;\n font-size: 18px;\n}";
|
68
84
|
var styles$s = {"card":"styles-module_card__bOd85"};
|
69
85
|
styleInject(css_248z$s);
|
@@ -419,36 +435,20 @@ function OptionFieldHorizontal({ title, iconName, onClick, preselected = false }
|
|
419
435
|
React__default["default"].createElement("h3", null, title)));
|
420
436
|
}
|
421
437
|
|
422
|
-
var css_248z$b = ".styles-
|
423
|
-
var styles$b = {"container":"styles-
|
438
|
+
var css_248z$b = ".styles-module_container__u4q5n {\n margin-bottom: 50px;\n width: 400px;\n max-width: 100%;\n}\n\n.styles-module_background__jt-ry {\n background: var(--border-2);\n height: 3px;\n position: relative;\n}\n\n.styles-module_progress__Zj-B7 {\n background: var(--foreground-1);\n position: absolute;\n left: 0;\n top: 0;\n height: 3px;\n}";
|
439
|
+
var styles$b = {"container":"styles-module_container__u4q5n","background":"styles-module_background__jt-ry","progress":"styles-module_progress__Zj-B7"};
|
424
440
|
styleInject(css_248z$b);
|
425
441
|
|
426
|
-
function PrimaryButton({ text, iconName, iconFill = "white", type = "blue", onClick = () => { } }) {
|
427
|
-
function onClickButton(event) {
|
428
|
-
event.preventDefault();
|
429
|
-
if (onClick)
|
430
|
-
onClick(event);
|
431
|
-
}
|
432
|
-
return (React__default["default"].createElement("div", { className: styles$b.container },
|
433
|
-
React__default["default"].createElement("button", { className: [styles$b.button, styles$b[type], (text && !iconName) ? styles$b.onlyText : "", (!text && iconName) ? styles$b.onlyIcon : ""].join(" "), onClick: onClickButton },
|
434
|
-
text,
|
435
|
-
iconName && React__default["default"].createElement(SvgIcon, { iconName: iconName, fill: iconFill }))));
|
436
|
-
}
|
437
|
-
|
438
|
-
var css_248z$a = ".styles-module_container__u4q5n {\n margin-bottom: 50px;\n width: 400px;\n max-width: 100%;\n}\n\n.styles-module_background__jt-ry {\n background: var(--border-2);\n height: 3px;\n position: relative;\n}\n\n.styles-module_progress__Zj-B7 {\n background: var(--foreground-1);\n position: absolute;\n left: 0;\n top: 0;\n height: 3px;\n}";
|
439
|
-
var styles$a = {"container":"styles-module_container__u4q5n","background":"styles-module_background__jt-ry","progress":"styles-module_progress__Zj-B7"};
|
440
|
-
styleInject(css_248z$a);
|
441
|
-
|
442
442
|
function ProgressBar({ length, progress }) {
|
443
443
|
return (React__default["default"].createElement(React__default["default"].Fragment, null,
|
444
|
-
React__default["default"].createElement("div", { className: styles$
|
445
|
-
React__default["default"].createElement("div", { className: styles$
|
446
|
-
React__default["default"].createElement("div", { className: styles$
|
444
|
+
React__default["default"].createElement("div", { className: styles$b.container },
|
445
|
+
React__default["default"].createElement("div", { className: styles$b.background },
|
446
|
+
React__default["default"].createElement("div", { className: styles$b.progress, style: { width: `${progress / length * 100}%` } })))));
|
447
447
|
}
|
448
448
|
|
449
|
-
var css_248z$
|
450
|
-
var styles$
|
451
|
-
styleInject(css_248z$
|
449
|
+
var css_248z$a = ".styles-module_container__Grkzw {\n display: flex;\n flex-direction: column;\n gap: 12px;\n color: var(--foreground-3);\n margin-bottom: 20px;\n}\n.styles-module_container__Grkzw [type=radio] {\n position: relative;\n left: 15px;\n top: -4px;\n z-index: 0;\n appearance: none;\n -webkit-appearance: none;\n cursor: pointer;\n margin-left: -3.5px;\n}\n.styles-module_container__Grkzw [type=radio] + label {\n position: absolute;\n cursor: pointer;\n}\n.styles-module_container__Grkzw [type=radio] + label::before {\n width: 15px;\n height: 15px;\n border-radius: 20px;\n border: 2px solid var(--border-2);\n display: block;\n content: \"\";\n float: left;\n margin-right: 8px;\n z-index: 5;\n position: relative;\n transition: 0.2s ease-in-out;\n}\n.styles-module_container__Grkzw [type=radio]:checked + label::before {\n background-color: var(--primary-2);\n border-color: var(--primary-1);\n}\n.styles-module_container__Grkzw [type=radio]:hover:not(:checked) + label::before {\n background-color: var(--background-4);\n border-color: var(--background-4);\n}";
|
450
|
+
var styles$a = {"container":"styles-module_container__Grkzw"};
|
451
|
+
styleInject(css_248z$a);
|
452
452
|
|
453
453
|
class RadioOption {
|
454
454
|
text;
|
@@ -465,7 +465,7 @@ function RadioButtons({ options, group, selected, onClick, width = "100%" }) {
|
|
465
465
|
if (onClick)
|
466
466
|
onClick(event);
|
467
467
|
}
|
468
|
-
return (React__default["default"].createElement("div", { className: styles$
|
468
|
+
return (React__default["default"].createElement("div", { className: styles$a.container, style: { width: width } }, options.map((option) => React__default["default"].createElement("div", { className: styles$a.option, key: option.name },
|
469
469
|
selected && selected == option.name ?
|
470
470
|
React__default["default"].createElement("input", { type: "radio", id: option.name, name: group, value: option.name, onInput: onUpdateSelected, defaultChecked: true })
|
471
471
|
:
|
@@ -473,9 +473,9 @@ function RadioButtons({ options, group, selected, onClick, width = "100%" }) {
|
|
473
473
|
React__default["default"].createElement("label", { htmlFor: option.name }, option.text)))));
|
474
474
|
}
|
475
475
|
|
476
|
-
var css_248z$
|
477
|
-
var styles$
|
478
|
-
styleInject(css_248z$
|
476
|
+
var css_248z$9 = ".styles-module_container__RhsQe {\n margin-right: 8px;\n}\n.styles-module_container__RhsQe .styles-module_button__HuX-0 {\n background: none;\n padding: none;\n border: none;\n width: 40px;\n height: 40px;\n transition: 0.2s;\n cursor: pointer;\n display: flex;\n justify-content: center;\n align-items: center;\n border-radius: 20px;\n}\n.styles-module_container__RhsQe .styles-module_button__HuX-0 span {\n color: var(--foreground-1);\n}\n.styles-module_container__RhsQe .styles-module_button__HuX-0:hover {\n background: var(--background-1);\n}\n.styles-module_container__RhsQe.styles-module_middle__xg7RF .styles-module_button__HuX-0 {\n flex-direction: row;\n gap: 5px;\n}\n.styles-module_container__RhsQe.styles-module_middle__xg7RF .styles-module_button__HuX-0:hover {\n background: none;\n}";
|
477
|
+
var styles$9 = {"container":"styles-module_container__RhsQe","button":"styles-module_button__HuX-0","middle":"styles-module_middle__xg7RF"};
|
478
|
+
styleInject(css_248z$9);
|
479
479
|
|
480
480
|
function RedirectButton({ type = "forward", onClick }) {
|
481
481
|
function onClickButton(event) {
|
@@ -490,16 +490,16 @@ function RedirectButton({ type = "forward", onClick }) {
|
|
490
490
|
case "middle": return "arrow_back";
|
491
491
|
}
|
492
492
|
};
|
493
|
-
return (React__default["default"].createElement("div", { className: [styles$
|
494
|
-
React__default["default"].createElement("button", { onClick: onClickButton, className: styles$
|
493
|
+
return (React__default["default"].createElement("div", { className: [styles$9.container, styles$9[type]].join(" ") },
|
494
|
+
React__default["default"].createElement("button", { onClick: onClickButton, className: styles$9.button },
|
495
495
|
React__default["default"].createElement(SvgIcon, { iconName: getIcon() }),
|
496
496
|
["middle"].includes(type) &&
|
497
497
|
React__default["default"].createElement("span", null, "Zur\u00FCck"))));
|
498
498
|
}
|
499
499
|
|
500
|
-
var css_248z$
|
501
|
-
var styles$
|
502
|
-
styleInject(css_248z$
|
500
|
+
var css_248z$8 = ".styles-module_container__VreeH {\n margin-bottom: 20px;\n display: flex;\n flex-direction: row;\n flex-wrap: wrap;\n gap: 10px;\n}\n.styles-module_container__VreeH .styles-module_chip__EvZ4J,\n.styles-module_container__VreeH .styles-module_show_all__HKn-s {\n padding: 10px 18px;\n background: var(--background-1);\n border-radius: 20px;\n display: flex;\n flex-direction: row;\n gap: 5px;\n align-items: center;\n cursor: pointer;\n user-select: none;\n -webkit-user-select: none;\n color: var(--foreground-2);\n transition: 0.2s ease-in-out;\n}\n.styles-module_container__VreeH .styles-module_chip__EvZ4J:hover {\n filter: brightness(0.95);\n}\n.styles-module_container__VreeH .styles-module_chip__EvZ4J.styles-module_selected__sArTD {\n background: var(--primary-2);\n color: var(--primary-1);\n}\n.styles-module_container__VreeH .styles-module_chip__EvZ4J.styles-module_selected__sArTD span {\n color: var(--primary-1);\n}";
|
501
|
+
var styles$8 = {"container":"styles-module_container__VreeH","chip":"styles-module_chip__EvZ4J","show_all":"styles-module_show_all__HKn-s","selected":"styles-module_selected__sArTD"};
|
502
|
+
styleInject(css_248z$8);
|
503
503
|
|
504
504
|
class SearchChip {
|
505
505
|
title;
|
@@ -520,19 +520,19 @@ function SearchChips({ items, onChange, chipsVisible = 9 }) {
|
|
520
520
|
if (onChange)
|
521
521
|
onChange(newChips);
|
522
522
|
}
|
523
|
-
return (React__default["default"].createElement("div", { className: styles$
|
524
|
-
(showAll ? chips : chips.slice(0, chipsVisible)).map((item, index) => React__default["default"].createElement("div", { key: index, onClick: (e) => onClick(item, index), className: [styles$
|
523
|
+
return (React__default["default"].createElement("div", { className: styles$8.container },
|
524
|
+
(showAll ? chips : chips.slice(0, chipsVisible)).map((item, index) => React__default["default"].createElement("div", { key: index, onClick: (e) => onClick(item, index), className: [styles$8.chip, item.selected ? styles$8.selected : styles$8.not_selected].join(" ") },
|
525
525
|
React__default["default"].createElement(SvgIcon, { iconName: item.selected ? "close" : "filter_list", size: "20px" }),
|
526
526
|
item.title)),
|
527
527
|
chipsVisible < chips.length && (showAll ?
|
528
|
-
React__default["default"].createElement("div", { className: styles$
|
528
|
+
React__default["default"].createElement("div", { className: styles$8.show_all, onClick: () => setShowAll(false) }, "Weniger anzeigen")
|
529
529
|
:
|
530
|
-
React__default["default"].createElement("div", { className: styles$
|
530
|
+
React__default["default"].createElement("div", { className: styles$8.show_all, onClick: () => setShowAll(true) }, "Mehr anzeigen"))));
|
531
531
|
}
|
532
532
|
|
533
|
-
var css_248z$
|
534
|
-
var styles$
|
535
|
-
styleInject(css_248z$
|
533
|
+
var css_248z$7 = ".styles-module_container__k4Z26 {\n width: 100%;\n display: flex;\n flex-direction: row;\n gap: 10px;\n position: relative;\n}\n.styles-module_container__k4Z26 button {\n background: var(--primary-2);\n padding: 0px 18px;\n border: none;\n font-size: 14px;\n border-radius: 10px;\n cursor: pointer;\n color: var(--primary-1);\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ-,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om {\n display: none;\n position: absolute;\n top: 60px;\n background: var(--background-1);\n box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.2509803922);\n width: 100%;\n border-radius: 14px;\n border: 1px solid var(--border-3);\n z-index: 1000;\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ-:hover,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om:hover {\n display: block;\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ- ul,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om ul {\n list-style: none;\n margin: 0;\n padding: 0;\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ- ul li,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om ul li {\n padding: 16px 20px;\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ- ul li:not(:last-child),\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om ul li:not(:last-child) {\n border-bottom: 1px solid var(--border-3);\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ- .styles-module_error__2Ov4X,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om .styles-module_error__2Ov4X {\n padding: 35px 0px;\n display: flex;\n flex-direction: column;\n align-items: center;\n gap: 15px;\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ- .styles-module_error__2Ov4X p,\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ- .styles-module_error__2Ov4X h3,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om .styles-module_error__2Ov4X p,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om .styles-module_error__2Ov4X h3 {\n margin: 0;\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ- .styles-module_error__2Ov4X p,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om .styles-module_error__2Ov4X p {\n color: var(--foreground-3);\n padding: 0px 30px;\n line-height: 1.5;\n text-align: center;\n margin-bottom: 10px;\n}\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om ul li {\n display: flex;\n flex-direction: row;\n padding: 10px 20px;\n align-items: center;\n}\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om ul li span {\n flex: 1;\n}\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om button {\n padding: 10px 16px;\n}\n\n.styles-module_input__wOJmG {\n padding: 14px 20px;\n font-size: 16px;\n width: 300px;\n border-radius: 12px;\n border: 1.5px solid var(--border-2);\n outline: none;\n transition: 0.2s ease;\n width: 100%;\n background: var(--background-1);\n color: var(--foreground-1);\n}\n.styles-module_input__wOJmG:focus, .styles-module_input__wOJmG:active {\n border-color: var(--primary-1);\n box-shadow: 0px 0px 3px 3px rgba(0, 87, 255, 0.2509803922);\n}\n\n.styles-module_form__mWTCu.styles-module_focus__-6H1f + .styles-module_suggestions_container__pceQ-,\n.styles-module_form__mWTCu.styles-module_focus__-6H1f + .styles-module_results_container__OY4Om {\n display: block;\n}\n\n/* animated text field */\n.styles-module_form__mWTCu {\n position: relative;\n width: 100%;\n}\n\n.styles-module_label__A41g9 {\n position: absolute;\n bottom: 0px;\n left: 0px;\n width: 100%;\n height: 100%;\n pointer-events: none;\n}\n\n.styles-module_label_text__NQHTC {\n position: absolute;\n bottom: 16px;\n left: 12px;\n transition: 0.3s ease;\n font-size: 16px;\n border-top-left-radius: 5px;\n border-top-right-radius: 5px;\n opacity: initial;\n background: var(--background-1);\n color: var(--foreground-3);\n padding-right: 8px;\n padding-left: 8px;\n}\n\n.styles-module_input__wOJmG.styles-module_with_title__rnN-t::placeholder {\n opacity: 0;\n transition: opacity 0.3s ease;\n color: var(--foreground-3);\n}\n\n.styles-module_input__wOJmG.styles-module_with_title__rnN-t:focus::placeholder {\n opacity: 1;\n}\n\n.styles-module_input__wOJmG:focus + .styles-module_label__A41g9 .styles-module_label_text__NQHTC,\n.styles-module_input__wOJmG.styles-module_valid__AAK-6 + .styles-module_label__A41g9 .styles-module_label_text__NQHTC {\n transform: translateY(-150%);\n left: 15px;\n font-size: 14px;\n background: var(--background-2);\n color: var(--primary-1);\n}\n\n.styles-module_input__wOJmG.styles-module_valid__AAK-6 + .styles-module_label__A41g9 .styles-module_label_text__NQHTC {\n color: var(--foreground-3);\n}";
|
534
|
+
var styles$7 = {"container":"styles-module_container__k4Z26","suggestions_container":"styles-module_suggestions_container__pceQ-","results_container":"styles-module_results_container__OY4Om","error":"styles-module_error__2Ov4X","input":"styles-module_input__wOJmG","form":"styles-module_form__mWTCu","focus":"styles-module_focus__-6H1f","label":"styles-module_label__A41g9","label_text":"styles-module_label_text__NQHTC","with_title":"styles-module_with_title__rnN-t","valid":"styles-module_valid__AAK-6"};
|
535
|
+
styleInject(css_248z$7);
|
536
536
|
|
537
537
|
function Searchbar({ placeholder, title = "Suchen", showNoResults = false, errorTitle = "Keine Ergebnisse gefunden", errorMessage = "", errorButton = "", helpTitle = "", helpMessage = "", marginBottom = 25, marginTop = 30, errorAction = () => { }, onInput = () => { }, onClickResult = () => { }, withButton = false, buttonText = "Suchen", suggestions = [], autoFocus = false, results = [] }) {
|
538
538
|
const [value, setValue] = React.useState("");
|
@@ -561,34 +561,34 @@ function Searchbar({ placeholder, title = "Suchen", showNoResults = false, error
|
|
561
561
|
element.focus();
|
562
562
|
}, [autoFocus]);
|
563
563
|
return (React__default["default"].createElement(React__default["default"].Fragment, null,
|
564
|
-
React__default["default"].createElement("div", { className: styles$
|
565
|
-
React__default["default"].createElement("div", { className: `${styles$
|
566
|
-
React__default["default"].createElement("input", { onFocus: () => setFocused(true), onBlur: () => setFocused(false), className: `${styles$
|
567
|
-
React__default["default"].createElement("label", { htmlFor: "text", className: styles$
|
568
|
-
React__default["default"].createElement("span", { className: styles$
|
564
|
+
React__default["default"].createElement("div", { className: styles$7.container, style: { marginTop: marginTop, marginBottom: marginBottom } },
|
565
|
+
React__default["default"].createElement("div", { className: `${styles$7.form} ${inputFocused ? styles$7.focus : styles$7.not_focused}` },
|
566
|
+
React__default["default"].createElement("input", { onFocus: () => setFocused(true), onBlur: () => setFocused(false), className: `${styles$7.input} ${title != undefined ? styles$7.with_title : styles$7.without_title} ${value.length > 0 ? styles$7.valid : styles$7.not_valid}`, placeholder: placeholder, type: "search", ref: inputElement, onInput: onInputChanged }),
|
567
|
+
React__default["default"].createElement("label", { htmlFor: "text", className: styles$7.label },
|
568
|
+
React__default["default"].createElement("span", { className: styles$7.label_text }, title))),
|
569
569
|
withButton && React__default["default"].createElement("button", { type: "button" }, buttonText),
|
570
|
-
suggestions.length > 0 && React__default["default"].createElement("div", { className: styles$
|
570
|
+
suggestions.length > 0 && React__default["default"].createElement("div", { className: styles$7.suggestions_container },
|
571
571
|
React__default["default"].createElement("ul", null, suggestions.map((suggestion, index) => React__default["default"].createElement("li", { key: index }, suggestion)))),
|
572
|
-
searchResults.length > 0 && React__default["default"].createElement("div", { className: styles$
|
572
|
+
searchResults.length > 0 && React__default["default"].createElement("div", { className: styles$7.results_container },
|
573
573
|
React__default["default"].createElement("ul", null, searchResults.map((result, index) => React__default["default"].createElement("li", { key: index, onClick: (event) => onClickResult(event, result) },
|
574
574
|
React__default["default"].createElement("span", null, result.title),
|
575
575
|
React__default["default"].createElement("button", { type: "button" }, buttonText))))),
|
576
|
-
searchResults.length == 0 && showNoResults && value.length > 0 && React__default["default"].createElement("div", { className: styles$
|
577
|
-
React__default["default"].createElement("div", { className: styles$
|
576
|
+
searchResults.length == 0 && showNoResults && value.length > 0 && React__default["default"].createElement("div", { className: styles$7.results_container },
|
577
|
+
React__default["default"].createElement("div", { className: styles$7.error },
|
578
578
|
React__default["default"].createElement(SvgIcon, { iconName: "error" }),
|
579
579
|
React__default["default"].createElement("h3", null, errorTitle),
|
580
580
|
React__default["default"].createElement("p", null, errorMessage),
|
581
581
|
errorButton.length > 0 && React__default["default"].createElement("button", { type: "button", onClick: errorAction }, errorButton))),
|
582
|
-
searchResults.length == 0 && showNoResults && value.length == 0 && React__default["default"].createElement("div", { className: styles$
|
583
|
-
React__default["default"].createElement("div", { className: styles$
|
582
|
+
searchResults.length == 0 && showNoResults && value.length == 0 && React__default["default"].createElement("div", { className: styles$7.results_container },
|
583
|
+
React__default["default"].createElement("div", { className: styles$7.error },
|
584
584
|
React__default["default"].createElement(SvgIcon, { iconName: "lightbulb" }),
|
585
585
|
React__default["default"].createElement("h3", null, helpTitle),
|
586
586
|
React__default["default"].createElement("p", null, helpMessage))))));
|
587
587
|
}
|
588
588
|
|
589
|
-
var css_248z$
|
590
|
-
var styles$
|
591
|
-
styleInject(css_248z$
|
589
|
+
var css_248z$6 = "";
|
590
|
+
var styles$6 = {};
|
591
|
+
styleInject(css_248z$6);
|
592
592
|
|
593
593
|
class SliderCard {
|
594
594
|
title;
|
@@ -600,44 +600,60 @@ class SliderCard {
|
|
600
600
|
}
|
601
601
|
function Slider({ cards }) {
|
602
602
|
const [selected, setSelected] = React.useState(0);
|
603
|
-
return (React__default["default"].createElement("div", { className: styles$
|
603
|
+
return (React__default["default"].createElement("div", { className: styles$6.container }, cards.map((card, index) => React__default["default"].createElement("div", { key: index, className: [styles$6.card, selected == index ? styles$6.selected : styles$6.not_selected].join(" ") },
|
604
604
|
React__default["default"].createElement("h1", null, card.title),
|
605
605
|
React__default["default"].createElement("p", null, card.description)))));
|
606
606
|
}
|
607
607
|
|
608
|
-
var css_248z$
|
609
|
-
var styles$
|
610
|
-
styleInject(css_248z$
|
608
|
+
var css_248z$5 = ".styles-module_container__xRQNT {\n display: flex;\n flex-direction: row;\n align-items: center;\n gap: 7px;\n color: var(--foreground-3);\n}\n.styles-module_container__xRQNT svg {\n fill: var(--foreground-3);\n}";
|
609
|
+
var styles$5 = {"container":"styles-module_container__xRQNT"};
|
610
|
+
styleInject(css_248z$5);
|
611
611
|
|
612
612
|
function StepBack({ iconName = "arrow_back", text = "Weitere Möglichkeiten" }) {
|
613
613
|
return (React__default["default"].createElement(React__default["default"].Fragment, null,
|
614
|
-
React__default["default"].createElement("div", { className: styles$
|
614
|
+
React__default["default"].createElement("div", { className: styles$5.container },
|
615
615
|
React__default["default"].createElement(SvgIcon, { iconName: iconName }),
|
616
616
|
text)));
|
617
617
|
}
|
618
618
|
|
619
|
+
var css_248z$4 = ".styles-module_card__hT9fw {\n display: flex;\n align-items: center;\n flex-direction: column;\n gap: 20px;\n padding: 100px 0px;\n}\n.styles-module_card__hT9fw h1 {\n margin: 0;\n font-size: 22px;\n font-weight: 500;\n}\n.styles-module_card__hT9fw p {\n margin: 0;\n font-size: 16px;\n}";
|
620
|
+
var styles$4 = {"card":"styles-module_card__hT9fw"};
|
621
|
+
styleInject(css_248z$4);
|
622
|
+
|
623
|
+
function EmptyCard({ title = "Keine Daten", subtitle = "Es sind keine Daten vorhanden.", iconName = "manage_search", button, onClick }) {
|
624
|
+
return (React__default["default"].createElement("div", { className: styles$4.card },
|
625
|
+
React__default["default"].createElement(SvgIcon, { size: "60px", iconName: iconName }),
|
626
|
+
React__default["default"].createElement("h1", null, title),
|
627
|
+
React__default["default"].createElement("p", null, subtitle),
|
628
|
+
button && React__default["default"].createElement(Button, { text: button, onClick: onClick })));
|
629
|
+
}
|
630
|
+
|
619
631
|
var css_248z$3 = ".styles-module_container__jNs7m h3 {\n font-weight: 500;\n font-size: 16px;\n color: var(--foreground-1);\n}\n\n.styles-module_item_list__FxHkg.styles-module_has_children__Uu-8D {\n border-top: 1px solid var(--border-1);\n border-bottom: 1px solid var(--border-1);\n}\n\n.styles-module_item_list__FxHkg {\n list-style: none;\n padding: 0;\n margin: 0;\n}\n.styles-module_item_list__FxHkg .styles-module_action__YYTok {\n display: flex;\n flex-direction: row;\n align-items: center;\n gap: 6px;\n cursor: pointer;\n padding: 8px 14px;\n border-radius: 25px;\n transition: 0.2s ease-in-out;\n}\n.styles-module_item_list__FxHkg .styles-module_action__YYTok.styles-module_default__SexGH:hover {\n background: var(--background-2);\n}\n.styles-module_item_list__FxHkg .styles-module_action__YYTok.styles-module_red__KD3qJ:hover {\n background: var(--red-2);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV.styles-module_selected__iOu39 {\n color: var(--primary-1) !important;\n border-color: var(--primary-1);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV.styles-module_selected__iOu39 .styles-module_icon__Jy87z {\n color: var(--primary-1) !important;\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV {\n padding: 10px 20px;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: center;\n gap: 10px;\n color: var(--foreground-1);\n flex-wrap: wrap;\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV .styles-module_moreText__-blXb {\n flex: 1;\n margin-bottom: 4px;\n color: var(--primary-1);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV .styles-module_subtitle__DT5OF {\n color: var(--foreground-3);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV .styles-module_icon__Jy87z {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n color: var(--foreground-1);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV.styles-module_blue__theVn .styles-module_title__nIwzs {\n color: var(--blue-1) !important;\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV.styles-module_blue__theVn .styles-module_icon__Jy87z {\n color: var(--blue-1) !important;\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV:nth-child(even) {\n background: var(--background-2);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV:nth-child(odd) {\n background: var(--background-1);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV:not(:last-child) {\n border-bottom: 1px solid var(--border-1);\n}";
|
620
632
|
var styles$3 = {"container":"styles-module_container__jNs7m","item_list":"styles-module_item_list__FxHkg","has_children":"styles-module_has_children__Uu-8D","action":"styles-module_action__YYTok","default":"styles-module_default__SexGH","red":"styles-module_red__KD3qJ","item":"styles-module_item__sgyiV","selected":"styles-module_selected__iOu39","icon":"styles-module_icon__Jy87z","moreText":"styles-module_moreText__-blXb","subtitle":"styles-module_subtitle__DT5OF","blue":"styles-module_blue__theVn","title":"styles-module_title__nIwzs"};
|
621
633
|
styleInject(css_248z$3);
|
622
634
|
|
623
|
-
function Table({ items, title = "Titel", actions = [], moreActions, selected, style = "default", marginTop = 30 }) {
|
635
|
+
function Table({ items, title = "Titel", actions = [], moreActions, selected, style = "default", marginTop = 30, emptyTitle = "Keine Daten", emptySubtitle = "Es sind keine Daten vorhanden.", emptyIconName = "manage_search" }) {
|
624
636
|
return (React__default["default"].createElement("div", { className: styles$3.container, style: { marginTop: marginTop } },
|
625
|
-
|
626
|
-
|
627
|
-
|
628
|
-
|
629
|
-
|
630
|
-
|
631
|
-
|
632
|
-
|
633
|
-
|
634
|
-
|
635
|
-
styles$3.
|
636
|
-
|
637
|
-
|
638
|
-
|
639
|
-
|
640
|
-
|
637
|
+
items.length == 0 &&
|
638
|
+
React__default["default"].createElement(EmptyCard, { title: emptyTitle, subtitle: emptySubtitle, iconName: emptyIconName }),
|
639
|
+
items.length > 0 &&
|
640
|
+
React__default["default"].createElement(React__default["default"].Fragment, null,
|
641
|
+
React__default["default"].createElement("h3", null, title),
|
642
|
+
React__default["default"].createElement("ul", { className: `${styles$3.item_list} ${items.length > 0 ? styles$3.has_children : styles$3.no_children}` }, items.map((item, index) => React__default["default"].createElement("li", { key: index, className: [styles$3.item, styles$3[style], selected == index ? styles$3.selected : styles$3.not_selected].join(" ") },
|
643
|
+
React__default["default"].createElement("div", { className: styles$3.icon },
|
644
|
+
React__default["default"].createElement(SvgIcon, { iconName: item.iconName })),
|
645
|
+
React__default["default"].createElement("div", { className: styles$3.title }, item.title),
|
646
|
+
React__default["default"].createElement("div", { className: styles$3.moreText }, item.moreText),
|
647
|
+
React__default["default"].createElement("div", { className: styles$3.subtitle }, item.subtitle),
|
648
|
+
moreActions &&
|
649
|
+
moreActions.map((moreAction, index) => React__default["default"].createElement("div", { className: styles$3.more_action, key: item.title + index }, moreAction(item.data, index))),
|
650
|
+
actions.length > 0 && actions.map((action, idx) => React__default["default"].createElement("div", { key: idx, className: [
|
651
|
+
styles$3.action,
|
652
|
+
action.type === "red" && styles$3.red,
|
653
|
+
action.type === "default" && styles$3.default,
|
654
|
+
].join(" "), onClick: (event) => action.onClick(event, item, index) },
|
655
|
+
React__default["default"].createElement(SvgIcon, { iconName: action.iconName }),
|
656
|
+
action.title))))))));
|
641
657
|
}
|
642
658
|
|
643
659
|
var css_248z$2 = ".styles-module_container__Kl-lB {\n display: flex;\n flex-direction: row;\n gap: 20px;\n margin-bottom: 20px;\n}\n\n.styles-module_tab__Veki- {\n flex: 1;\n border-radius: 42px;\n border-bottom: 2px;\n border-bottom-style: solid;\n border-bottom-color: var(--border-1);\n background: var(--background-1);\n color: var(--foreground-1);\n padding: 16px;\n text-align: center;\n cursor: pointer;\n transition: all 0.2s ease-in-out;\n}\n.styles-module_tab__Veki-.styles-module_selected__geNE7 {\n border-bottom-color: var(--primary-1);\n background: var(--primary-2);\n color: var(--primary-1);\n}\n\n@media (max-width: 750px) {\n .styles-module_container__Kl-lB {\n gap: 0px;\n }\n .styles-module_tab__Veki- {\n border-radius: 0px;\n }\n .styles-module_tab__Veki-:first-child {\n border-top-left-radius: 42px;\n border-bottom-left-radius: 42px;\n }\n .styles-module_tab__Veki-:last-child {\n border-top-right-radius: 42px;\n border-bottom-right-radius: 42px;\n }\n}";
|
@@ -1042,6 +1058,7 @@ exports.S3FileCategory = void 0;
|
|
1042
1058
|
|
1043
1059
|
exports.Accordeon = Accordeon;
|
1044
1060
|
exports.AuthButton = AuthButton;
|
1061
|
+
exports.Button = Button;
|
1045
1062
|
exports.CardButton = CardButton;
|
1046
1063
|
exports.Checkbox = Checkbox;
|
1047
1064
|
exports.ChooseRole = ChooseRole;
|
@@ -1061,7 +1078,6 @@ exports.InputPin = InputPin;
|
|
1061
1078
|
exports.InputText = InputText;
|
1062
1079
|
exports.OptionField = OptionField;
|
1063
1080
|
exports.OptionFieldHorizontal = OptionFieldHorizontal;
|
1064
|
-
exports.PrimaryButton = PrimaryButton;
|
1065
1081
|
exports.ProgressBar = ProgressBar;
|
1066
1082
|
exports.RadioButtons = RadioButtons;
|
1067
1083
|
exports.RadioOption = RadioOption;
|
package/dist/index.d.ts
CHANGED
@@ -1,5 +1,6 @@
|
|
1
1
|
export * from './components/Accordeon';
|
2
2
|
export * from './components/AuthButton';
|
3
|
+
export * from './components/Button';
|
3
4
|
export * from './components/CardButton';
|
4
5
|
export * from './components/Checkbox';
|
5
6
|
export * from './components/ChooseRole';
|
@@ -18,7 +19,6 @@ export * from './components/InputPin';
|
|
18
19
|
export * from './components/InputText';
|
19
20
|
export * from './components/OptionField';
|
20
21
|
export * from './components/OptionFieldHorizontal';
|
21
|
-
export * from './components/PrimaryButton';
|
22
22
|
export * from './components/ProgressBar';
|
23
23
|
export * from './components/RadioButtons';
|
24
24
|
export * from './components/RedirectButton';
|
package/dist/index.esm.js
CHANGED
@@ -32,30 +32,46 @@ function styleInject(css, ref) {
|
|
32
32
|
}
|
33
33
|
}
|
34
34
|
|
35
|
-
var css_248z$
|
36
|
-
var styles$
|
37
|
-
styleInject(css_248z$
|
35
|
+
var css_248z$v = ".styles-module_container__3IVfB {\n margin-bottom: 20px;\n background: var(--background-1);\n border-radius: 30px;\n transition: 0.2s ease-in-out;\n color: var(--foreground-1);\n}\n.styles-module_container__3IVfB .styles-module_head__xFYQb {\n display: flex;\n flex-direction: row;\n align-items: center;\n padding: 16px 20px;\n color: var(--foreground-3);\n background: var(--background-2);\n border-radius: 30px;\n cursor: pointer;\n user-select: none;\n -webkit-user-select: none;\n transition: 0.2s ease-in-out;\n gap: 10px;\n}\n.styles-module_container__3IVfB .styles-module_head__xFYQb span {\n transition: 0.2s ease-in-out;\n}\n.styles-module_container__3IVfB .styles-module_head__xFYQb h3 {\n margin: 0;\n font-weight: 400;\n font-size: 16px;\n user-select: none;\n -webkit-user-select: none;\n}\n.styles-module_container__3IVfB .styles-module_head__xFYQb:hover {\n filter: brightness(0.95);\n}\n.styles-module_container__3IVfB.styles-module_active__soD8R {\n box-shadow: rgba(0, 0, 0, 0.05) 0px 6px 24px 0px, rgba(0, 0, 0, 0.08) 0px 0px 0px 1px;\n}\n.styles-module_container__3IVfB.styles-module_active__soD8R .styles-module_head__xFYQb span {\n rotate: 180deg;\n}\n.styles-module_container__3IVfB .styles-module_content__XAf02 {\n transition: all 0.3s ease-in-out;\n line-height: 1.5;\n}\n.styles-module_container__3IVfB.styles-module_not_active__JcVLz .styles-module_content__XAf02 {\n height: 0;\n max-height: 0;\n overflow: hidden;\n opacity: 0;\n}\n.styles-module_container__3IVfB.styles-module_active__soD8R .styles-module_content__XAf02 {\n max-height: auto;\n overflow: visible;\n opacity: 1;\n padding: 10px 0px;\n}";
|
36
|
+
var styles$v = {"container":"styles-module_container__3IVfB","head":"styles-module_head__xFYQb","active":"styles-module_active__soD8R","content":"styles-module_content__XAf02","not_active":"styles-module_not_active__JcVLz"};
|
37
|
+
styleInject(css_248z$v);
|
38
38
|
|
39
39
|
function Accordeon({ title, children }) {
|
40
40
|
const [isActive, setActive] = useState(false);
|
41
|
-
return (React.createElement("div", { className: [styles$
|
42
|
-
React.createElement("div", { className: styles$
|
41
|
+
return (React.createElement("div", { className: [styles$v.container, isActive ? styles$v.active : styles$v.not_active].join(" ") },
|
42
|
+
React.createElement("div", { className: styles$v.head, onClick: () => setActive(!isActive) },
|
43
43
|
React.createElement(SvgIcon, { iconName: "expand_more" }),
|
44
44
|
React.createElement("h3", null, title)),
|
45
|
-
React.createElement("div", { className: styles$
|
45
|
+
React.createElement("div", { className: styles$v.content }, children)));
|
46
46
|
}
|
47
47
|
|
48
|
-
var css_248z$
|
49
|
-
var styles$
|
50
|
-
styleInject(css_248z$
|
48
|
+
var css_248z$u = ".styles-module_container__4978M {\n max-width: 100%;\n width: 350px;\n transition: all 0.2s ease-in-out;\n box-sizing: border-box;\n}\n.styles-module_container__4978M.styles-module_visible__uvQwq {\n max-height: 100px;\n opacity: 1;\n}\n.styles-module_container__4978M.styles-module_hidden__Oruyx {\n overflow: hidden;\n max-height: 0;\n opacity: 0;\n}\n\n.styles-module_container__4978M.styles-module_rotate__mmYPQ .styles-module_button__BWOOi:hover span {\n rotate: -45deg;\n}\n\n.styles-module_button__BWOOi {\n padding: 12px 20px;\n background: linear-gradient(60deg, #0075FF, #0056b8);\n background-position-x: right;\n color: white;\n display: flex;\n flex-direction: row;\n width: 100%;\n align-items: center;\n justify-content: center;\n border-radius: 14px;\n border: none;\n cursor: pointer;\n font-size: 16px;\n font-weight: 400;\n gap: 10px;\n position: relative;\n transition: all 0.5s ease-in-out;\n}\n.styles-module_button__BWOOi span {\n transition: 0.1s ease-in-out;\n}\n.styles-module_button__BWOOi:hover {\n background-position-x: left;\n}\n.styles-module_button__BWOOi.styles-module_secondary__Eoik3 {\n background: var(--background-2);\n color: var(--primary-1);\n border: 1px solid var(--primary-1);\n}\n.styles-module_button__BWOOi.styles-module_secondary__Eoik3 svg {\n fill: var(--primary-1);\n}\n\n@media (max-width: 450px) {\n .styles-module_button__BWOOi {\n font-size: 14px;\n }\n}";
|
49
|
+
var styles$u = {"container":"styles-module_container__4978M","visible":"styles-module_visible__uvQwq","hidden":"styles-module_hidden__Oruyx","rotate":"styles-module_rotate__mmYPQ","button":"styles-module_button__BWOOi","secondary":"styles-module_secondary__Eoik3"};
|
50
|
+
styleInject(css_248z$u);
|
51
51
|
|
52
52
|
function AuthButton({ text, type = "submit", theme = "primary", iconName = "arrow_forward", isVisible = true, onClick }) {
|
53
|
-
return (React.createElement("div", { className: [styles$
|
54
|
-
React.createElement("button", { type: type, className: `${styles$
|
53
|
+
return (React.createElement("div", { className: [styles$u.container, isVisible ? styles$u.visible : styles$u.hidden, ["arrow_forward"].includes(iconName) ? styles$u.rotate : null].join(" ") },
|
54
|
+
React.createElement("button", { type: type, className: `${styles$u.button} ${styles$u[theme]}`, onClick: onClick },
|
55
55
|
text,
|
56
56
|
React.createElement(SvgIcon, { iconName: iconName }))));
|
57
57
|
}
|
58
58
|
|
59
|
+
var css_248z$t = ".styles-module_container__TP0rp {\n max-width: 100%;\n}\n.styles-module_container__TP0rp .styles-module_button__Sh-fr {\n padding: 10px 18px;\n background: var(--primary-1);\n border-radius: 40px;\n cursor: pointer;\n display: flex;\n flex-direction: row;\n gap: 10px;\n font-size: 15px;\n font-weight: 400;\n color: white;\n align-items: center;\n border: none;\n}\n.styles-module_container__TP0rp .styles-module_button__Sh-fr.styles-module_onlyIcon__bNVnI {\n width: 44px;\n height: 44px;\n padding: 0;\n align-items: center;\n justify-content: center;\n}\n.styles-module_container__TP0rp .styles-module_button__Sh-fr.styles-module_onlyIcon__bNVnI span {\n font-size: 22px !important;\n}\n.styles-module_container__TP0rp .styles-module_button__Sh-fr.styles-module_red__EhImH {\n background: var(--red-1);\n color: white;\n}\n.styles-module_container__TP0rp .styles-module_button__Sh-fr.styles-module_grey__kAVD1 {\n background: var(--background-1);\n color: var(--foreground-2);\n}";
|
60
|
+
var styles$t = {"container":"styles-module_container__TP0rp","button":"styles-module_button__Sh-fr","onlyIcon":"styles-module_onlyIcon__bNVnI","red":"styles-module_red__EhImH","grey":"styles-module_grey__kAVD1"};
|
61
|
+
styleInject(css_248z$t);
|
62
|
+
|
63
|
+
function Button({ text, iconName, iconFill = "white", type = "blue", onClick = () => { } }) {
|
64
|
+
function onClickButton(event) {
|
65
|
+
event.preventDefault();
|
66
|
+
if (onClick)
|
67
|
+
onClick(event);
|
68
|
+
}
|
69
|
+
return (React.createElement("div", { className: styles$t.container },
|
70
|
+
React.createElement("button", { className: [styles$t.button, styles$t[type], (text && !iconName) ? styles$t.onlyText : "", (!text && iconName) ? styles$t.onlyIcon : ""].join(" "), onClick: onClickButton },
|
71
|
+
text,
|
72
|
+
iconName && React.createElement(SvgIcon, { iconName: iconName, fill: iconFill }))));
|
73
|
+
}
|
74
|
+
|
59
75
|
var css_248z$s = ".styles-module_card__bOd85 {\n background: var(--background-2);\n border: 1px solid var(--border-2);\n border-radius: 18px;\n transition: 0.2s ease;\n padding: 18px 14px;\n box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.2509803922);\n cursor: pointer;\n text-align: center;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n gap: 10px;\n padding-top: 30px;\n}\n.styles-module_card__bOd85 span {\n color: var(--foreground-3);\n}\n.styles-module_card__bOd85:hover {\n transform: scale(1.01);\n box-shadow: none;\n background: none;\n}\n.styles-module_card__bOd85 h2 {\n margin-top: 0;\n color: var(--foreground-3);\n font-weight: 400;\n font-size: 18px;\n}";
|
60
76
|
var styles$s = {"card":"styles-module_card__bOd85"};
|
61
77
|
styleInject(css_248z$s);
|
@@ -411,36 +427,20 @@ function OptionFieldHorizontal({ title, iconName, onClick, preselected = false }
|
|
411
427
|
React.createElement("h3", null, title)));
|
412
428
|
}
|
413
429
|
|
414
|
-
var css_248z$b = ".styles-
|
415
|
-
var styles$b = {"container":"styles-
|
430
|
+
var css_248z$b = ".styles-module_container__u4q5n {\n margin-bottom: 50px;\n width: 400px;\n max-width: 100%;\n}\n\n.styles-module_background__jt-ry {\n background: var(--border-2);\n height: 3px;\n position: relative;\n}\n\n.styles-module_progress__Zj-B7 {\n background: var(--foreground-1);\n position: absolute;\n left: 0;\n top: 0;\n height: 3px;\n}";
|
431
|
+
var styles$b = {"container":"styles-module_container__u4q5n","background":"styles-module_background__jt-ry","progress":"styles-module_progress__Zj-B7"};
|
416
432
|
styleInject(css_248z$b);
|
417
433
|
|
418
|
-
function PrimaryButton({ text, iconName, iconFill = "white", type = "blue", onClick = () => { } }) {
|
419
|
-
function onClickButton(event) {
|
420
|
-
event.preventDefault();
|
421
|
-
if (onClick)
|
422
|
-
onClick(event);
|
423
|
-
}
|
424
|
-
return (React.createElement("div", { className: styles$b.container },
|
425
|
-
React.createElement("button", { className: [styles$b.button, styles$b[type], (text && !iconName) ? styles$b.onlyText : "", (!text && iconName) ? styles$b.onlyIcon : ""].join(" "), onClick: onClickButton },
|
426
|
-
text,
|
427
|
-
iconName && React.createElement(SvgIcon, { iconName: iconName, fill: iconFill }))));
|
428
|
-
}
|
429
|
-
|
430
|
-
var css_248z$a = ".styles-module_container__u4q5n {\n margin-bottom: 50px;\n width: 400px;\n max-width: 100%;\n}\n\n.styles-module_background__jt-ry {\n background: var(--border-2);\n height: 3px;\n position: relative;\n}\n\n.styles-module_progress__Zj-B7 {\n background: var(--foreground-1);\n position: absolute;\n left: 0;\n top: 0;\n height: 3px;\n}";
|
431
|
-
var styles$a = {"container":"styles-module_container__u4q5n","background":"styles-module_background__jt-ry","progress":"styles-module_progress__Zj-B7"};
|
432
|
-
styleInject(css_248z$a);
|
433
|
-
|
434
434
|
function ProgressBar({ length, progress }) {
|
435
435
|
return (React.createElement(React.Fragment, null,
|
436
|
-
React.createElement("div", { className: styles$
|
437
|
-
React.createElement("div", { className: styles$
|
438
|
-
React.createElement("div", { className: styles$
|
436
|
+
React.createElement("div", { className: styles$b.container },
|
437
|
+
React.createElement("div", { className: styles$b.background },
|
438
|
+
React.createElement("div", { className: styles$b.progress, style: { width: `${progress / length * 100}%` } })))));
|
439
439
|
}
|
440
440
|
|
441
|
-
var css_248z$
|
442
|
-
var styles$
|
443
|
-
styleInject(css_248z$
|
441
|
+
var css_248z$a = ".styles-module_container__Grkzw {\n display: flex;\n flex-direction: column;\n gap: 12px;\n color: var(--foreground-3);\n margin-bottom: 20px;\n}\n.styles-module_container__Grkzw [type=radio] {\n position: relative;\n left: 15px;\n top: -4px;\n z-index: 0;\n appearance: none;\n -webkit-appearance: none;\n cursor: pointer;\n margin-left: -3.5px;\n}\n.styles-module_container__Grkzw [type=radio] + label {\n position: absolute;\n cursor: pointer;\n}\n.styles-module_container__Grkzw [type=radio] + label::before {\n width: 15px;\n height: 15px;\n border-radius: 20px;\n border: 2px solid var(--border-2);\n display: block;\n content: \"\";\n float: left;\n margin-right: 8px;\n z-index: 5;\n position: relative;\n transition: 0.2s ease-in-out;\n}\n.styles-module_container__Grkzw [type=radio]:checked + label::before {\n background-color: var(--primary-2);\n border-color: var(--primary-1);\n}\n.styles-module_container__Grkzw [type=radio]:hover:not(:checked) + label::before {\n background-color: var(--background-4);\n border-color: var(--background-4);\n}";
|
442
|
+
var styles$a = {"container":"styles-module_container__Grkzw"};
|
443
|
+
styleInject(css_248z$a);
|
444
444
|
|
445
445
|
class RadioOption {
|
446
446
|
text;
|
@@ -457,7 +457,7 @@ function RadioButtons({ options, group, selected, onClick, width = "100%" }) {
|
|
457
457
|
if (onClick)
|
458
458
|
onClick(event);
|
459
459
|
}
|
460
|
-
return (React.createElement("div", { className: styles$
|
460
|
+
return (React.createElement("div", { className: styles$a.container, style: { width: width } }, options.map((option) => React.createElement("div", { className: styles$a.option, key: option.name },
|
461
461
|
selected && selected == option.name ?
|
462
462
|
React.createElement("input", { type: "radio", id: option.name, name: group, value: option.name, onInput: onUpdateSelected, defaultChecked: true })
|
463
463
|
:
|
@@ -465,9 +465,9 @@ function RadioButtons({ options, group, selected, onClick, width = "100%" }) {
|
|
465
465
|
React.createElement("label", { htmlFor: option.name }, option.text)))));
|
466
466
|
}
|
467
467
|
|
468
|
-
var css_248z$
|
469
|
-
var styles$
|
470
|
-
styleInject(css_248z$
|
468
|
+
var css_248z$9 = ".styles-module_container__RhsQe {\n margin-right: 8px;\n}\n.styles-module_container__RhsQe .styles-module_button__HuX-0 {\n background: none;\n padding: none;\n border: none;\n width: 40px;\n height: 40px;\n transition: 0.2s;\n cursor: pointer;\n display: flex;\n justify-content: center;\n align-items: center;\n border-radius: 20px;\n}\n.styles-module_container__RhsQe .styles-module_button__HuX-0 span {\n color: var(--foreground-1);\n}\n.styles-module_container__RhsQe .styles-module_button__HuX-0:hover {\n background: var(--background-1);\n}\n.styles-module_container__RhsQe.styles-module_middle__xg7RF .styles-module_button__HuX-0 {\n flex-direction: row;\n gap: 5px;\n}\n.styles-module_container__RhsQe.styles-module_middle__xg7RF .styles-module_button__HuX-0:hover {\n background: none;\n}";
|
469
|
+
var styles$9 = {"container":"styles-module_container__RhsQe","button":"styles-module_button__HuX-0","middle":"styles-module_middle__xg7RF"};
|
470
|
+
styleInject(css_248z$9);
|
471
471
|
|
472
472
|
function RedirectButton({ type = "forward", onClick }) {
|
473
473
|
function onClickButton(event) {
|
@@ -482,16 +482,16 @@ function RedirectButton({ type = "forward", onClick }) {
|
|
482
482
|
case "middle": return "arrow_back";
|
483
483
|
}
|
484
484
|
};
|
485
|
-
return (React.createElement("div", { className: [styles$
|
486
|
-
React.createElement("button", { onClick: onClickButton, className: styles$
|
485
|
+
return (React.createElement("div", { className: [styles$9.container, styles$9[type]].join(" ") },
|
486
|
+
React.createElement("button", { onClick: onClickButton, className: styles$9.button },
|
487
487
|
React.createElement(SvgIcon, { iconName: getIcon() }),
|
488
488
|
["middle"].includes(type) &&
|
489
489
|
React.createElement("span", null, "Zur\u00FCck"))));
|
490
490
|
}
|
491
491
|
|
492
|
-
var css_248z$
|
493
|
-
var styles$
|
494
|
-
styleInject(css_248z$
|
492
|
+
var css_248z$8 = ".styles-module_container__VreeH {\n margin-bottom: 20px;\n display: flex;\n flex-direction: row;\n flex-wrap: wrap;\n gap: 10px;\n}\n.styles-module_container__VreeH .styles-module_chip__EvZ4J,\n.styles-module_container__VreeH .styles-module_show_all__HKn-s {\n padding: 10px 18px;\n background: var(--background-1);\n border-radius: 20px;\n display: flex;\n flex-direction: row;\n gap: 5px;\n align-items: center;\n cursor: pointer;\n user-select: none;\n -webkit-user-select: none;\n color: var(--foreground-2);\n transition: 0.2s ease-in-out;\n}\n.styles-module_container__VreeH .styles-module_chip__EvZ4J:hover {\n filter: brightness(0.95);\n}\n.styles-module_container__VreeH .styles-module_chip__EvZ4J.styles-module_selected__sArTD {\n background: var(--primary-2);\n color: var(--primary-1);\n}\n.styles-module_container__VreeH .styles-module_chip__EvZ4J.styles-module_selected__sArTD span {\n color: var(--primary-1);\n}";
|
493
|
+
var styles$8 = {"container":"styles-module_container__VreeH","chip":"styles-module_chip__EvZ4J","show_all":"styles-module_show_all__HKn-s","selected":"styles-module_selected__sArTD"};
|
494
|
+
styleInject(css_248z$8);
|
495
495
|
|
496
496
|
class SearchChip {
|
497
497
|
title;
|
@@ -512,19 +512,19 @@ function SearchChips({ items, onChange, chipsVisible = 9 }) {
|
|
512
512
|
if (onChange)
|
513
513
|
onChange(newChips);
|
514
514
|
}
|
515
|
-
return (React.createElement("div", { className: styles$
|
516
|
-
(showAll ? chips : chips.slice(0, chipsVisible)).map((item, index) => React.createElement("div", { key: index, onClick: (e) => onClick(item, index), className: [styles$
|
515
|
+
return (React.createElement("div", { className: styles$8.container },
|
516
|
+
(showAll ? chips : chips.slice(0, chipsVisible)).map((item, index) => React.createElement("div", { key: index, onClick: (e) => onClick(item, index), className: [styles$8.chip, item.selected ? styles$8.selected : styles$8.not_selected].join(" ") },
|
517
517
|
React.createElement(SvgIcon, { iconName: item.selected ? "close" : "filter_list", size: "20px" }),
|
518
518
|
item.title)),
|
519
519
|
chipsVisible < chips.length && (showAll ?
|
520
|
-
React.createElement("div", { className: styles$
|
520
|
+
React.createElement("div", { className: styles$8.show_all, onClick: () => setShowAll(false) }, "Weniger anzeigen")
|
521
521
|
:
|
522
|
-
React.createElement("div", { className: styles$
|
522
|
+
React.createElement("div", { className: styles$8.show_all, onClick: () => setShowAll(true) }, "Mehr anzeigen"))));
|
523
523
|
}
|
524
524
|
|
525
|
-
var css_248z$
|
526
|
-
var styles$
|
527
|
-
styleInject(css_248z$
|
525
|
+
var css_248z$7 = ".styles-module_container__k4Z26 {\n width: 100%;\n display: flex;\n flex-direction: row;\n gap: 10px;\n position: relative;\n}\n.styles-module_container__k4Z26 button {\n background: var(--primary-2);\n padding: 0px 18px;\n border: none;\n font-size: 14px;\n border-radius: 10px;\n cursor: pointer;\n color: var(--primary-1);\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ-,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om {\n display: none;\n position: absolute;\n top: 60px;\n background: var(--background-1);\n box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.2509803922);\n width: 100%;\n border-radius: 14px;\n border: 1px solid var(--border-3);\n z-index: 1000;\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ-:hover,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om:hover {\n display: block;\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ- ul,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om ul {\n list-style: none;\n margin: 0;\n padding: 0;\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ- ul li,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om ul li {\n padding: 16px 20px;\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ- ul li:not(:last-child),\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om ul li:not(:last-child) {\n border-bottom: 1px solid var(--border-3);\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ- .styles-module_error__2Ov4X,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om .styles-module_error__2Ov4X {\n padding: 35px 0px;\n display: flex;\n flex-direction: column;\n align-items: center;\n gap: 15px;\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ- .styles-module_error__2Ov4X p,\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ- .styles-module_error__2Ov4X h3,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om .styles-module_error__2Ov4X p,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om .styles-module_error__2Ov4X h3 {\n margin: 0;\n}\n.styles-module_container__k4Z26 .styles-module_suggestions_container__pceQ- .styles-module_error__2Ov4X p,\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om .styles-module_error__2Ov4X p {\n color: var(--foreground-3);\n padding: 0px 30px;\n line-height: 1.5;\n text-align: center;\n margin-bottom: 10px;\n}\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om ul li {\n display: flex;\n flex-direction: row;\n padding: 10px 20px;\n align-items: center;\n}\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om ul li span {\n flex: 1;\n}\n.styles-module_container__k4Z26 .styles-module_results_container__OY4Om button {\n padding: 10px 16px;\n}\n\n.styles-module_input__wOJmG {\n padding: 14px 20px;\n font-size: 16px;\n width: 300px;\n border-radius: 12px;\n border: 1.5px solid var(--border-2);\n outline: none;\n transition: 0.2s ease;\n width: 100%;\n background: var(--background-1);\n color: var(--foreground-1);\n}\n.styles-module_input__wOJmG:focus, .styles-module_input__wOJmG:active {\n border-color: var(--primary-1);\n box-shadow: 0px 0px 3px 3px rgba(0, 87, 255, 0.2509803922);\n}\n\n.styles-module_form__mWTCu.styles-module_focus__-6H1f + .styles-module_suggestions_container__pceQ-,\n.styles-module_form__mWTCu.styles-module_focus__-6H1f + .styles-module_results_container__OY4Om {\n display: block;\n}\n\n/* animated text field */\n.styles-module_form__mWTCu {\n position: relative;\n width: 100%;\n}\n\n.styles-module_label__A41g9 {\n position: absolute;\n bottom: 0px;\n left: 0px;\n width: 100%;\n height: 100%;\n pointer-events: none;\n}\n\n.styles-module_label_text__NQHTC {\n position: absolute;\n bottom: 16px;\n left: 12px;\n transition: 0.3s ease;\n font-size: 16px;\n border-top-left-radius: 5px;\n border-top-right-radius: 5px;\n opacity: initial;\n background: var(--background-1);\n color: var(--foreground-3);\n padding-right: 8px;\n padding-left: 8px;\n}\n\n.styles-module_input__wOJmG.styles-module_with_title__rnN-t::placeholder {\n opacity: 0;\n transition: opacity 0.3s ease;\n color: var(--foreground-3);\n}\n\n.styles-module_input__wOJmG.styles-module_with_title__rnN-t:focus::placeholder {\n opacity: 1;\n}\n\n.styles-module_input__wOJmG:focus + .styles-module_label__A41g9 .styles-module_label_text__NQHTC,\n.styles-module_input__wOJmG.styles-module_valid__AAK-6 + .styles-module_label__A41g9 .styles-module_label_text__NQHTC {\n transform: translateY(-150%);\n left: 15px;\n font-size: 14px;\n background: var(--background-2);\n color: var(--primary-1);\n}\n\n.styles-module_input__wOJmG.styles-module_valid__AAK-6 + .styles-module_label__A41g9 .styles-module_label_text__NQHTC {\n color: var(--foreground-3);\n}";
|
526
|
+
var styles$7 = {"container":"styles-module_container__k4Z26","suggestions_container":"styles-module_suggestions_container__pceQ-","results_container":"styles-module_results_container__OY4Om","error":"styles-module_error__2Ov4X","input":"styles-module_input__wOJmG","form":"styles-module_form__mWTCu","focus":"styles-module_focus__-6H1f","label":"styles-module_label__A41g9","label_text":"styles-module_label_text__NQHTC","with_title":"styles-module_with_title__rnN-t","valid":"styles-module_valid__AAK-6"};
|
527
|
+
styleInject(css_248z$7);
|
528
528
|
|
529
529
|
function Searchbar({ placeholder, title = "Suchen", showNoResults = false, errorTitle = "Keine Ergebnisse gefunden", errorMessage = "", errorButton = "", helpTitle = "", helpMessage = "", marginBottom = 25, marginTop = 30, errorAction = () => { }, onInput = () => { }, onClickResult = () => { }, withButton = false, buttonText = "Suchen", suggestions = [], autoFocus = false, results = [] }) {
|
530
530
|
const [value, setValue] = useState("");
|
@@ -553,34 +553,34 @@ function Searchbar({ placeholder, title = "Suchen", showNoResults = false, error
|
|
553
553
|
element.focus();
|
554
554
|
}, [autoFocus]);
|
555
555
|
return (React.createElement(React.Fragment, null,
|
556
|
-
React.createElement("div", { className: styles$
|
557
|
-
React.createElement("div", { className: `${styles$
|
558
|
-
React.createElement("input", { onFocus: () => setFocused(true), onBlur: () => setFocused(false), className: `${styles$
|
559
|
-
React.createElement("label", { htmlFor: "text", className: styles$
|
560
|
-
React.createElement("span", { className: styles$
|
556
|
+
React.createElement("div", { className: styles$7.container, style: { marginTop: marginTop, marginBottom: marginBottom } },
|
557
|
+
React.createElement("div", { className: `${styles$7.form} ${inputFocused ? styles$7.focus : styles$7.not_focused}` },
|
558
|
+
React.createElement("input", { onFocus: () => setFocused(true), onBlur: () => setFocused(false), className: `${styles$7.input} ${title != undefined ? styles$7.with_title : styles$7.without_title} ${value.length > 0 ? styles$7.valid : styles$7.not_valid}`, placeholder: placeholder, type: "search", ref: inputElement, onInput: onInputChanged }),
|
559
|
+
React.createElement("label", { htmlFor: "text", className: styles$7.label },
|
560
|
+
React.createElement("span", { className: styles$7.label_text }, title))),
|
561
561
|
withButton && React.createElement("button", { type: "button" }, buttonText),
|
562
|
-
suggestions.length > 0 && React.createElement("div", { className: styles$
|
562
|
+
suggestions.length > 0 && React.createElement("div", { className: styles$7.suggestions_container },
|
563
563
|
React.createElement("ul", null, suggestions.map((suggestion, index) => React.createElement("li", { key: index }, suggestion)))),
|
564
|
-
searchResults.length > 0 && React.createElement("div", { className: styles$
|
564
|
+
searchResults.length > 0 && React.createElement("div", { className: styles$7.results_container },
|
565
565
|
React.createElement("ul", null, searchResults.map((result, index) => React.createElement("li", { key: index, onClick: (event) => onClickResult(event, result) },
|
566
566
|
React.createElement("span", null, result.title),
|
567
567
|
React.createElement("button", { type: "button" }, buttonText))))),
|
568
|
-
searchResults.length == 0 && showNoResults && value.length > 0 && React.createElement("div", { className: styles$
|
569
|
-
React.createElement("div", { className: styles$
|
568
|
+
searchResults.length == 0 && showNoResults && value.length > 0 && React.createElement("div", { className: styles$7.results_container },
|
569
|
+
React.createElement("div", { className: styles$7.error },
|
570
570
|
React.createElement(SvgIcon, { iconName: "error" }),
|
571
571
|
React.createElement("h3", null, errorTitle),
|
572
572
|
React.createElement("p", null, errorMessage),
|
573
573
|
errorButton.length > 0 && React.createElement("button", { type: "button", onClick: errorAction }, errorButton))),
|
574
|
-
searchResults.length == 0 && showNoResults && value.length == 0 && React.createElement("div", { className: styles$
|
575
|
-
React.createElement("div", { className: styles$
|
574
|
+
searchResults.length == 0 && showNoResults && value.length == 0 && React.createElement("div", { className: styles$7.results_container },
|
575
|
+
React.createElement("div", { className: styles$7.error },
|
576
576
|
React.createElement(SvgIcon, { iconName: "lightbulb" }),
|
577
577
|
React.createElement("h3", null, helpTitle),
|
578
578
|
React.createElement("p", null, helpMessage))))));
|
579
579
|
}
|
580
580
|
|
581
|
-
var css_248z$
|
582
|
-
var styles$
|
583
|
-
styleInject(css_248z$
|
581
|
+
var css_248z$6 = "";
|
582
|
+
var styles$6 = {};
|
583
|
+
styleInject(css_248z$6);
|
584
584
|
|
585
585
|
class SliderCard {
|
586
586
|
title;
|
@@ -592,44 +592,60 @@ class SliderCard {
|
|
592
592
|
}
|
593
593
|
function Slider({ cards }) {
|
594
594
|
const [selected, setSelected] = useState(0);
|
595
|
-
return (React.createElement("div", { className: styles$
|
595
|
+
return (React.createElement("div", { className: styles$6.container }, cards.map((card, index) => React.createElement("div", { key: index, className: [styles$6.card, selected == index ? styles$6.selected : styles$6.not_selected].join(" ") },
|
596
596
|
React.createElement("h1", null, card.title),
|
597
597
|
React.createElement("p", null, card.description)))));
|
598
598
|
}
|
599
599
|
|
600
|
-
var css_248z$
|
601
|
-
var styles$
|
602
|
-
styleInject(css_248z$
|
600
|
+
var css_248z$5 = ".styles-module_container__xRQNT {\n display: flex;\n flex-direction: row;\n align-items: center;\n gap: 7px;\n color: var(--foreground-3);\n}\n.styles-module_container__xRQNT svg {\n fill: var(--foreground-3);\n}";
|
601
|
+
var styles$5 = {"container":"styles-module_container__xRQNT"};
|
602
|
+
styleInject(css_248z$5);
|
603
603
|
|
604
604
|
function StepBack({ iconName = "arrow_back", text = "Weitere Möglichkeiten" }) {
|
605
605
|
return (React.createElement(React.Fragment, null,
|
606
|
-
React.createElement("div", { className: styles$
|
606
|
+
React.createElement("div", { className: styles$5.container },
|
607
607
|
React.createElement(SvgIcon, { iconName: iconName }),
|
608
608
|
text)));
|
609
609
|
}
|
610
610
|
|
611
|
+
var css_248z$4 = ".styles-module_card__hT9fw {\n display: flex;\n align-items: center;\n flex-direction: column;\n gap: 20px;\n padding: 100px 0px;\n}\n.styles-module_card__hT9fw h1 {\n margin: 0;\n font-size: 22px;\n font-weight: 500;\n}\n.styles-module_card__hT9fw p {\n margin: 0;\n font-size: 16px;\n}";
|
612
|
+
var styles$4 = {"card":"styles-module_card__hT9fw"};
|
613
|
+
styleInject(css_248z$4);
|
614
|
+
|
615
|
+
function EmptyCard({ title = "Keine Daten", subtitle = "Es sind keine Daten vorhanden.", iconName = "manage_search", button, onClick }) {
|
616
|
+
return (React.createElement("div", { className: styles$4.card },
|
617
|
+
React.createElement(SvgIcon, { size: "60px", iconName: iconName }),
|
618
|
+
React.createElement("h1", null, title),
|
619
|
+
React.createElement("p", null, subtitle),
|
620
|
+
button && React.createElement(Button, { text: button, onClick: onClick })));
|
621
|
+
}
|
622
|
+
|
611
623
|
var css_248z$3 = ".styles-module_container__jNs7m h3 {\n font-weight: 500;\n font-size: 16px;\n color: var(--foreground-1);\n}\n\n.styles-module_item_list__FxHkg.styles-module_has_children__Uu-8D {\n border-top: 1px solid var(--border-1);\n border-bottom: 1px solid var(--border-1);\n}\n\n.styles-module_item_list__FxHkg {\n list-style: none;\n padding: 0;\n margin: 0;\n}\n.styles-module_item_list__FxHkg .styles-module_action__YYTok {\n display: flex;\n flex-direction: row;\n align-items: center;\n gap: 6px;\n cursor: pointer;\n padding: 8px 14px;\n border-radius: 25px;\n transition: 0.2s ease-in-out;\n}\n.styles-module_item_list__FxHkg .styles-module_action__YYTok.styles-module_default__SexGH:hover {\n background: var(--background-2);\n}\n.styles-module_item_list__FxHkg .styles-module_action__YYTok.styles-module_red__KD3qJ:hover {\n background: var(--red-2);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV.styles-module_selected__iOu39 {\n color: var(--primary-1) !important;\n border-color: var(--primary-1);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV.styles-module_selected__iOu39 .styles-module_icon__Jy87z {\n color: var(--primary-1) !important;\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV {\n padding: 10px 20px;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: center;\n gap: 10px;\n color: var(--foreground-1);\n flex-wrap: wrap;\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV .styles-module_moreText__-blXb {\n flex: 1;\n margin-bottom: 4px;\n color: var(--primary-1);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV .styles-module_subtitle__DT5OF {\n color: var(--foreground-3);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV .styles-module_icon__Jy87z {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n color: var(--foreground-1);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV.styles-module_blue__theVn .styles-module_title__nIwzs {\n color: var(--blue-1) !important;\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV.styles-module_blue__theVn .styles-module_icon__Jy87z {\n color: var(--blue-1) !important;\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV:nth-child(even) {\n background: var(--background-2);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV:nth-child(odd) {\n background: var(--background-1);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV:not(:last-child) {\n border-bottom: 1px solid var(--border-1);\n}";
|
612
624
|
var styles$3 = {"container":"styles-module_container__jNs7m","item_list":"styles-module_item_list__FxHkg","has_children":"styles-module_has_children__Uu-8D","action":"styles-module_action__YYTok","default":"styles-module_default__SexGH","red":"styles-module_red__KD3qJ","item":"styles-module_item__sgyiV","selected":"styles-module_selected__iOu39","icon":"styles-module_icon__Jy87z","moreText":"styles-module_moreText__-blXb","subtitle":"styles-module_subtitle__DT5OF","blue":"styles-module_blue__theVn","title":"styles-module_title__nIwzs"};
|
613
625
|
styleInject(css_248z$3);
|
614
626
|
|
615
|
-
function Table({ items, title = "Titel", actions = [], moreActions, selected, style = "default", marginTop = 30 }) {
|
627
|
+
function Table({ items, title = "Titel", actions = [], moreActions, selected, style = "default", marginTop = 30, emptyTitle = "Keine Daten", emptySubtitle = "Es sind keine Daten vorhanden.", emptyIconName = "manage_search" }) {
|
616
628
|
return (React.createElement("div", { className: styles$3.container, style: { marginTop: marginTop } },
|
617
|
-
|
618
|
-
|
619
|
-
|
620
|
-
|
621
|
-
|
622
|
-
|
623
|
-
|
624
|
-
|
625
|
-
|
626
|
-
|
627
|
-
styles$3.
|
628
|
-
|
629
|
-
|
630
|
-
|
631
|
-
|
632
|
-
|
629
|
+
items.length == 0 &&
|
630
|
+
React.createElement(EmptyCard, { title: emptyTitle, subtitle: emptySubtitle, iconName: emptyIconName }),
|
631
|
+
items.length > 0 &&
|
632
|
+
React.createElement(React.Fragment, null,
|
633
|
+
React.createElement("h3", null, title),
|
634
|
+
React.createElement("ul", { className: `${styles$3.item_list} ${items.length > 0 ? styles$3.has_children : styles$3.no_children}` }, items.map((item, index) => React.createElement("li", { key: index, className: [styles$3.item, styles$3[style], selected == index ? styles$3.selected : styles$3.not_selected].join(" ") },
|
635
|
+
React.createElement("div", { className: styles$3.icon },
|
636
|
+
React.createElement(SvgIcon, { iconName: item.iconName })),
|
637
|
+
React.createElement("div", { className: styles$3.title }, item.title),
|
638
|
+
React.createElement("div", { className: styles$3.moreText }, item.moreText),
|
639
|
+
React.createElement("div", { className: styles$3.subtitle }, item.subtitle),
|
640
|
+
moreActions &&
|
641
|
+
moreActions.map((moreAction, index) => React.createElement("div", { className: styles$3.more_action, key: item.title + index }, moreAction(item.data, index))),
|
642
|
+
actions.length > 0 && actions.map((action, idx) => React.createElement("div", { key: idx, className: [
|
643
|
+
styles$3.action,
|
644
|
+
action.type === "red" && styles$3.red,
|
645
|
+
action.type === "default" && styles$3.default,
|
646
|
+
].join(" "), onClick: (event) => action.onClick(event, item, index) },
|
647
|
+
React.createElement(SvgIcon, { iconName: action.iconName }),
|
648
|
+
action.title))))))));
|
633
649
|
}
|
634
650
|
|
635
651
|
var css_248z$2 = ".styles-module_container__Kl-lB {\n display: flex;\n flex-direction: row;\n gap: 20px;\n margin-bottom: 20px;\n}\n\n.styles-module_tab__Veki- {\n flex: 1;\n border-radius: 42px;\n border-bottom: 2px;\n border-bottom-style: solid;\n border-bottom-color: var(--border-1);\n background: var(--background-1);\n color: var(--foreground-1);\n padding: 16px;\n text-align: center;\n cursor: pointer;\n transition: all 0.2s ease-in-out;\n}\n.styles-module_tab__Veki-.styles-module_selected__geNE7 {\n border-bottom-color: var(--primary-1);\n background: var(--primary-2);\n color: var(--primary-1);\n}\n\n@media (max-width: 750px) {\n .styles-module_container__Kl-lB {\n gap: 0px;\n }\n .styles-module_tab__Veki- {\n border-radius: 0px;\n }\n .styles-module_tab__Veki-:first-child {\n border-top-left-radius: 42px;\n border-bottom-left-radius: 42px;\n }\n .styles-module_tab__Veki-:last-child {\n border-top-right-radius: 42px;\n border-bottom-right-radius: 42px;\n }\n}";
|
@@ -1032,4 +1048,4 @@ var S3FileCategory;
|
|
1032
1048
|
S3FileCategory["default"] = "file";
|
1033
1049
|
})(S3FileCategory || (S3FileCategory = {}));
|
1034
1050
|
|
1035
|
-
export { Accordeon, AuthButton, CardButton, Checkbox, ChooseRole, ChooseRoleItem, CopyCode, CourseAnnouncementAssetType, Dialog, FormButton, FormText, ForwardButton, Gap, InputArea, InputMail, InputNames, InputNumber, InputPassword, InputPin, InputText, OptionField, OptionFieldHorizontal,
|
1051
|
+
export { Accordeon, AuthButton, Button, CardButton, Checkbox, ChooseRole, ChooseRoleItem, CopyCode, CourseAnnouncementAssetType, Dialog, FormButton, FormText, ForwardButton, Gap, InputArea, InputMail, InputNames, InputNumber, InputPassword, InputPin, InputText, OptionField, OptionFieldHorizontal, ProgressBar, RadioButtons, RadioOption, RedirectButton, S3FileCategory, SearchChip, SearchChips, Searchbar, Slider, SliderCard, StepBack, SvgIcon, Table, Tabs, TextWithIcon, UsageCard };
|
package/dist/types/Feedback.d.ts
CHANGED
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "math-main-components",
|
3
|
-
"version": "0.0.
|
3
|
+
"version": "0.0.135",
|
4
4
|
"author": "Emilian Scheel",
|
5
5
|
"files": [
|
6
6
|
"dist/**/*"
|
@@ -41,6 +41,7 @@
|
|
41
41
|
"react-dom": "^18.2.0"
|
42
42
|
},
|
43
43
|
"scripts": {
|
44
|
+
"dev": "nodemon --watch src --exec \"npm run build && yalc push\" --ext ts,tsx,scss,js,jsx",
|
44
45
|
"clean": "rm -rf dist",
|
45
46
|
"increment-version": "npm --no-git-tag-version version patch",
|
46
47
|
"git-add-all": "git add .",
|
@@ -50,6 +51,7 @@
|
|
50
51
|
},
|
51
52
|
"dependencies": {
|
52
53
|
"@sanity/types": "^3.20.1",
|
54
|
+
"nodemon": "^3.0.2",
|
53
55
|
"pre-commit": "^1.2.2",
|
54
56
|
"sanity": "^3.20.1",
|
55
57
|
"stripe": "^14.5.0"
|