magneto365.ui 2.71.0 → 2.72.1

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 (18) hide show
  1. package/dist/cjs/index.js +4 -4
  2. package/dist/cjs/index.js.map +1 -1
  3. package/dist/cjs/types/components/UI/molecules/Drawer/Drawer.interface.d.ts +4 -0
  4. package/dist/cjs/types/components/docs/DesignSystem/DesignSystem.interface.d.ts +32 -0
  5. package/dist/cjs/types/components/docs/DesignSystem/children/DesignSystemUtilityClass/children/DesignSystemUtilityClassRenderer/DesignSystemUtilityClassRenderer.component.d.ts +3 -0
  6. package/dist/cjs/types/components/docs/DesignSystem/children/DesignSystemUtilityClass/children/DesignSystemUtilityClassRenderer/DesignSystemUtilityClassRenderer.interface.d.ts +4 -0
  7. package/dist/cjs/types/components/docs/DesignSystem/children/DesignSystemUtilityClass/children/DesignSystemUtilityClassRenderer/index.d.ts +2 -0
  8. package/dist/cjs/types/components/docs/DesignSystem/children/DesignSystemUtilityClass/children/index.d.ts +1 -0
  9. package/dist/esm/index.js +4 -4
  10. package/dist/esm/index.js.map +1 -1
  11. package/dist/esm/types/components/UI/molecules/Drawer/Drawer.interface.d.ts +4 -0
  12. package/dist/esm/types/components/docs/DesignSystem/DesignSystem.interface.d.ts +32 -0
  13. package/dist/esm/types/components/docs/DesignSystem/children/DesignSystemUtilityClass/children/DesignSystemUtilityClassRenderer/DesignSystemUtilityClassRenderer.component.d.ts +3 -0
  14. package/dist/esm/types/components/docs/DesignSystem/children/DesignSystemUtilityClass/children/DesignSystemUtilityClassRenderer/DesignSystemUtilityClassRenderer.interface.d.ts +4 -0
  15. package/dist/esm/types/components/docs/DesignSystem/children/DesignSystemUtilityClass/children/DesignSystemUtilityClassRenderer/index.d.ts +2 -0
  16. package/dist/esm/types/components/docs/DesignSystem/children/DesignSystemUtilityClass/children/index.d.ts +1 -0
  17. package/dist/index.d.ts +4 -0
  18. package/package.json +1 -1
@@ -42,6 +42,10 @@ export interface IDrawer {
42
42
  * this property blocks fn onClose from background
43
43
  */
44
44
  blockBackgroundClose?: boolean;
45
+ /**
46
+ * this property sets custom styles into background drawer
47
+ */
48
+ backGroundClassName?: string;
45
49
  }
