@grassus/ui-package 1.0.25 → 1.0.26
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/index.js +1 -1
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/types/components/Header/Header.d.ts +3 -4
- package/dist/esm/index.js +1 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/types/components/Header/Header.d.ts +3 -4
- package/dist/index.d.ts +3 -4
- package/package.json +1 -1
package/dist/cjs/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var e=require("react"),t=require("antd");const{
|
|
1
|
+
"use strict";var e=require("react"),t=require("antd");const{Sider:n}=t.Layout,l={height:"100vh",position:"sticky",top:0,overflow:"hidden"},a=e=>({scrollbarGutter:"stable",overflow:e?"auto":"hidden"}),r="menuCollapsed";!function(e,t){void 0===t&&(t={});var n=t.insertAt;if("undefined"!=typeof document){var l=document.head||document.getElementsByTagName("head")[0],a=document.createElement("style");a.type="text/css","top"===n&&l.firstChild?l.insertBefore(a,l.firstChild):l.appendChild(a),a.styleSheet?a.styleSheet.cssText=e:a.appendChild(document.createTextNode(e))}}("button {\r\n /* font-size: 60px; */\r\n}\r\n");exports.Header=({title:n="",metaTitle:l,extra:a,actions:r,gap:o,styles:s})=>(l&&console.log("set",l),e.createElement(t.Layout.Header,{style:(null==s?void 0:s.body)||{}},e.createElement(t.Flex,{align:"center",gap:o,style:{width:"100%"}},a&&e.createElement("div",{style:(null==s?void 0:s.extra)||{}},a),e.createElement(t.Flex,{flex:"1 1 auto",style:Object.assign({overflow:"hidden"},null==s?void 0:s.title)},n),r&&e.createElement("div",{style:(null==s?void 0:s.actions)||{}},r)))),exports.SiderMenu=({collapsed:r,title:o,extra:s,styles:i,loading:c,menuProps:d})=>{const[u,m]=e.useState(!1);let p;return"boolean"==typeof c?p={spinning:c}:"object"==typeof c&&(p=Object.assign({spinning:!0},c)),e.createElement(n,{collapsed:r,style:(null==i?void 0:i.body)||{}},e.createElement(t.Flex,{vertical:!0,style:l},o&&e.createElement(t.Flex,{align:"center",justify:"center",style:(null==i?void 0:i.header)||{}},e.createElement("div",{style:{width:"100%"}},o)),e.createElement(t.Flex,{vertical:!0,flex:"1 1 auto",style:a(u),onMouseEnter:()=>{m(!0)},onMouseLeave:()=>{m(!1)}},e.createElement(t.Spin,Object.assign({spinning:!1},p),e.createElement(t.Menu,Object.assign({},d,{style:(null==i?void 0:i.actions)||{}})))),s&&e.createElement(t.Flex,{style:(null==i?void 0:i.extra)||{}},s)))},exports.StepPreloader=({colorPrimary:t="#1677ff",colorSecondary:n="transparent",count:l=8,delay:a=1.2})=>{const r=e=>({animationDelay:`${.1*e}s`}),o={width:"10px",height:"70px",display:"inline-block",transformOrigin:"bottom center",borderTopRightRadius:"20px",borderTopLeftRadius:"20px",animation:`animationStepPreloader ${a}s linear infinite`,margin:"2px"};return e.createElement("span",null,e.createElement("style",null,`\n @keyframes animationStepPreloader {\n 0% {\n transform: scaleY(0.1);\n background: ${n};\n }\n 50% {\n transform: scaleY(1);\n background: ${t};\n }\n 100% {\n transform: scaleY(0.1);\n background: ${n};\n }\n }\n `),Array.from(Array(l).keys()).map((t=>e.createElement("div",{key:t,style:Object.assign(Object.assign({},o),r(t))}))))},exports.TestInfo=t=>e.createElement("button",null,t.label),exports.useMenuCollapsed=t=>{const[n,l]=e.useState((e=>{const t=window.localStorage.getItem(e);return!!t&&/true/i.test(t)})(t||r));return{menuCollapsed:n,setMenuCollapsed:e=>{l(e),window.localStorage.setItem(t||r,String(e))}}};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
package/dist/cjs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../src/components/Header/Header.tsx","../../src/components/SiderMenu/SiderMenu.tsx","../../src/components/SiderMenu/hooks/useMenuCollapsed.ts","../../node_modules/style-inject/dist/style-inject.es.js","../../src/components/preloaders/StepPreloader/StepPreloader.tsx","../../src/components/TestInfo/TestInfo.tsx"],"sourcesContent":[null,null,null,"function styleInject(css, ref) {\n if ( ref === void 0 ) ref = {};\n var insertAt = ref.insertAt;\n\n if (!css || typeof document === 'undefined') { return; }\n\n var head = document.head || document.getElementsByTagName('head')[0];\n var style = document.createElement('style');\n style.type = 'text/css';\n\n if (insertAt === 'top') {\n if (head.firstChild) {\n head.insertBefore(style, head.firstChild);\n } else {\n head.appendChild(style);\n }\n } else {\n head.appendChild(style);\n }\n\n if (style.styleSheet) {\n style.styleSheet.cssText = css;\n } else {\n style.appendChild(document.createTextNode(css));\n }\n}\n\nexport default styleInject;\n",null,null],"names":["
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../src/components/Header/Header.tsx","../../src/components/SiderMenu/SiderMenu.tsx","../../src/components/SiderMenu/hooks/useMenuCollapsed.ts","../../node_modules/style-inject/dist/style-inject.es.js","../../src/components/preloaders/StepPreloader/StepPreloader.tsx","../../src/components/TestInfo/TestInfo.tsx"],"sourcesContent":[null,null,null,"function styleInject(css, ref) {\n if ( ref === void 0 ) ref = {};\n var insertAt = ref.insertAt;\n\n if (!css || typeof document === 'undefined') { return; }\n\n var head = document.head || document.getElementsByTagName('head')[0];\n var style = document.createElement('style');\n style.type = 'text/css';\n\n if (insertAt === 'top') {\n if (head.firstChild) {\n head.insertBefore(style, head.firstChild);\n } else {\n head.appendChild(style);\n }\n } else {\n head.appendChild(style);\n }\n\n if (style.styleSheet) {\n style.styleSheet.cssText = css;\n } else {\n style.appendChild(document.createTextNode(css));\n }\n}\n\nexport default styleInject;\n",null,null],"names":["Sider","Layout","siderWrapper","height","position","top","overflow","menuWrapper","isHover","scrollbarGutter","defaultMenuName","css","ref","insertAt","document","head","getElementsByTagName","style","createElement","type","firstChild","insertBefore","appendChild","styleSheet","cssText","createTextNode","title","metaTitle","extra","actions","gap","styles","console","log","React","Header","body","Flex","align","width","flex","collapsed","loading","menuProps","setIsHover","useState","spinProps","spinning","vertical","justify","header","onMouseEnter","onMouseLeave","Spin","Object","assign","Menu","colorPrimary","colorSecondary","count","delay","barItem","item","animationDelay","barStyle1","display","transformOrigin","borderTopRightRadius","borderTopLeftRadius","animation","margin","Array","from","keys","map","key","props","label","menuName","menuCollapsed","setMenuCollapsed","sidebarState","window","localStorage","getItem","test","getInitialMenuCollapsedState","value","setItem","String"],"mappings":"sDAmBA,MCdMA,MAAEA,GAAUC,SAkBZC,EAAoC,CACxCC,OAAQ,QACRC,SAAU,SACVC,IAAK,EACLC,SAAU,UAGNC,EAAeC,IACZ,CACLC,gBAAiB,SACjBH,SAAUE,EAAU,OAAS,WC/B3BE,EAAkB,iBCFxB,SAAqBC,EAAKC,QACX,IAARA,IAAiBA,EAAM,CAAA,GAC5B,IAAIC,EAAWD,EAAIC,SAEnB,GAAgC,oBAAbC,SAAnB,CAEA,IAAIC,EAAOD,SAASC,MAAQD,SAASE,qBAAqB,QAAQ,GAC9DC,EAAQH,SAASI,cAAc,SACnCD,EAAME,KAAO,WAEI,QAAbN,GACEE,EAAKK,WACPL,EAAKM,aAAaJ,EAAOF,EAAKK,YAKhCL,EAAKO,YAAYL,GAGfA,EAAMM,WACRN,EAAMM,WAAWC,QAAUb,EAE3BM,EAAMK,YAAYR,SAASW,eAAed,GAnBY,CAqB1D,kEHNe,EAAGe,QAAQ,GAAIC,YAAWC,QAAOC,UAASC,MAAKC,aAExDJ,GAAWK,QAAQC,IAAI,MAAON,GAGhCO,EAAChB,cAAAjB,EAAAA,OAAOkC,QAAOlB,OAAOc,aAAM,EAANA,EAAQK,OAAQ,IACpCF,EAAAhB,cAACmB,OAAK,CAAAC,MAAM,SAASR,IAAKA,EAAKb,MAAO,CAAEsB,MAAO,SAC5CX,GAASM,EAAKhB,cAAA,MAAA,CAAAD,OAAOc,aAAA,EAAAA,EAAQH,QAAS,CAAA,GAAKA,GAE5CM,EAAChB,cAAAmB,EAAIA,MAACG,KAAK,WAAWvB,qBAASX,SAAU,UAAayB,aAAM,EAANA,EAAQL,QA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B,OACrBC,UAAW,0BAA0BT,qBACrCU,OAAQ,OAGV,OACEpC,EAAAhB,cAAA,OAAA,KACEgB,EACGhB,cAAA,QAAA,KAAA,uIAImBwC,wGAIAD,2GAIAC,4CAKrBa,MAAMC,KAAKD,MAAMZ,GAAOc,QAAQC,KAAKZ,GACpC5B,EAAAhB,cAAA,MAAA,CAAKyD,IAAKb,EAAM7C,qCAAY+C,GAAcH,EAAQC,QAGtD,mBC5Ccc,GACT1C,EAAShB,cAAA,SAAA,KAAA0D,EAAMC,gCHOSC,IAC/B,MAAOC,EAAeC,GAAoBnC,EAAAA,SAXP,CAACiC,IACpC,MAAMG,EAAeC,OAAOC,aAAaC,QAAQN,GAEjD,QAAKG,GAIE,QAAQI,KAAKJ,EAAa,EAK/BK,CAA6BR,GAAYpE,IAG3C,MAAO,CACLqE,gBACAC,iBAAmBO,IACjBP,EAAiBO,GACjBL,OAAOC,aAAaK,QAAQV,GAAYpE,EAAiB+E,OAAOF,GAAO,EAE1E","x_google_ignoreList":[3]}
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { SizeType } from 'antd/es/config-provider/SizeContext';
|
|
3
|
-
declare const TITLE_ELE_LIST: readonly [1, 2, 3, 4, 5];
|
|
4
3
|
interface IWrapperHeader {
|
|
5
4
|
actions?: React.ReactNode | undefined;
|
|
6
5
|
extra?: React.ReactNode | undefined;
|
|
7
|
-
title?: string | undefined;
|
|
8
|
-
|
|
6
|
+
title?: React.ReactNode | string | undefined;
|
|
7
|
+
metaTitle?: string | undefined;
|
|
9
8
|
gap?: React.CSSProperties['gap'] | SizeType;
|
|
10
9
|
styles?: {
|
|
11
10
|
actions?: React.CSSProperties;
|
|
@@ -14,5 +13,5 @@ interface IWrapperHeader {
|
|
|
14
13
|
title?: React.CSSProperties;
|
|
15
14
|
};
|
|
16
15
|
}
|
|
17
|
-
declare const Header: ({ title,
|
|
16
|
+
declare const Header: ({ title, metaTitle, extra, actions, gap, styles }: IWrapperHeader) => React.JSX.Element;
|
|
18
17
|
export default Header;
|
package/dist/esm/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import e,{useState as t}from"react";import{Layout as n,Flex as l,
|
|
1
|
+
import e,{useState as t}from"react";import{Layout as n,Flex as l,Spin as a,Menu as o}from"antd";const r=({title:t="",metaTitle:a,extra:o,actions:r,gap:i,styles:s})=>(a&&console.log("set",a),e.createElement(n.Header,{style:(null==s?void 0:s.body)||{}},e.createElement(l,{align:"center",gap:i,style:{width:"100%"}},o&&e.createElement("div",{style:(null==s?void 0:s.extra)||{}},o),e.createElement(l,{flex:"1 1 auto",style:Object.assign({overflow:"hidden"},null==s?void 0:s.title)},t),r&&e.createElement("div",{style:(null==s?void 0:s.actions)||{}},r)))),{Sider:i}=n,s={height:"100vh",position:"sticky",top:0,overflow:"hidden"},c=e=>({scrollbarGutter:"stable",overflow:e?"auto":"hidden"}),d=({collapsed:n,title:r,extra:d,styles:m,loading:u,menuProps:p})=>{const[y,g]=t(!1);let f;return"boolean"==typeof u?f={spinning:u}:"object"==typeof u&&(f=Object.assign({spinning:!0},u)),e.createElement(i,{collapsed:n,style:(null==m?void 0:m.body)||{}},e.createElement(l,{vertical:!0,style:s},r&&e.createElement(l,{align:"center",justify:"center",style:(null==m?void 0:m.header)||{}},e.createElement("div",{style:{width:"100%"}},r)),e.createElement(l,{vertical:!0,flex:"1 1 auto",style:c(y),onMouseEnter:()=>{g(!0)},onMouseLeave:()=>{g(!1)}},e.createElement(a,Object.assign({spinning:!1},f),e.createElement(o,Object.assign({},p,{style:(null==m?void 0:m.actions)||{}})))),d&&e.createElement(l,{style:(null==m?void 0:m.extra)||{}},d)))},m="menuCollapsed",u=e=>{const[n,l]=t((e=>{const t=window.localStorage.getItem(e);return!!t&&/true/i.test(t)})(e||m));return{menuCollapsed:n,setMenuCollapsed:t=>{l(t),window.localStorage.setItem(e||m,String(t))}}};!function(e,t){void 0===t&&(t={});var n=t.insertAt;if("undefined"!=typeof document){var l=document.head||document.getElementsByTagName("head")[0],a=document.createElement("style");a.type="text/css","top"===n&&l.firstChild?l.insertBefore(a,l.firstChild):l.appendChild(a),a.styleSheet?a.styleSheet.cssText=e:a.appendChild(document.createTextNode(e))}}("button {\r\n /* font-size: 60px; */\r\n}\r\n");const p=t=>e.createElement("button",null,t.label),y=({colorPrimary:t="#1677ff",colorSecondary:n="transparent",count:l=8,delay:a=1.2})=>{const o=e=>({animationDelay:`${.1*e}s`}),r={width:"10px",height:"70px",display:"inline-block",transformOrigin:"bottom center",borderTopRightRadius:"20px",borderTopLeftRadius:"20px",animation:`animationStepPreloader ${a}s linear infinite`,margin:"2px"};return e.createElement("span",null,e.createElement("style",null,`\n @keyframes animationStepPreloader {\n 0% {\n transform: scaleY(0.1);\n background: ${n};\n }\n 50% {\n transform: scaleY(1);\n background: ${t};\n }\n 100% {\n transform: scaleY(0.1);\n background: ${n};\n }\n }\n `),Array.from(Array(l).keys()).map((t=>e.createElement("div",{key:t,style:Object.assign(Object.assign({},r),o(t))}))))};export{r as Header,d as SiderMenu,y as StepPreloader,p as TestInfo,u as useMenuCollapsed};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
package/dist/esm/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../src/components/Header/Header.tsx","../../src/components/SiderMenu/SiderMenu.tsx","../../src/components/SiderMenu/hooks/useMenuCollapsed.ts","../../node_modules/style-inject/dist/style-inject.es.js","../../src/components/TestInfo/TestInfo.tsx","../../src/components/preloaders/StepPreloader/StepPreloader.tsx"],"sourcesContent":[null,null,null,"function styleInject(css, ref) {\n if ( ref === void 0 ) ref = {};\n var insertAt = ref.insertAt;\n\n if (!css || typeof document === 'undefined') { return; }\n\n var head = document.head || document.getElementsByTagName('head')[0];\n var style = document.createElement('style');\n style.type = 'text/css';\n\n if (insertAt === 'top') {\n if (head.firstChild) {\n head.insertBefore(style, head.firstChild);\n } else {\n head.appendChild(style);\n }\n } else {\n head.appendChild(style);\n }\n\n if (style.styleSheet) {\n style.styleSheet.cssText = css;\n } else {\n style.appendChild(document.createTextNode(css));\n }\n}\n\nexport default styleInject;\n",null,null],"names":["
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../src/components/Header/Header.tsx","../../src/components/SiderMenu/SiderMenu.tsx","../../src/components/SiderMenu/hooks/useMenuCollapsed.ts","../../node_modules/style-inject/dist/style-inject.es.js","../../src/components/TestInfo/TestInfo.tsx","../../src/components/preloaders/StepPreloader/StepPreloader.tsx"],"sourcesContent":[null,null,null,"function styleInject(css, ref) {\n if ( ref === void 0 ) ref = {};\n var insertAt = ref.insertAt;\n\n if (!css || typeof document === 'undefined') { return; }\n\n var head = document.head || document.getElementsByTagName('head')[0];\n var style = document.createElement('style');\n style.type = 'text/css';\n\n if (insertAt === 'top') {\n if (head.firstChild) {\n head.insertBefore(style, head.firstChild);\n } else {\n head.appendChild(style);\n }\n } else {\n head.appendChild(style);\n }\n\n if (style.styleSheet) {\n style.styleSheet.cssText = css;\n } else {\n style.appendChild(document.createTextNode(css));\n }\n}\n\nexport default styleInject;\n",null,null],"names":["Header","title","metaTitle","extra","actions","gap","styles","console","log","React","createElement","Layout","style","body","Flex","align","width","flex","overflow","Sider","siderWrapper","height","position","top","menuWrapper","isHover","scrollbarGutter","SiderMenu","collapsed","loading","menuProps","setIsHover","useState","spinProps","spinning","vertical","justify","header","onMouseEnter","onMouseLeave","Spin","Object","assign","Menu","defaultMenuName","useMenuCollapsed","menuName","menuCollapsed","setMenuCollapsed","sidebarState","window","localStorage","getItem","test","getInitialMenuCollapsedState","value","setItem","String","css","ref","insertAt","document","head","getElementsByTagName","type","firstChild","insertBefore","appendChild","styleSheet","cssText","createTextNode","TestInfo","props","label","StepPreloader","colorPrimary","colorSecondary","count","delay","barItem","item","animationDelay","barStyle1","display","transformOrigin","borderTopRightRadius","borderTopLeftRadius","animation","margin","Array","from","keys","map","key"],"mappings":"gGAmBA,MAAMA,EAAS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,QAAS,eACTC,gBAAiB,gBACjBC,qBAAsB,OACtBC,oBAAqB,OACrBC,UAAW,0BAA0BT,qBACrCU,OAAQ,OAGV,OACE/E,EAAAC,cAAA,OAAA,KACED,EACGC,cAAA,QAAA,KAAA,uIAImBkE,wGAIAD,2GAIAC,4CAKrBa,MAAMC,KAAKD,MAAMZ,GAAOc,QAAQC,KAAKZ,GACpCvE,EAAAC,cAAA,MAAA,CAAKmF,IAAKb,EAAMpE,qCAAYsE,GAAcH,EAAQC,QAGtD","x_google_ignoreList":[3]}
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { SizeType } from 'antd/es/config-provider/SizeContext';
|
|
3
|
-
declare const TITLE_ELE_LIST: readonly [1, 2, 3, 4, 5];
|
|
4
3
|
interface IWrapperHeader {
|
|
5
4
|
actions?: React.ReactNode | undefined;
|
|
6
5
|
extra?: React.ReactNode | undefined;
|
|
7
|
-
title?: string | undefined;
|
|
8
|
-
|
|
6
|
+
title?: React.ReactNode | string | undefined;
|
|
7
|
+
metaTitle?: string | undefined;
|
|
9
8
|
gap?: React.CSSProperties['gap'] | SizeType;
|
|
10
9
|
styles?: {
|
|
11
10
|
actions?: React.CSSProperties;
|
|
@@ -14,5 +13,5 @@ interface IWrapperHeader {
|
|
|
14
13
|
title?: React.CSSProperties;
|
|
15
14
|
};
|
|
16
15
|
}
|
|
17
|
-
declare const Header: ({ title,
|
|
16
|
+
declare const Header: ({ title, metaTitle, extra, actions, gap, styles }: IWrapperHeader) => React.JSX.Element;
|
|
18
17
|
export default Header;
|
package/dist/index.d.ts
CHANGED
|
@@ -3,12 +3,11 @@ import { SizeType } from 'antd/es/config-provider/SizeContext';
|
|
|
3
3
|
import { MenuProps } from 'antd/lib/menu/menu';
|
|
4
4
|
import { SpinProps } from 'antd/lib/spin';
|
|
5
5
|
|
|
6
|
-
declare const TITLE_ELE_LIST: readonly [1, 2, 3, 4, 5];
|
|
7
6
|
interface IWrapperHeader {
|
|
8
7
|
actions?: React.ReactNode | undefined;
|
|
9
8
|
extra?: React.ReactNode | undefined;
|
|
10
|
-
title?: string | undefined;
|
|
11
|
-
|
|
9
|
+
title?: React.ReactNode | string | undefined;
|
|
10
|
+
metaTitle?: string | undefined;
|
|
12
11
|
gap?: React.CSSProperties['gap'] | SizeType;
|
|
13
12
|
styles?: {
|
|
14
13
|
actions?: React.CSSProperties;
|
|
@@ -17,7 +16,7 @@ interface IWrapperHeader {
|
|
|
17
16
|
title?: React.CSSProperties;
|
|
18
17
|
};
|
|
19
18
|
}
|
|
20
|
-
declare const Header: ({ title,
|
|
19
|
+
declare const Header: ({ title, metaTitle, extra, actions, gap, styles }: IWrapperHeader) => React.JSX.Element;
|
|
21
20
|
|
|
22
21
|
interface ISideMenu {
|
|
23
22
|
menuProps: MenuProps;
|