@foodpilot/foods 0.1.2

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.
Files changed (90) hide show
  1. package/README.md +30 -0
  2. package/dist/atoms/gammeAtom.d.ts +12 -0
  3. package/dist/atoms/index.d.ts +5 -0
  4. package/dist/atoms/ingredientsAtom.d.ts +7 -0
  5. package/dist/atoms/productGridAtom.d.ts +13 -0
  6. package/dist/atoms/questionnaireAtom.d.ts +4 -0
  7. package/dist/components/Accordion/AccordionProduct.d.ts +27 -0
  8. package/dist/components/Accordion/GenericAccordion.d.ts +8 -0
  9. package/dist/components/Accordion/index.d.ts +2 -0
  10. package/dist/components/BaseTemplate/BaseTemplate.d.ts +4 -0
  11. package/dist/components/BaseTemplate/Footer.d.ts +1 -0
  12. package/dist/components/BaseTemplate/Navbar.d.ts +11 -0
  13. package/dist/components/BaseTemplate/index.d.ts +4 -0
  14. package/dist/components/Box/CategoryBox.d.ts +4 -0
  15. package/dist/components/Box/DottedBox.d.ts +5 -0
  16. package/dist/components/Box/InfoBox.d.ts +5 -0
  17. package/dist/components/Box/LineGroupBox.d.ts +9 -0
  18. package/dist/components/Box/QuoteBox.d.ts +5 -0
  19. package/dist/components/Box/SolidGreyBox.d.ts +5 -0
  20. package/dist/components/Box/WarningBox.d.ts +5 -0
  21. package/dist/components/Box/index.d.ts +7 -0
  22. package/dist/components/Button/Button.d.ts +6 -0
  23. package/dist/components/Button/TertiaryToggleButton.d.ts +9 -0
  24. package/dist/components/Button/index.d.ts +3 -0
  25. package/dist/components/CardImage.d.ts +5 -0
  26. package/dist/components/Checkbox/PrimaryCheckbox.d.ts +13 -0
  27. package/dist/components/Checkbox/index.d.ts +1 -0
  28. package/dist/components/Dialog/ConsumptionModal.d.ts +11 -0
  29. package/dist/components/Dialog/MaterialModal.d.ts +11 -0
  30. package/dist/components/Dialog/PackagingModal.d.ts +11 -0
  31. package/dist/components/Dialog/PrimaryDialog.d.ts +16 -0
  32. package/dist/components/Dialog/TransformationModal.d.ts +11 -0
  33. package/dist/components/Dialog/index.d.ts +5 -0
  34. package/dist/components/Fields/CategoryField.d.ts +9 -0
  35. package/dist/components/Fields/GammeField.d.ts +9 -0
  36. package/dist/components/Fields/NumberField.d.ts +9 -0
  37. package/dist/components/Fields/TextField.d.ts +9 -0
  38. package/dist/components/Fields/index.d.ts +4 -0
  39. package/dist/components/Form/FormBase.d.ts +19 -0
  40. package/dist/components/Form/index.d.ts +2 -0
  41. package/dist/components/Grid/MRTGrid.d.ts +4 -0
  42. package/dist/components/Grid/MaterialGrid.d.ts +6 -0
  43. package/dist/components/Grid/index.d.ts +2 -0
  44. package/dist/components/Inputs/RoundInput.d.ts +3 -0
  45. package/dist/components/Inputs/RoundNumberInput.d.ts +5 -0
  46. package/dist/components/Inputs/SearchBox.d.ts +7 -0
  47. package/dist/components/Inputs/index.d.ts +3 -0
  48. package/dist/components/LinearProgress.d.ts +9 -0
  49. package/dist/components/Navigation/FormTopBar.d.ts +11 -0
  50. package/dist/components/Navigation/IconThread.d.ts +10 -0
  51. package/dist/components/Navigation/index.d.ts +2 -0
  52. package/dist/components/Popover/AddProductPopover.d.ts +1 -0
  53. package/dist/components/Popover/AnchoredPopover.d.ts +16 -0
  54. package/dist/components/Popover/BigPopoverLayout.d.ts +12 -0
  55. package/dist/components/Popover/CommonSelectProductLine.d.ts +13 -0
  56. package/dist/components/Popover/WhitePopoverOnIcon.d.ts +8 -0
  57. package/dist/components/Popover/index.d.ts +6 -0
  58. package/dist/components/ProductGrid/Cells/ArrayCell.d.ts +3 -0
  59. package/dist/components/ProductGrid/Cells/EcoScoreCell.d.ts +6 -0
  60. package/dist/components/ProductGrid/Cells/GreyCell.d.ts +3 -0
  61. package/dist/components/ProductGrid/Cells/LinkCell.d.ts +4 -0
  62. package/dist/components/ProductGrid/Cells/PointsCell.d.ts +4 -0
  63. package/dist/components/ProductGrid/Cells/index.d.ts +6 -0
  64. package/dist/components/ProductGrid/Layout/ProductPageHeader.d.ts +1 -0
  65. package/dist/components/ProductGrid/Layout/TableHeader.d.ts +1 -0
  66. package/dist/components/ProductGrid/Layout/index.d.ts +3 -0
  67. package/dist/components/ProductGrid/Popovers/ColumnPositionPopover.d.ts +4 -0
  68. package/dist/components/ProductGrid/Popovers/DraggableColumn.d.ts +8 -0
  69. package/dist/components/ProductGrid/Popovers/FilterPopover.d.ts +4 -0
  70. package/dist/components/ProductGrid/Popovers/ProductCreationMenu.d.ts +1 -0
  71. package/dist/components/ProductGrid/Popovers/RowMenu.d.ts +1 -0
  72. package/dist/components/ProductGrid/Popovers/index.d.ts +6 -0
  73. package/dist/components/ProductGrid/ProductGrid.d.ts +11 -0
  74. package/dist/components/ProductGrid/index.d.ts +5 -0
  75. package/dist/components/SsqCard.d.ts +22 -0
  76. package/dist/components/Texts/TextArrowList.d.ts +4 -0
  77. package/dist/components/Texts/TextTitle.d.ts +8 -0
  78. package/dist/components/Texts/TextTitleGreyIcon.d.ts +8 -0
  79. package/dist/components/Texts/index.d.ts +3 -0
  80. package/dist/components/index.d.ts +17 -0
  81. package/dist/main.d.ts +11 -0
  82. package/dist/main.js +54278 -0
  83. package/dist/main.umd.cjs +426 -0
  84. package/dist/themes/FoodPilotTheme.d.ts +3 -0
  85. package/dist/themes/ThemeExtensions.d.ts +99 -0
  86. package/dist/themes/WinePilotTheme.d.ts +3 -0
  87. package/dist/themes/index.d.ts +3 -0
  88. package/dist/types/Product.d.ts +18 -0
  89. package/dist/types/index.d.ts +42 -0
  90. package/package.json +77 -0