46
50
  /**
47
51
  * This interface represents a Portal for the Drawer component.
@@ -0,0 +1,32 @@
1
+ export declare type IDesignSystem = {
2
+ values: IDesignSystemValues;
3
+ utilities?: IDesignSystemUtilities;
4
+ docs?: IDesignSystemDocs;
5
+ };
6
+ export declare type IDesignSystemValues = {
7
+ [key: string]: string | number | IDesignSystemValues;
8
+ };
9
+ export declare type IDesignSystemUtilities = {
10
+ imports?: IDesignSystemImport[];
11
+ classes?: IDesignSystemClass[];
12
+ };
13
+ export declare type IDesignSystemImport = {
14
+ file: string;
15
+ alias?: string;
16
+ };
17
+ export declare type IDesignSystemClass = {
18
+ name: string;
19
+ prefix: string;
20
+ conditions?: IDesignSystemConditions;
21
+ properties: IDesignSystemProperty[];
22
+ };
23
+ export declare type IDesignSystemConditions = {
24
+ excludeValues?: string[];
25
+ removeFromClass?: string[];
26
+ };
27
+ export declare type IDesignSystemProperty = {
28
+ property: string;
29
+ };
30
+ export declare type IDesignSystemDocs = {
31
+ [key: string]: string | boolean | number;
32
+ };
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ import { IDesignSystemUtilityClassRenderer } from './DesignSystemUtilityClassRenderer.interface';
3
+ export declare const DesignSystemUtilityClassRenderer: React.FC<IDesignSystemUtilityClassRenderer>;
@@ -0,0 +1,4 @@
1
+ import { IDesignSystem } from '../../../../DesignSystem.interface';
2
+ export declare type IDesignSystemUtilityClassRenderer = {
3
+ token: IDesignSystem;
4
+ };
@@ -0,0 +1,2 @@
1
+ export { DesignSystemUtilityClassRenderer } from './DesignSystemUtilityClassRenderer.component';
2
+ export * from './DesignSystemUtilityClassRenderer.interface';
@@ -0,0 +1 @@
1
+ export { DesignSystemUtilityClassRenderer } from './DesignSystemUtilityClassRenderer';
package/dist/esm/index.js CHANGED
@@ -3656,13 +3656,13 @@ var style$T = {"magneto-ui-drawer":"mg_drawer_magneto-ui-drawer_1hxen","magneto-
3656
3656
 
3657
3657
  var DEFAULT_PADDING = 20;
3658
3658
  var Component$22 = function (_a) {
3659
- var _b = _a.className, className = _b === void 0 ? '' : _b, isOpen = _a.isOpen, _c = _a.direction, direction = _c === void 0 ? 'left' : _c, isFull = _a.isFull, customPadding = _a.customPadding, drawerWidth = _a.drawerWidth, isMobile = _a.isMobile, hideButton = _a.hideButton, children = _a.children, onClose = _a.onClose, _d = _a.blockBackgroundClose, blockBackgroundClose = _d === void 0 ? false : _d;
3659
+ var _b = _a.className, className = _b === void 0 ? '' : _b, isOpen = _a.isOpen, _c = _a.direction, direction = _c === void 0 ? 'left' : _c, isFull = _a.isFull, customPadding = _a.customPadding, drawerWidth = _a.drawerWidth, isMobile = _a.isMobile, hideButton = _a.hideButton, children = _a.children, onClose = _a.onClose, _d = _a.blockBackgroundClose, blockBackgroundClose = _d === void 0 ? false : _d, _e = _a.backGroundClassName, backGroundClassName = _e === void 0 ? '' : _e;
3660
3660
  var fullDrawer = isFull ? "full-drawer" : '';
3661
3661
  var paddingValue = customPadding !== undefined ? "".concat(customPadding, "px") : "".concat(DEFAULT_PADDING, "px");
3662
3662
  var backgroundEffect = isMobile ? 'no-background' : 'background-drawer';
3663
3663
  var widthValue = { '--drawer-width': drawerWidth };
3664
- var _e = useState(false), showContent = _e[0], setShowContent = _e[1];
3665
- var _f = useState(isOpen), renderPortal = _f[0], setRenderPortal = _f[1];
3664
+ var _f = useState(false), showContent = _f[0], setShowContent = _f[1];
3665
+ var _g = useState(isOpen), renderPortal = _g[0], setRenderPortal = _g[1];
3666
3666
  var showDrawer = showContent ? "show-".concat(direction) : "hidden-".concat(direction);
3667
3667
  useEffect(function () {
3668
3668
  var body = document.body;
@@ -3696,7 +3696,7 @@ var Component$22 = function (_a) {
3696
3696
  !hideButton && (React.createElement("button", { className: style$T['magneto-ui-close-button'], onClick: onClose },
3697
3697
  React.createElement(IconItem, { icon: Add, hover: false }))),
3698
3698
  children),
3699
- isOpen && (React.createElement("span", { className: "".concat(style$T[backgroundEffect]), onClick: blockBackgroundClose ? function () { return null; } : onClose })))))));
3699
+ isOpen && (React.createElement("span", { className: "".concat(style$T[backgroundEffect], " ").concat(backGroundClassName), onClick: blockBackgroundClose ? function () { return null; } : onClose })))))));
3700
3700
  };
3701
3701
  /**
3702
3702
  * Molecule UI component for Drawer