@foodpilot/foods 2.7.3 → 2.7.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Button/FoodsToggleButton.js +1 -0
- package/dist/components/Cards/SeeMoreCard/SeeMoreCard.js +1 -1
- package/dist/components/Chart/TrajectoryChart/TrajectoryChart.d.ts +2 -0
- package/dist/components/Chart/TrajectoryChart/TrajectoryChart.js +3 -1
- package/dist/components/Dialog/PrimaryDialog.js +1 -1
- package/dist/themes/common/MUIComponents/buttons.d.ts +1 -1
- package/dist/themes/common/components.js +35 -10
- package/package.json +1 -1
|
@@ -16,7 +16,7 @@ const SeeMoreCard = (props) => {
|
|
|
16
16
|
return /* @__PURE__ */ jsxs(
|
|
17
17
|
Stack,
|
|
18
18
|
{
|
|
19
|
-
padding: theme.spacing(4),
|
|
19
|
+
padding: { xs: theme.spacing(2), sm: theme.spacing(4) },
|
|
20
20
|
gap: theme.spacing(3),
|
|
21
21
|
border: `1px solid ${theme.custom.grey[500]}`,
|
|
22
22
|
borderRadius: "12px",
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { SxProps, Theme } from '@mui/material';
|
|
1
2
|
import { BarsOptions } from './useBars';
|
|
2
3
|
import { Improvement } from '../../ComparisonBlock/ComparisonBlock';
|
|
3
4
|
import { TextOptions } from './TrajectoryLegend/types';
|
|
@@ -12,5 +13,6 @@ export type TrajectoryChartProps = BarsOptions & {
|
|
|
12
13
|
precision?: number;
|
|
13
14
|
textOptions: TextOptions;
|
|
14
15
|
forceGoalLegend?: boolean;
|
|
16
|
+
sx?: SxProps<Theme>;
|
|
15
17
|
};
|
|
16
18
|
export declare const TrajectoryChart: (props: TrajectoryChartProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -26,6 +26,7 @@ const TrajectoryChart = (props) => {
|
|
|
26
26
|
precision = DEFAULT_PRECISION,
|
|
27
27
|
textOptions,
|
|
28
28
|
forceGoalLegend,
|
|
29
|
+
sx,
|
|
29
30
|
...allChartsData
|
|
30
31
|
} = props;
|
|
31
32
|
const chartData = useBars(allChartsData);
|
|
@@ -113,7 +114,8 @@ const TrajectoryChart = (props) => {
|
|
|
113
114
|
borderRadius: theme.spacing(BORDER_RADIUS_SPACING),
|
|
114
115
|
height: "100%",
|
|
115
116
|
width: "100%",
|
|
116
|
-
padding: theme.spacing(PADDING_SPACING)
|
|
117
|
+
padding: theme.spacing(PADDING_SPACING),
|
|
118
|
+
...sx
|
|
117
119
|
},
|
|
118
120
|
ref: chartContainerRef,
|
|
119
121
|
children: /* @__PURE__ */ jsx(
|
|
@@ -41,7 +41,7 @@ const PrimaryDialog = (props) => {
|
|
|
41
41
|
closeWindow();
|
|
42
42
|
}
|
|
43
43
|
};
|
|
44
|
-
return /* @__PURE__ */ jsxs(Dialog, { onClose: _onCancel,
|
|
44
|
+
return /* @__PURE__ */ jsxs(Dialog, { onClose: _onCancel, fullWidth: true, maxWidth: "md", scroll: "body", ...dialogProps, children: [
|
|
45
45
|
/* @__PURE__ */ jsxs(DialogTitle, { sx: dialogTitleStyles, children: [
|
|
46
46
|
options.title,
|
|
47
47
|
/* @__PURE__ */ jsx(Button, { variant: "text", endIcon: /* @__PURE__ */ jsx(SvgBlackCross, {}), onClick: _onCancel })
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export type IconButtonVariants = "icon-xs-nobackground" | "icon-s-nobackground" | "icon-m-nobackground" | "icon-xs-withbackground" | "icon-s-withbackground" | "icon-m-withbackground";
|
|
2
2
|
export type TagsButtonVariants = "tags-grey" | "tags-black" | "tags-white" | "tags-red" | "tags-green";
|
|
3
|
-
export type customButtonVariants = "primary" | "secondary" | "ternary" | "text" | "black-text" | "selected-menu" | "selected-submenu" | "default-menu" | "black-filled" | "white-filled" | "white-filled-no-shadow" | "select" | "validate" | IconButtonVariants | TagsButtonVariants;
|
|
3
|
+
export type customButtonVariants = "primary" | "secondary" | "ternary" | "text" | "black-text" | "selected-menu" | "selected-submenu" | "default-menu" | "black-filled" | "white-filled" | "white-filled-no-shadow" | "select" | "validate" | "error" | "delete" | IconButtonVariants | TagsButtonVariants;
|
|
4
4
|
type ButtonNewVariants = Record<customButtonVariants, React.CSSProperties>;
|
|
5
5
|
type ButtonPropsNewVariants = Record<customButtonVariants, true>;
|
|
6
6
|
declare module "@mui/material/styles" {
|
|
@@ -114,8 +114,8 @@ const components = {
|
|
|
114
114
|
boxShadow: `0px 4px 8px 0px #2A2B2714`
|
|
115
115
|
},
|
|
116
116
|
...ownerState.variant === "secondary" && {
|
|
117
|
-
border: `
|
|
118
|
-
|
|
117
|
+
border: `1px solid ${theme.custom.grey[500]}`,
|
|
118
|
+
background: `linear-gradient(${theme.custom.grey[100]}}, ${theme.custom.grey[300]})`
|
|
119
119
|
},
|
|
120
120
|
...ownerState.variant === "ternary" && {
|
|
121
121
|
border: `1px solid ${theme.custom.grey[500]}`,
|
|
@@ -178,14 +178,25 @@ const components = {
|
|
|
178
178
|
transition: "none",
|
|
179
179
|
background: `linear-gradient(180deg, ${theme.custom.green[500]} 0%, ${theme.custom.green[700]} 100%)`
|
|
180
180
|
},
|
|
181
|
+
...ownerState.variant === "delete" && {
|
|
182
|
+
borderRadius: "44px",
|
|
183
|
+
color: "#FFFFFF",
|
|
184
|
+
transition: "none",
|
|
185
|
+
background: `${theme.custom.red[600]}`
|
|
186
|
+
},
|
|
187
|
+
...ownerState.variant === "error" && {
|
|
188
|
+
transition: "none",
|
|
189
|
+
paddingInline: "0",
|
|
190
|
+
color: theme.custom.red[600],
|
|
191
|
+
fontWeight: "600"
|
|
192
|
+
},
|
|
181
193
|
":hover": {
|
|
182
194
|
...ownerState.variant === "primary" && {
|
|
183
195
|
background: theme.palette.primary[600]
|
|
184
196
|
},
|
|
185
197
|
...ownerState.variant === "secondary" && {
|
|
186
|
-
color: "#FFFFFF",
|
|
187
|
-
|
|
188
|
-
background: theme.palette.primary[600]
|
|
198
|
+
// color: "#FFFFFF",
|
|
199
|
+
background: theme.custom.grey[400]
|
|
189
200
|
},
|
|
190
201
|
...ownerState.variant === "ternary" && {
|
|
191
202
|
border: `1px solid ${theme.custom.grey[500]}`,
|
|
@@ -213,6 +224,12 @@ const components = {
|
|
|
213
224
|
},
|
|
214
225
|
...ownerState.variant === "validate" && {
|
|
215
226
|
background: theme.custom.green[600]
|
|
227
|
+
},
|
|
228
|
+
...ownerState.variant === "delete" && {
|
|
229
|
+
background: theme.custom.red[700]
|
|
230
|
+
},
|
|
231
|
+
...ownerState.variant === "error" && {
|
|
232
|
+
color: theme.custom.red[900]
|
|
216
233
|
}
|
|
217
234
|
},
|
|
218
235
|
":disabled": {
|
|
@@ -221,8 +238,8 @@ const components = {
|
|
|
221
238
|
background: alpha(theme.palette.primary["600"] ?? "", 0.36)
|
|
222
239
|
},
|
|
223
240
|
...ownerState.variant === "secondary" && {
|
|
224
|
-
color: alpha(theme.
|
|
225
|
-
border: `
|
|
241
|
+
color: alpha(theme.custom.grey["2800"], 0.36),
|
|
242
|
+
border: `1px solid ${alpha(theme.custom.grey["500"], 0.36)}`,
|
|
226
243
|
background: theme.custom.grey[100]
|
|
227
244
|
},
|
|
228
245
|
...ownerState.variant === "ternary" && {
|
|
@@ -247,6 +264,13 @@ const components = {
|
|
|
247
264
|
...ownerState.variant === "validate" && {
|
|
248
265
|
background: alpha(theme.custom.green[500], 0.36),
|
|
249
266
|
color: "#FFFFFF"
|
|
267
|
+
},
|
|
268
|
+
...ownerState.variant === "delete" && {
|
|
269
|
+
background: theme.custom.red[100],
|
|
270
|
+
color: alpha(theme.custom.red[600], 0.36)
|
|
271
|
+
},
|
|
272
|
+
...ownerState.variant === "error" && {
|
|
273
|
+
color: alpha(theme.custom.red[700], 0.36)
|
|
250
274
|
}
|
|
251
275
|
},
|
|
252
276
|
":active": {
|
|
@@ -254,9 +278,7 @@ const components = {
|
|
|
254
278
|
background: theme.palette.primary[800]
|
|
255
279
|
},
|
|
256
280
|
...ownerState.variant === "secondary" && {
|
|
257
|
-
|
|
258
|
-
border: "none",
|
|
259
|
-
background: theme.palette.primary[800]
|
|
281
|
+
background: theme.custom.grey[400]
|
|
260
282
|
},
|
|
261
283
|
...ownerState.variant === "secondary" && {
|
|
262
284
|
background: theme.custom.grey[600]
|
|
@@ -275,6 +297,9 @@ const components = {
|
|
|
275
297
|
},
|
|
276
298
|
...ownerState.variant === "validate" && {
|
|
277
299
|
background: theme.custom.green[800]
|
|
300
|
+
},
|
|
301
|
+
...ownerState.variant === "delete" && {
|
|
302
|
+
background: theme.custom.red[800]
|
|
278
303
|
}
|
|
279
304
|
},
|
|
280
305
|
...ownerState.variant === "tags-grey" && {
|