math-main-components 0.0.95 → 0.0.98

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.
@@ -18,9 +18,10 @@ export declare class TableItemAction<DataType> {
18
18
  type: TableActionType;
19
19
  constructor(title: string, iconName: string, type: TableActionType, onClick?: (event: MouseEvent<HTMLDivElement>, item: TableItem<DataType>, index: number) => void);
20
20
  }
21
- export declare function Table<DataType>({ items, title, actions, moreActions }: {
21
+ export declare function Table<DataType>({ items, title, actions, moreActions, marginTop }: {
22
22
  items: TableItem<DataType>[];
23
23
  title: string;
24
24
  actions?: TableItemAction<DataType>[];
25
25
  moreActions?: ((data: DataType, index: number) => ReactNode)[];
26
+ marginTop?: number;
26
27
  }): React.JSX.Element;
package/dist/index.cjs.js CHANGED
@@ -404,7 +404,7 @@ function OptionField({ headline, description, iconName }) {
404
404
  React__default["default"].createElement("p", null, description)))));
405
405
  }
406
406
 
407
- var css_248z$c = ".styles-module_container__XCtqW {\n background: var(--background-1);\n border-radius: 12px;\n padding: 30px;\n margin-bottom: 30px;\n flex: 1;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n gap: 18px;\n color: var(--foreground-1);\n border: 1px solid var(--border-2);\n transition: 0.2s ease-in-out;\n box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25);\n cursor: pointer;\n}\n.styles-module_container__XCtqW:hover {\n background: var(--background-2);\n border-color: var(--border-3);\n}\n.styles-module_container__XCtqW h3 {\n font-weight: 500;\n margin: 0;\n}\n\n.styles-module_container__XCtqW.styles-module_preselected__WoSbB {\n border: 1px solid var(--foreground-1);\n}";
407
+ var css_248z$c = ".styles-module_container__XCtqW {\n background: var(--background-1);\n border-radius: 12px;\n padding: 30px;\n margin-bottom: 30px;\n flex: 1;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n gap: 18px;\n color: var(--foreground-1);\n border: 1px solid var(--border-2);\n transition: 0.2s ease-in-out;\n box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25);\n cursor: pointer;\n}\n.styles-module_container__XCtqW:hover {\n background: var(--background-2);\n border-color: var(--border-3);\n}\n.styles-module_container__XCtqW h3 {\n font-weight: 500;\n margin: 0;\n text-align: center;\n}\n\n.styles-module_container__XCtqW.styles-module_preselected__WoSbB {\n border: 1px solid var(--foreground-1);\n}";
408
408
  var styles$c = {"container":"styles-module_container__XCtqW","preselected":"styles-module_preselected__WoSbB"};
409
409
  styleInject(css_248z$c);
410
410
 
@@ -616,7 +616,7 @@ function StepBack({ iconName = "arrow_back", text = "Weitere Möglichkeiten" })
616
616
  text)));
617
617
  }
618
618
 
619
- var css_248z$3 = ".styles-module_container__jNs7m {\n margin-top: 30px;\n}\n.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 {\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}\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:nth-child(even) {\n background: var(--background-2);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV:not(:last-child) {\n border-bottom: 1px solid var(--border-1);\n}";
619
+ 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 {\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}\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:nth-child(even) {\n background: var(--background-2);\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
620
  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","moreText":"styles-module_moreText__-blXb","subtitle":"styles-module_subtitle__DT5OF","icon":"styles-module_icon__Jy87z"};
621
621
  styleInject(css_248z$3);
622
622
 
@@ -651,8 +651,8 @@ class TableItemAction {
651
651
  this.type = type;
652
652
  }
653
653
  }