package/README.md ADDED
@@ -0,0 +1,30 @@
1
+ # React + TypeScript + Vite
2
+
3
+ This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.
4
+
5
+ Currently, two official plugins are available:
6
+
7
+ - [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react/README.md) uses [Babel](https://babeljs.io/) for Fast Refresh
8
+ - [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh
9
+
10
+ ## Expanding the ESLint configuration
11
+
12
+ If you are developing a production application, we recommend updating the configuration to enable type aware lint rules:
13
+
14
+ - Configure the top-level `parserOptions` property like this:
15
+
16
+ ```js
17
+ export default {
18
+ // other rules...
19
+ parserOptions: {
20
+ ecmaVersion: 'latest',
21
+ sourceType: 'module',
22
+ project: ['./tsconfig.json', './tsconfig.node.json'],
23
+ tsconfigRootDir: __dirname,
24
+ },
25
+ }
26
+ ```
27
+
28
+ - Replace `plugin:@typescript-eslint/recommended` to `plugin:@typescript-eslint/recommended-type-checked` or `plugin:@typescript-eslint/strict-type-checked`
29
+ - Optionally add `plugin:@typescript-eslint/stylistic-type-checked`
30
+ - Install [eslint-plugin-react](https://github.com/jsx-eslint/eslint-plugin-react) and add `plugin:react/recommended` & `plugin:react/jsx-runtime` to the `extends` list
@@ -0,0 +1,12 @@
1
+ export interface NodeGamme {
2
+ parent: string;
3
+ label: string;
4
+ children: string[];
5
+ }
6
+ export interface gammeState {
7
+ currentGamme: string;
8
+ gammes: Record<string, NodeGamme>;
9
+ search: string | null;
10
+ }
11
+ export declare const gammeAtom: import("recoil").RecoilState<gammeState>;
12
+ export declare const filteredGammes: import("recoil").RecoilValueReadOnly<Record<string, NodeGamme>>;
@@ -0,0 +1,5 @@
1
+ import * as gammeAtom from "./gammeAtom";
2
+ import * as ingredientsAtom from "./ingredientsAtom";
3
+ import * as productGridAtom from "./productGridAtom";
4
+ import * as questionnaireAtom from "./questionnaireAtom";
5
+ export { gammeAtom, ingredientsAtom, productGridAtom, questionnaireAtom };
@@ -0,0 +1,7 @@
1
+ import { Ingredient } from "../types";
2
+ export interface IIngredientGridState {
3
+ globalFilter: string;
4
+ defaultsSet: boolean;
5
+ ingredients: Ingredient[];
6
+ }
7
+ export declare const ingredientsAtom: import("recoil").RecoilState<IIngredientGridState>;
@@ -0,0 +1,13 @@
1
+ import { ProductGrid } from "../components/ProductGrid/ProductGrid";
2
+ export type ProductGridKeys = keyof ProductGrid;
3
+ export type ProductGridTypes = ProductGrid[ProductGridKeys];
4
+ export interface IProductGridState {
5
+ globalFilter: string;
6
+ columnVisibility: Record<string, boolean>;
7
+ columnOrder: string[];
8
+ defaultsSet: boolean;
9
+ products: ProductGrid[];
10
+ headers: Record<string, string>;
11
+ }
12
+ export declare const productGridAtom: import("recoil").RecoilState<IProductGridState>;
13
+ export declare const getUniqueProductValues: (param: keyof ProductGrid) => import("recoil").RecoilValueReadOnly<string[]>;
@@ -0,0 +1,4 @@
1
+ export interface IQuestionnaireState {
2
+ model: string | undefined;
3
+ }
4
+ export declare const questionnaireAtom: import("recoil").RecoilState<IQuestionnaireState>;
@@ -0,0 +1,27 @@
1
+ import React from "react";
2
+ export declare const StyledAccordion: import("@emotion/styled").StyledComponent<{
3
+ children: NonNullable<React.ReactNode>;
4
+ classes?: Partial<import("@mui/material/Accordion").AccordionClasses> | undefined;
5
+ defaultExpanded?: boolean | undefined;
6
+ disabled?: boolean | undefined;
7
+ disableGutters?: boolean | undefined;
8
+ expanded?: boolean | undefined;
9
+ onChange?: ((event: React.SyntheticEvent<Element, Event>, expanded: boolean) => void) | undefined;
10
+ sx?: import("@mui/system").SxProps<import("@mui/material").Theme> | undefined;
11
+ TransitionComponent?: React.JSXElementConstructor<import("@mui/material/transitions").TransitionProps & {
12
+ children?: React.ReactElement<any, any> | undefined;
13
+ }> | undefined;
14
+ TransitionProps?: import("@mui/material/transitions").TransitionProps | undefined;
15
+ } & Omit<import("@mui/material").PaperOwnProps, "classes" | "onChange"> & import("@mui/material/OverridableComponent").CommonProps & Omit<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
16
+ ref?: ((instance: HTMLDivElement | null) => void) | React.RefObject<HTMLDivElement> | null | undefined;
17
+ }, keyof import("@mui/material/OverridableComponent").CommonProps | "children" | "disabled" | "sx" | "variant" | "onChange" | "elevation" | "square" | "defaultExpanded" | "disableGutters" | "expanded" | "TransitionComponent" | "TransitionProps"> & {
18
+ theme?: import("@emotion/react").Theme | undefined;
19
+ }, {}, {}>;
20
+ export type AccordionContent = {
21
+ title: JSX.Element;
22
+ content: JSX.Element;
23
+ };
24
+ export type AccordionProductProps = {
25
+ pages: AccordionContent[];
26
+ };
27
+ export declare const AccordionProduct: (props: AccordionProductProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,8 @@
1
+ /// <reference types="react" />
2
+ export interface IGenericAccordionProps {
3
+ children: JSX.Element | JSX.Element[];
4
+ headerIcon: JSX.Element;
5
+ headerText: string;
6
+ controls?: JSX.Element | JSX.Element[];
7
+ }
8
+ export declare function GenericAccordion(props: IGenericAccordionProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export * from "./AccordionProduct";
2
+ export * from "./GenericAccordion";
@@ -0,0 +1,4 @@
1
+ /// <reference types="react" />
2
+ export declare function BaseTemplate(props: {
3
+ children: React.ReactNode;
4
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1 @@
1
+ export declare function Footer(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,11 @@
1
+ /// <reference types="react" />
2
+ export interface INavBarLink {
3
+ icon: React.ReactElement;
4
+ link: string;
5
+ isCurrent: boolean;
6
+ }
7
+ export interface INavBarProps {
8
+ links: INavBarLink[];
9
+ }
10
+ export default function NavBar(props: INavBarProps): import("react/jsx-runtime").JSX.Element;
11
+ export declare function NavBarLink(props: INavBarLink): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,4 @@
1
+ import * as BaseTemplate from "./BaseTemplate";
2
+ import * as Footer from "./Footer";
3
+ import * as Navbar from "./Navbar";
4
+ export { BaseTemplate, Footer, Navbar };
@@ -0,0 +1,4 @@
1
+ export type CategoryBoxProps = {
2
+ text: string;
3
+ };
4
+ export declare const CategoryBox: (props: CategoryBoxProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,5 @@
1
+ /// <reference types="react" />
2
+ export type DottedBoxProps = {
3
+ children: JSX.Element | JSX.Element[];
4
+ };
5
+ export declare const DottedBox: (props: DottedBoxProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,5 @@
1
+ /// <reference types="react" />
2
+ export type InfoBoxProps = {
3
+ children?: JSX.Element[];
4
+ };
5
+ export declare const InfoBox: (props: InfoBoxProps) => import("react/jsx-runtime").JSX.Element | null;
@@ -0,0 +1,9 @@
1
+ /// <reference types="react" />
2
+ export type LineGroupBoxProps = Omit<InnerLineGroupBoxProps, "children">;
3
+ type InnerLineGroupBoxProps = {
4
+ isFirst?: boolean;
5
+ isLast?: boolean;
6
+ children: JSX.Element | JSX.Element[];
7
+ };
8
+ export declare const LineGroupBox: (props: InnerLineGroupBoxProps) => import("react/jsx-runtime").JSX.Element;
9
+ export {};
@@ -0,0 +1,5 @@
1
+ /// <reference types="react" />
2
+ export type QuoteBoxProps = {
3
+ data: JSX.Element;
4
+ };
5
+ export declare const QuoteBox: (props: QuoteBoxProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,5 @@
1
+ /// <reference types="react" />
2
+ export type SolidGreyBoxProps = {
3
+ children: JSX.Element | JSX.Element[];
4
+ };
5
+ export declare const SolidGreyBox: (props: SolidGreyBoxProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,5 @@
1
+ /// <reference types="react" />
2
+ export type WarningBoxProps = {
3
+ children: JSX.Element | JSX.Element[];
4
+ };
5
+ export declare const WarningBox: (props: WarningBoxProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,7 @@
1
+ export * from "./CategoryBox";
2
+ export * from "./DottedBox";
3
+ export * from "./InfoBox";
4
+ export * from "./LineGroupBox";
5
+ export * from "./QuoteBox";
6
+ export * from "./SolidGreyBox";
7
+ export * from "./WarningBox";
@@ -0,0 +1,6 @@
1
+ import { ButtonProps as MuiButtonProps } from "@mui/material/Button";
2
+ type ButtonBaseProps = Omit<MuiButtonProps, "classes" | "sx" | "className" | "style" | "tabIndex">;
3
+ export interface ButtonProps extends ButtonBaseProps {
4
+ }
5
+ export declare const Button: (props: ButtonProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,9 @@
1
+ /// <reference types="react" />
2
+ export declare const CustomToggleButton: import("@emotion/styled").StyledComponent<import("@mui/material").ToggleButtonOwnProps & Omit<import("@mui/material").ButtonBaseOwnProps, "classes"> & import("@mui/material/OverridableComponent").CommonProps & Omit<Omit<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & {
3
+ ref?: ((instance: HTMLButtonElement | null) => void) | import("react").RefObject<HTMLButtonElement> | null | undefined;
4
+ }, "color" | "className" | "style" | "classes" | "action" | "centerRipple" | "children" | "disabled" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "sx" | "tabIndex" | "TouchRippleProps" | "touchRippleRef" | "disableFocusRipple" | "fullWidth" | "size" | "value" | "onChange" | "onClick" | "selected"> & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
5
+ export type TertiaryToggleButtonsProps = {
6
+ choices: string[];
7
+ onClick?: (index: number) => void;
8
+ };
9
+ export declare const TertiaryToggleButtons: (props: TertiaryToggleButtonsProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,3 @@
1
+ import * as Button from "./Button";
2
+ import * as TertiaryToggleButton from "./TertiaryToggleButton";
3
+ export { Button, TertiaryToggleButton };
@@ -0,0 +1,5 @@
1
+ export interface CardImageProps {
2
+ title: string;
3
+ introduction: string;
4
+ }
5
+ export declare const CardImage: (props: CardImageProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,13 @@
1
+ import { CheckboxProps } from "@mui/material";
2
+ type ObjectWithName = {
3
+ name: string;
4
+ };
5
+ export type CheckboxProperties = Record<string, boolean>;
6
+ export declare const checkboxToAny: <T extends ObjectWithName, U extends T>(startingValues: T[], allValues: CheckboxProperties, defaultValue: (name: string) => U) => T[];
7
+ export declare const anyToCheckbox: <T extends ObjectWithName>(values: T[], allValues: string[]) => CheckboxProperties;
8
+ type PrimaryCheckboxProps = Omit<CheckboxProps, "onChange"> & {
9
+ values: CheckboxProperties;
10
+ onChange: (label: string, isChecked: boolean) => void;
11
+ };
12
+ export declare const PrimaryCheckbox: (props: PrimaryCheckboxProps) => import("react/jsx-runtime").JSX.Element;
13
+ export {};
@@ -0,0 +1 @@
1
+ export * from "./PrimaryCheckbox";
@@ -0,0 +1,11 @@
1
+ import { Dispatch, SetStateAction } from "react";
2
+ import { Consumption } from "../../types";
3
+ type ConsumptionModalProps = {
4
+ isOpen: boolean;
5
+ setOpen: Dispatch<SetStateAction<boolean>>;
6
+ currentConsumptions: Consumption[];
7
+ allConsumptions: string[];
8
+ onValidate: (values: Consumption[]) => void;
9
+ };
10
+ export declare const ConsumptionModal: (props: ConsumptionModalProps) => JSX.Element;
11
+ export {};
@@ -0,0 +1,11 @@
1
+ import { Dispatch, SetStateAction } from "react";
2
+ import { Packaging } from "../../types";
3
+ type MaterialModalProps = {
4
+ isOpen: boolean;
5
+ setOpen: Dispatch<SetStateAction<boolean>>;
6
+ packaging: Packaging | null;
7
+ allMaterials: string[];
8
+ onValidate: (value: Packaging) => void;
9
+ };
10
+ export declare const MaterialModal: (props: MaterialModalProps) => JSX.Element | null;
11
+ export {};
@@ -0,0 +1,11 @@
1
+ import { Dispatch, SetStateAction } from "react";
2
+ import { Packaging } from "../../types";
3
+ type PackagingModalProps = {
4
+ isOpen: boolean;
5
+ setOpen: Dispatch<SetStateAction<boolean>>;
6
+ allPackagings: Packaging["name"][];
7
+ currentPackagings: Packaging[];
8
+ onValidate: (values: Packaging[]) => void;
9
+ };
10
+ export declare const PackagingModal: (props: PackagingModalProps) => JSX.Element;
11
+ export {};
@@ -0,0 +1,16 @@
1
+ import { Dispatch, SetStateAction } from "react";
2
+ type Settings = {
3
+ title: JSX.Element;
4
+ content: JSX.Element;
5
+ error?: JSX.Element;
6
+ };
7
+ type PrimaryDialogProps = {
8
+ isOpen: boolean;
9
+ setOpen: Dispatch<SetStateAction<boolean>>;
10
+ options: Settings;
11
+ onValidate?: () => void;
12
+ onCancel?: () => void;
13
+ canValidate?: boolean;
14
+ };
15
+ export declare const PrimaryDialog: (props: PrimaryDialogProps) => import("react/jsx-runtime").JSX.Element;
16
+ export {};
@@ -0,0 +1,11 @@
1
+ import { Dispatch, SetStateAction } from "react";
2
+ import { Transformation } from "../../types";
3
+ type TransformationModalProps = {
4
+ isOpen: boolean;
5
+ setOpen: Dispatch<SetStateAction<boolean>>;
6
+ allTransformations: Transformation["name"][];
7
+ currentTransformations: Transformation[];
8
+ onValidate: (values: Transformation[]) => void;
9
+ };
10
+ export declare const TransformationModal: (props: TransformationModalProps) => JSX.Element;
11
+ export {};
@@ -0,0 +1,5 @@
1
+ export * from "./ConsumptionModal";
2
+ export * from "./MaterialModal";
3
+ export * from "./PackagingModal";
4
+ export * from "./PrimaryDialog";
5
+ export * from "./TransformationModal";
@@ -0,0 +1,9 @@
1
+ import { EmptyProduct } from "../../types";
2
+ export type CategoryFieldProps = {
3
+ title: string;
4
+ tiles: string[];
5
+ description: string;
6
+ addAction: (newProduct: EmptyProduct) => void;
7
+ product: EmptyProduct;
8
+ };
9
+ export declare const CategoryField: (props: CategoryFieldProps) => JSX.Element;
@@ -0,0 +1,9 @@
1
+ import { EmptyProduct } from "../../types";
2
+ export type GammeFieldProps = {
3
+ title: string;
4
+ tiles: string[];
5
+ description: string;
6
+ addAction: (newProduct: EmptyProduct) => void;
7
+ product: EmptyProduct;
8
+ };
9
+ export declare const GammeField: (props: GammeFieldProps) => JSX.Element;
@@ -0,0 +1,9 @@
1
+ import { RoundInputProps } from "../Inputs/RoundInput";
2
+ export type NumberFieldProps = RoundInputProps & {
3
+ title: string;
4
+ unit: string;
5
+ placeholder: string;
6
+ value?: number;
7
+ description?: string;
8
+ };
9
+ export declare const NumberField: (props: NumberFieldProps) => JSX.Element;
@@ -0,0 +1,9 @@
1
+ /// <reference types="react" />
2
+ import { RoundInputProps } from "../Inputs/RoundInput";
3
+ export type TextFieldProps = RoundInputProps & {
4
+ title: string;
5
+ placeholder: string;
6
+ value?: string;
7
+ description?: string;
8
+ };
9
+ export declare function TextField(props: TextFieldProps): JSX.Element;
@@ -0,0 +1,4 @@
1
+ export * from "./NumberField";
2
+ export * from "./TextField";
3
+ export * from "./CategoryField";
4
+ export * from "./GammeField";
@@ -0,0 +1,19 @@
1
+ /// <reference types="react" />
2
+ export type Page = {
3
+ title: string;
4
+ subTitle?: string;
5
+ info?: JSX.Element;
6
+ bigIcon: JSX.Element;
7
+ smallIcon: {
8
+ selected: JSX.Element;
9
+ unselected: JSX.Element;
10
+ };
11
+ content: JSX.Element | JSX.Element[];
12
+ usesBaseLayout?: boolean;
13
+ };
14
+ export type FormBaseProps = {
15
+ title: string;
16
+ icon: JSX.Element;
17
+ pages: Page[];
18
+ };
19
+ export declare const FormBase: (props: FormBaseProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ import * as FormBase from "./FormBase";
2
+ export { FormBase };
@@ -0,0 +1,4 @@
1
+ import { MRT_RowData, MRT_TableOptions } from "material-react-table";
2
+ export interface IMRTGridProps<T extends MRT_RowData> extends MRT_TableOptions<T> {
3
+ }
4
+ export declare function MRTGrid<T extends MRT_RowData>(props: MRT_TableOptions<T>): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,6 @@
1
+ import { Packaging } from "../../types";
2
+ export type MaterialGridProps = {
3
+ packaging: Packaging;
4
+ onChange: (newPackaging: Packaging) => void;
5
+ };
6
+ export declare const MaterialGrid: (props: MaterialGridProps) => JSX.Element;
@@ -0,0 +1,2 @@
1
+ export * from "./MaterialGrid";
2
+ export * from "./MRTGrid";
@@ -0,0 +1,3 @@
1
+ import type { InputBaseProps } from "@mui/material";
2
+ export type RoundInputProps = InputBaseProps;
3
+ export declare const RoundInput: (props: RoundInputProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,5 @@
1
+ import { RoundInputProps } from "./RoundInput";
2
+ export type RoundNumberInputProps = RoundInputProps & {
3
+ unit: string;
4
+ };
5
+ export declare const RoundNumberInput: (props: RoundNumberInputProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,7 @@
1
+ export interface ISearchBoxProps {
2
+ placeholder?: string;
3
+ value: string | null;
4
+ onChange: (value: string) => void;
5
+ variant: "standalone" | "inline";
6
+ }
7
+ export declare function SearchBox(props: ISearchBoxProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,3 @@
1
+ export * from "./RoundInput";
2
+ export * from "./RoundNumberInput";
3
+ export * from "./SearchBox";
@@ -0,0 +1,9 @@
1
+ import { LinearProgressProps as MuiLinearProgressProps } from "@mui/material/LinearProgress";
2
+ type LinearProgressBaseProps = Omit<MuiLinearProgressProps, "classes" | "sx" | "valueBuffer" | "variant">;
3
+ export interface LinearProgressProps extends LinearProgressBaseProps {
4
+ value: number;
5
+ }
6
+ export declare const LinearProgress: (props: LinearProgressProps & {
7
+ value: number;
8
+ }) => import("react/jsx-runtime").JSX.Element;
9
+ export {};
@@ -0,0 +1,11 @@
1
+ /// <reference types="react" />
2
+ import { Icon } from "./IconThread";
3
+ type FormTopBarProps = {
4
+ title: string;
5
+ icon: JSX.Element;
6
+ pageIcons: Icon[];
7
+ currentPage: number;
8
+ setPage: (value: number) => void;
9
+ };
10
+ export declare const FormTopBar: (props: FormTopBarProps) => import("react/jsx-runtime").JSX.Element;
11
+ export {};
@@ -0,0 +1,10 @@
1
+ /// <reference types="react" />
2
+ export type Icon = {
3
+ selected: JSX.Element;
4
+ unselected: JSX.Element;
5
+ };
6
+ export type IconThreadProps = {
7
+ icons: Icon[];
8
+ currentStep?: number;
9
+ };
10
+ export declare const IconThread: (props: IconThreadProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export * from "./FormTopBar";
2
+ export * from "./IconThread";
@@ -0,0 +1 @@
1
+ export declare function AddProductPopover(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,16 @@
1
+ /// <reference types="react" />
2
+ export interface IAnchoredPopoverProps {
3
+ open: boolean;
4
+ anchor: HTMLElement | null;
5
+ onClose: () => void;
6
+ anchorPosition?: "leftside" | "center" | "rightside";
7
+ children: JSX.Element | JSX.Element[];
8
+ variant?: "themed" | "headless";
9
+ }
10
+ export declare enum AnchoredPopoverVariant {
11
+ "themed" = 0,
12
+ "headless" = 1
13
+ }
14
+ export declare function AnchoredPopover(props: IAnchoredPopoverProps): import("react/jsx-runtime").JSX.Element;
15
+ export declare function ThemedPopover(props: IAnchoredPopoverProps): import("react/jsx-runtime").JSX.Element;
16
+ export declare function HeadlessPopover(props: IAnchoredPopoverProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,12 @@
1
+ /// <reference types="react" />
2
+ export interface IBigPopoverLayout {
3
+ headerText: string;
4
+ headerIcon?: JSX.Element;
5
+ children: JSX.Element | JSX.Element[];
6
+ bottomActions?: boolean;
7
+ width?: string;
8
+ onClose: () => void;
9
+ onCancel?: () => void;
10
+ onValidate?: () => void;
11
+ }
12
+ export declare function BigPopoverLayout(props: IBigPopoverLayout): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,13 @@
1
+ import { NodeGamme } from "../../atoms/gammeAtom";
2
+ export interface ISelectProductLineProps {
3
+ onClose: () => void;
4
+ setGamme: (gamme: string) => void;
5
+ gamme: string;
6
+ }
7
+ export declare function CommonSelectProductLine(props: ISelectProductLineProps): import("react/jsx-runtime").JSX.Element;
8
+ export interface IRenderNodeProps {
9
+ id: string;
10
+ setGamme: (id: string) => void;
11
+ currentGamme: string;
12
+ gammes: Record<string, NodeGamme>;
13
+ }
@@ -0,0 +1,8 @@
1
+ /// <reference types="react" />
2
+ type WhitePopoverOnIconProps = {
3
+ icon: JSX.Element;
4
+ body: JSX.Element;
5
+ size: string;
6
+ };
7
+ export declare const WhitePopoverOnIcon: (props: WhitePopoverOnIconProps) => import("react/jsx-runtime").JSX.Element;
8
+ export {};
@@ -0,0 +1,6 @@
1
+ import * as AddProductPopover from "./AddProductPopover";
2
+ import * as AnchoredPopover from "./AnchoredPopover";
3
+ import * as BigPopoverLayout from "./BigPopoverLayout";
4
+ import * as CommonSelectProductLine from "./CommonSelectProductLine";
5
+ import * as WhitePopoverOnIcon from "./WhitePopoverOnIcon";
6
+ export { AddProductPopover, AnchoredPopover, BigPopoverLayout, CommonSelectProductLine, WhitePopoverOnIcon };
@@ -0,0 +1,3 @@
1
+ export declare function ArrayCell(props: {
2
+ value: string[];
3
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,6 @@
1
+ export interface IEcoScoreCellProps {
2
+ grade: string;
3
+ value: number;
4
+ hasWarning: boolean;
5
+ }
6
+ export declare function EcoScoreCell(props: IEcoScoreCellProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,3 @@
1
+ export declare function GreyTextCell(props: {
2
+ value: string;
3
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,4 @@
1
+ export declare function LinkCell(props: {
2
+ value: string;
3
+ chain: boolean;
4
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,4 @@
1
+ export declare function PointsCell(props: {
2
+ value: string;
3
+ hasWarning: boolean;
4
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,6 @@
1
+ import * as ArrayCell from "./ArrayCell";
2
+ import * as EcoScoreCell from "./EcoScoreCell";
3
+ import * as GreyCell from "./GreyCell";
4
+ import * as LinkCell from "./LinkCell";
5
+ import * as PointsCell from "./PointsCell";
6
+ export { ArrayCell, EcoScoreCell, GreyCell, LinkCell, PointsCell };
@@ -0,0 +1 @@
1
+ export declare function ProductHeader(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1 @@
1
+ export declare function TableHeader(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,3 @@
1
+ import * as ProductPageHeader from "./ProductPageHeader";
2
+ import * as TableHeader from "./TableHeader";
3
+ export { ProductPageHeader, TableHeader };
@@ -0,0 +1,4 @@
1
+ export interface IColumnPositionPopoverProps {
2
+ onClose: () => void;
3
+ }
4
+ export declare function ColumnPositionPopover(props: IColumnPositionPopoverProps): import("react/jsx-runtime").JSX.Element;