@symply.io/basic-components 1.3.11-alpha.10 → 1.3.11-alpha.11

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.
@@ -1,4 +1,4 @@
1
- import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { useMemo } from "react";
3
3
  import Slide from "@mui/material/Slide";
4
4
  import Snackbar from "@mui/material/Snackbar";
@@ -37,7 +37,7 @@ function Prompt(props) {
37
37
  error: ErrorIcon,
38
38
  info: InfoIcon
39
39
  }), []);
40
- const Icon = useMemo(() => VariantIcon[variant], []);
40
+ const Icon = useMemo(() => icon || VariantIcon[variant], []);
41
41
  return (_jsx(ThemeProvider, { theme: theme, children: _jsx(Snackbar, { anchorOrigin: { vertical: "bottom", horizontal: "left" }, open: open, onClose: onClose, autoHideDuration: timeout, TransitionComponent: Transition, sx: {
42
42
  zIndex: 99999,
43
43
  marginTop: "3vh"
@@ -54,10 +54,10 @@ function Prompt(props) {
54
54
  fontWeight: 700,
55
55
  display: "flex",
56
56
  alignItems: "center"
57
- }, children: [!icon ? (_jsx(Icon, { sx: {
57
+ }, children: [_jsx(Icon, { sx: {
58
58
  fontSize: 20,
59
59
  opacity: 0.9,
60
60
  marginRight: theme.spacing(1)
61
- } })) : (_jsx(_Fragment, { children: icon })), message] }) }) }, `${Date.now() * Math.round(Math.random())}`) }));
61
+ } }), message] }) }) }, `${Date.now() * Math.round(Math.random())}`) }));
62
62
  }
63
63
  export default Prompt;
@@ -1,6 +1,6 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { createContext, useContext, cloneElement } from "react";
3
- import { default as Prompt } from "./Prompt";
3
+ import Prompt from "./Prompt";
4
4
  import useInteractions from "./useInteractions";
5
5
  const PromptContext = createContext({
6
6
  showPrompt: () => { }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@symply.io/basic-components",
3
- "version": "1.3.11-alpha.10",
3
+ "version": "1.3.11-alpha.11",
4
4
  "description": "Basic and reusable components for all frontend of Symply apps",
5
5
  "keywords": [
6
6
  "react",