654
- function Table({ items, title = "Titel", actions = [], moreActions }) {
655
- return (React__default["default"].createElement("div", { className: styles$3.container },
654
+ function Table({ items, title = "Titel", actions = [], moreActions, marginTop = 30 }) {
655
+ return (React__default["default"].createElement("div", { className: styles$3.container, style: { marginTop: marginTop } },
656
656
  React__default["default"].createElement("h3", null, title),
657
657
  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 },
658
658
  React__default["default"].createElement("div", { className: styles$3.icon },
package/dist/index.esm.js CHANGED
@@ -396,7 +396,7 @@ function OptionField({ headline, description, iconName }) {
396
396
  React.createElement("p", null, description)))));
397
397
  }
398
398
 
399
- var css_248z$c = ".styles-module_container__XCtqW {\n background: var(--background-1);\n border-radius: 12px;\n padding: 30px;\n margin-bottom: 30px;\n flex: 1;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n gap: 18px;\n color: var(--foreground-1);\n border: 1px solid var(--border-2);\n transition: 0.2s ease-in-out;\n box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25);\n cursor: pointer;\n}\n.styles-module_container__XCtqW:hover {\n background: var(--background-2);\n border-color: var(--border-3);\n}\n.styles-module_container__XCtqW h3 {\n font-weight: 500;\n margin: 0;\n}\n\n.styles-module_container__XCtqW.styles-module_preselected__WoSbB {\n border: 1px solid var(--foreground-1);\n}";
399
+ var css_248z$c = ".styles-module_container__XCtqW {\n background: var(--background-1);\n border-radius: 12px;\n padding: 30px;\n margin-bottom: 30px;\n flex: 1;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n gap: 18px;\n color: var(--foreground-1);\n border: 1px solid var(--border-2);\n transition: 0.2s ease-in-out;\n box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25);\n cursor: pointer;\n}\n.styles-module_container__XCtqW:hover {\n background: var(--background-2);\n border-color: var(--border-3);\n}\n.styles-module_container__XCtqW h3 {\n font-weight: 500;\n margin: 0;\n text-align: center;\n}\n\n.styles-module_container__XCtqW.styles-module_preselected__WoSbB {\n border: 1px solid var(--foreground-1);\n}";
400
400
  var styles$c = {"container":"styles-module_container__XCtqW","preselected":"styles-module_preselected__WoSbB"};
401
401
  styleInject(css_248z$c);
402
402
 
@@ -608,7 +608,7 @@ function StepBack({ iconName = "arrow_back", text = "Weitere Möglichkeiten" })
608
608
  text)));
609
609
  }
610
610
 
611
- var css_248z$3 = ".styles-module_container__jNs7m {\n margin-top: 30px;\n}\n.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 {\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}\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:nth-child(even) {\n background: var(--background-2);\n}\n.styles-module_item_list__FxHkg li.styles-module_item__sgyiV:not(:last-child) {\n border-bottom: 1px solid var(--border-1);\n}";
611
+ 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 {\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}\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:nth-child(even) {\n background: var(--background-2);\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
612
  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","moreText":"styles-module_moreText__-blXb","subtitle":"styles-module_subtitle__DT5OF","icon":"styles-module_icon__Jy87z"};
613
613
  styleInject(css_248z$3);
614
614
 
@@ -643,8 +643,8 @@ class TableItemAction {
643
643
  this.type = type;
644
644
  }
645
645
  }
646
- function Table({ items, title = "Titel", actions = [], moreActions }) {
647
- return (React.createElement("div", { className: styles$3.container },
646
+ function Table({ items, title = "Titel", actions = [], moreActions, marginTop = 30 }) {
647
+ return (React.createElement("div", { className: styles$3.container, style: { marginTop: marginTop } },
648
648
  React.createElement("h3", null, title),
649
649
  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 },
650
650
  React.createElement("div", { className: styles$3.icon },
@@ -1,5 +1,6 @@
1
1
  import { PortableTextBlock } from "sanity";
2
2
  import { Category } from "./Category";
3
+ import { Product } from "./Product";
3
4
  export interface Ebook {
4
5
  _id: string;
5
6
  title: string;
@@ -17,4 +18,5 @@ export interface Ebook {
17
18
  description: PortableTextBlock[];
18
19
  shortDescription: string;
19
20
  categories: Category[];
21
+ product?: Product;
20
22
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "math-main-components",
3
- "version": "0.0.95",
3
+ "version": "0.0.98",
4
4
  "author": "Emilian Scheel",
5
5
  "files": [
6
6
  "dist/**/*"