react-easy-wall 1.0.28 → 1.0.29
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/cjs/components/panel/PanelButton.js +3 -1
- package/dist/cjs/components/panel/PanelButton.js.map +1 -1
- package/dist/cjs/components/panel/PanelSubscriptionIcon.js +6 -1
- package/dist/cjs/components/panel/PanelSubscriptionIcon.js.map +1 -1
- package/dist/esm/components/panel/PanelButton.js +3 -1
- package/dist/esm/components/panel/PanelButton.js.map +1 -1
- package/dist/esm/components/panel/PanelSubscriptionIcon.js +6 -1
- package/dist/esm/components/panel/PanelSubscriptionIcon.js.map +1 -1
- package/package.json +1 -1
|
@@ -5,11 +5,13 @@ var jsxRuntime = require('react/jsx-runtime');
|
|
|
5
5
|
var panel_actions = require('./panel.actions.js');
|
|
6
6
|
var index = require('../../_virtual/index.js');
|
|
7
7
|
var panel_store = require('./panel.store.js');
|
|
8
|
+
var session_hooks = require('../session/session.hooks.js');
|
|
8
9
|
var Button = require('../../node_modules/@mui/material/esm/Button/Button.js');
|
|
9
10
|
|
|
10
11
|
const PanelButton = ({ children, ...rest }) => {
|
|
11
12
|
const { isOpen } = index.libExports.useStore(panel_store.panelStore);
|
|
12
|
-
|
|
13
|
+
const { user } = session_hooks.useSession();
|
|
14
|
+
return (jsxRuntime.jsx(Button.default, { onClick: () => user && panel_actions.handlePanelClick(!isOpen), ...rest, children: children }));
|
|
13
15
|
};
|
|
14
16
|
|
|
15
17
|
exports.PanelButton = PanelButton;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PanelButton.js","sources":["../../../../src/components/panel/PanelButton.tsx"],"sourcesContent":["'use client'
|
|
1
|
+
{"version":3,"file":"PanelButton.js","sources":["../../../../src/components/panel/PanelButton.tsx"],"sourcesContent":["'use client';\nimport React, { FC } from 'react';\nimport { Button, ButtonProps } from '@mui/material';\nimport { handlePanelClick } from './panel.actions';\nimport { useStore } from '@cobuildlab/react-simple-state';\nimport { panelStore } from './panel.store';\nimport { useSession } from '../session/session.hooks';\n\nexport interface PanelButtonProps extends ButtonProps {\n children: React.ReactNode;\n}\n\nexport const PanelButton: FC<PanelButtonProps> = ({ children, ...rest }) => {\n const { isOpen } = useStore(panelStore);\n const { user } = useSession();\n return (\n <Button onClick={() => user && handlePanelClick(!isOpen)} {...rest}>\n {children}\n </Button>\n );\n};\n"],"names":[],"mappings":";;;;;;;;;;AAYO;;AAEL;;AAMF;;"}
|
|
@@ -9,7 +9,12 @@ const PanelSubscriptionIcon = ({ children, subscriptionImageContainerProps = {},
|
|
|
9
9
|
const { subscription } = session_hooks.useSession();
|
|
10
10
|
if (!subscription)
|
|
11
11
|
return null;
|
|
12
|
-
return jsxRuntime.jsx(Box.default, {
|
|
12
|
+
return (jsxRuntime.jsx(Box.default, { sx: {
|
|
13
|
+
borderRadius: '50%',
|
|
14
|
+
position: 'absolute',
|
|
15
|
+
top: -7,
|
|
16
|
+
right: -7,
|
|
17
|
+
}, ...subscriptionImageContainerProps, children: children }));
|
|
13
18
|
};
|
|
14
19
|
|
|
15
20
|
exports.PanelSubscriptionIcon = PanelSubscriptionIcon;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PanelSubscriptionIcon.js","sources":["../../../../src/components/panel/PanelSubscriptionIcon.tsx"],"sourcesContent":["'use client';\n\nimport React from 'react';\nimport { useSession } from '../session/session.hooks';\nimport { Box
|
|
1
|
+
{"version":3,"file":"PanelSubscriptionIcon.js","sources":["../../../../src/components/panel/PanelSubscriptionIcon.tsx"],"sourcesContent":["'use client';\n\nimport React from 'react';\nimport { useSession } from '../session/session.hooks';\nimport { Box, BoxProps } from '@mui/material';\n\nexport interface PanelSubscriptionIconProps {\n children?: React.ReactNode;\n subscriptionImageContainerProps?: BoxProps;\n}\n\nexport const PanelSubscriptionIcon: React.FC<PanelSubscriptionIconProps> = ({\n children,\n subscriptionImageContainerProps = {},\n}) => {\n const { subscription } = useSession();\n\n if (!subscription) return null;\n\n return (\n <Box\n sx={{\n borderRadius: '50%',\n position: 'absolute',\n top: -7,\n right: -7,\n }}\n {...subscriptionImageContainerProps}>\n {children}\n </Box>\n );\n};\n"],"names":[],"mappings":";;;;;;;AAWO;AAIL;AAEA;AAAmB;AAEnB;AAGM;AACA;;;AAGD;AAKP;;"}
|
|
@@ -3,11 +3,13 @@ import { jsx } from 'react/jsx-runtime';
|
|
|
3
3
|
import { handlePanelClick } from './panel.actions.js';
|
|
4
4
|
import { l as libExports } from '../../_virtual/index.js';
|
|
5
5
|
import { panelStore } from './panel.store.js';
|
|
6
|
+
import { useSession } from '../session/session.hooks.js';
|
|
6
7
|
import Button from '../../node_modules/@mui/material/esm/Button/Button.js';
|
|
7
8
|
|
|
8
9
|
const PanelButton = ({ children, ...rest }) => {
|
|
9
10
|
const { isOpen } = libExports.useStore(panelStore);
|
|
10
|
-
|
|
11
|
+
const { user } = useSession();
|
|
12
|
+
return (jsx(Button, { onClick: () => user && handlePanelClick(!isOpen), ...rest, children: children }));
|
|
11
13
|
};
|
|
12
14
|
|
|
13
15
|
export { PanelButton };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PanelButton.js","sources":["../../../../src/components/panel/PanelButton.tsx"],"sourcesContent":["'use client'
|
|
1
|
+
{"version":3,"file":"PanelButton.js","sources":["../../../../src/components/panel/PanelButton.tsx"],"sourcesContent":["'use client';\nimport React, { FC } from 'react';\nimport { Button, ButtonProps } from '@mui/material';\nimport { handlePanelClick } from './panel.actions';\nimport { useStore } from '@cobuildlab/react-simple-state';\nimport { panelStore } from './panel.store';\nimport { useSession } from '../session/session.hooks';\n\nexport interface PanelButtonProps extends ButtonProps {\n children: React.ReactNode;\n}\n\nexport const PanelButton: FC<PanelButtonProps> = ({ children, ...rest }) => {\n const { isOpen } = useStore(panelStore);\n const { user } = useSession();\n return (\n <Button onClick={() => user && handlePanelClick(!isOpen)} {...rest}>\n {children}\n </Button>\n );\n};\n"],"names":[],"mappings":";;;;;;;;AAYO;;AAEL;;AAMF;;"}
|
|
@@ -7,7 +7,12 @@ const PanelSubscriptionIcon = ({ children, subscriptionImageContainerProps = {},
|
|
|
7
7
|
const { subscription } = useSession();
|
|
8
8
|
if (!subscription)
|
|
9
9
|
return null;
|
|
10
|
-
return jsx(Box, {
|
|
10
|
+
return (jsx(Box, { sx: {
|
|
11
|
+
borderRadius: '50%',
|
|
12
|
+
position: 'absolute',
|
|
13
|
+
top: -7,
|
|
14
|
+
right: -7,
|
|
15
|
+
}, ...subscriptionImageContainerProps, children: children }));
|
|
11
16
|
};
|
|
12
17
|
|
|
13
18
|
export { PanelSubscriptionIcon };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PanelSubscriptionIcon.js","sources":["../../../../src/components/panel/PanelSubscriptionIcon.tsx"],"sourcesContent":["'use client';\n\nimport React from 'react';\nimport { useSession } from '../session/session.hooks';\nimport { Box
|
|
1
|
+
{"version":3,"file":"PanelSubscriptionIcon.js","sources":["../../../../src/components/panel/PanelSubscriptionIcon.tsx"],"sourcesContent":["'use client';\n\nimport React from 'react';\nimport { useSession } from '../session/session.hooks';\nimport { Box, BoxProps } from '@mui/material';\n\nexport interface PanelSubscriptionIconProps {\n children?: React.ReactNode;\n subscriptionImageContainerProps?: BoxProps;\n}\n\nexport const PanelSubscriptionIcon: React.FC<PanelSubscriptionIconProps> = ({\n children,\n subscriptionImageContainerProps = {},\n}) => {\n const { subscription } = useSession();\n\n if (!subscription) return null;\n\n return (\n <Box\n sx={{\n borderRadius: '50%',\n position: 'absolute',\n top: -7,\n right: -7,\n }}\n {...subscriptionImageContainerProps}>\n {children}\n </Box>\n );\n};\n"],"names":[],"mappings":";;;;;AAWO;AAIL;AAEA;AAAmB;AAEnB;AAGM;AACA;;;AAGD;AAKP;;"}
|