hisd3-ui-kit 3.0.0 → 4.0.0
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/README.md +118 -78
- package/dist/index.cjs.js +485 -93
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +211 -22
- package/dist/index.js +485 -93
- package/dist/index.js.map +1 -1
- package/package.json +7 -8
package/dist/index.cjs.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
"use strict";var e=require("react/jsx-runtime"),t=require("
|
|
1
|
+
"use strict";var e=require("react/jsx-runtime"),t=require("antd"),r=require("react"),n=require("styled-components"),o=require("@ant-design/icons");function i(e,t){void 0===t&&(t={});var r=t.insertAt;if(e&&"undefined"!=typeof document){var n=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css","top"===r&&n.firstChild?n.insertBefore(o,n.firstChild):n.appendChild(o),o.styleSheet?o.styleSheet.cssText=e:o.appendChild(document.createTextNode(e))}}i('body,html{height:100%;width:100%}input::-ms-clear,input::-ms-reveal{display:none}*,:after,:before{box-sizing:border-box}html{-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%;-ms-overflow-style:scrollbar;-webkit-tap-highlight-color:rgba(0,0,0,0);font-family:sans-serif;line-height:1.15}body{margin:0}[tabindex="-1"]:focus{outline:none}hr{box-sizing:content-box;height:0;overflow:visible}h1,h2,h3,h4,h5,h6{font-weight:500;margin-bottom:.5em;margin-top:0}p{margin-bottom:1em;margin-top:0}abbr[data-original-title],abbr[title]{border-bottom:0;cursor:help;-webkit-text-decoration:underline dotted;text-decoration:underline dotted}address{font-style:normal;line-height:inherit;margin-bottom:1em}input[type=number],input[type=password],input[type=text],textarea{-webkit-appearance:none}dl,ol,ul{margin-bottom:1em;margin-top:0}ol ol,ol ul,ul ol,ul ul{margin-bottom:0}dt{font-weight:500}dd{margin-bottom:.5em;margin-left:0}blockquote{margin:0 0 1em}dfn{font-style:italic}b,strong{font-weight:bolder}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}code,kbd,pre,samp{font-family:SFMono-Regular,Consolas,Liberation Mono,Menlo,Courier,monospace;font-size:1em}pre{margin-bottom:1em;margin-top:0;overflow:auto}figure{margin:0 0 1em}img{border-style:none;vertical-align:middle}[role=button],a,area,button,input:not([type=range]),label,select,summary,textarea{touch-action:manipulation}table{border-collapse:collapse}caption{caption-side:bottom;padding-bottom:.3em;padding-top:.75em;text-align:left}button,input,optgroup,select,textarea{color:inherit;font-family:inherit;font-size:inherit;line-height:inherit;margin:0}button,input{overflow:visible}button,select{text-transform:none}[type=reset],[type=submit],button,html [type=button]{-webkit-appearance:button}[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,[type=submit]::-moz-focus-inner,button::-moz-focus-inner{border-style:none;padding:0}input[type=checkbox],input[type=radio]{box-sizing:border-box;padding:0}input[type=date],input[type=datetime-local],input[type=month],input[type=time]{-webkit-appearance:listbox}textarea{overflow:auto;resize:vertical}fieldset{border:0;margin:0;min-width:0;padding:0}legend{color:inherit;display:block;font-size:1.5em;line-height:inherit;margin-bottom:.5em;max-width:100%;padding:0;white-space:normal;width:100%}progress{vertical-align:baseline}[type=number]::-webkit-inner-spin-button,[type=number]::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:none;outline-offset:-2px}[type=search]::-webkit-search-cancel-button,[type=search]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}output{display:inline-block}summary{display:list-item}template{display:none}[hidden]{display:none!important}');i('@import url("https://fonts.googleapis.com/css2?family=Archivo:ital,wght@0,400;0,500;0,600;0,700;0,800;1,400&display=swap");:root{--font-body:"Archivo",-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;--font-heading:var(--font-body);--font-weight-heading:800}body{-webkit-font-smoothing:antialiased;font-family:var(--font-body)}.ant-typography h1,.ant-typography h2,.ant-typography h3,.ant-typography h4,.ant-typography h5,h1,h2,h3,h4,h5,h6{font-family:var(--font-heading);font-weight:var(--font-weight-heading);letter-spacing:-.01em}');const a={red:"#E5401C",orange:"#F26B1D",teal:"#00796B",blue:"#1D5FD1",green:"#2E7D32",purple:"#6A3FD6"},l={bgLayout:"#F3F2F0",bgContainer:"#F3F2F0",bgElevated:"#FFFFFF",bgFilled:"#E6E4E1",text:"#171717",textSecondary:"#4A4A4A",textTertiary:"#6E6E6E",border:"#1F1F1F",borderSecondary:"#CFCDC9",white:"#FFFFFF"},s="'Archivo', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif",d=(e="red")=>a[e]??e,p=(e,t)=>{const r=e.replace("#",""),n=3===r.length?r.split("").map((e=>e+e)).join(""):r,o=parseInt(n,16),i=o>>8&255,a=255&o,l=e=>Math.round(e+(255-e)*t);return`#${[l(o>>16&255),l(i),l(a)].map((e=>e.toString(16).padStart(2,"0"))).join("")}`},c=({primary:e,radius:t=0,lineWidth:r=2,overrides:n}={})=>{const o=d(e),i=l,a={cssVar:{key:"hisd3"},token:{colorPrimary:o,colorInfo:o,colorLink:o,colorPrimaryBg:p(o,.92),colorPrimaryBgHover:p(o,.86),colorPrimaryBorder:p(o,.6),fontFamily:s,fontSize:14,fontWeightStrong:700,borderRadius:t,borderRadiusLG:t,borderRadiusSM:t,borderRadiusXS:t,lineWidth:r,colorBgLayout:i.bgLayout,colorBgContainer:i.bgContainer,colorBgElevated:i.bgElevated,colorText:i.text,colorTextSecondary:i.textSecondary,colorTextTertiary:i.textTertiary,colorTextHeading:i.text,colorBorder:i.border,colorBorderSecondary:i.borderSecondary,colorSplit:i.borderSecondary,controlHeight:40,controlHeightLG:52,controlHeightSM:32,boxShadow:"none",boxShadowSecondary:"0 8px 24px rgba(0,0,0,0.12)"},components:{Layout:{siderBg:i.bgLayout,headerBg:i.bgLayout,bodyBg:i.bgLayout,headerPadding:"0 48px"},Menu:{itemBg:"transparent",subMenuItemBg:"transparent",itemColor:i.text,itemHoverColor:i.text,itemHoverBg:"rgba(0,0,0,0.04)",itemSelectedBg:p(o,.9),itemSelectedColor:o,itemActiveBg:p(o,.86),subMenuItemSelectedColor:o,groupTitleColor:i.textTertiary,groupTitleFontSize:12,itemBorderRadius:0,itemMarginInline:0,itemMarginBlock:0,itemHeight:46,itemPaddingInline:24,iconSize:18,collapsedIconSize:18,activeBarBorderWidth:0,activeBarWidth:0},Button:{fontWeight:600,primaryShadow:"none",defaultShadow:"none",dangerShadow:"none",defaultBorderColor:i.border,defaultColor:i.text,defaultBg:i.bgLayout,defaultHoverBg:i.white,defaultHoverBorderColor:i.border,defaultHoverColor:i.text,defaultActiveBorderColor:i.border,paddingInline:20,contentFontSizeLG:16},Input:{activeShadow:"none",colorBorder:i.borderSecondary,hoverBorderColor:i.border,activeBorderColor:i.border,paddingInline:16},Select:{optionSelectedBg:p(o,.9),colorBorder:i.borderSecondary},Table:{headerBg:"transparent",headerColor:i.textTertiary,headerSplitColor:"transparent",headerBorderRadius:0,borderColor:i.borderSecondary,rowHoverBg:"rgba(0,0,0,0.03)",cellPaddingBlock:20,cellPaddingInline:16,cellFontSize:16,footerBg:"transparent"},Tabs:{inkBarColor:o,itemColor:i.text,itemSelectedColor:o,itemHoverColor:o,titleFontSize:18,horizontalItemGutter:48,horizontalMargin:"0",lineWidthBold:4},Tag:{borderRadiusSM:0,defaultBg:"transparent"},Pagination:{itemBg:i.bgLayout,itemActiveBg:o,itemSize:48,itemInputBg:i.bgLayout},Dropdown:{paddingBlock:10},Breadcrumb:{itemColor:i.textTertiary,lastItemColor:i.text,linkColor:i.textTertiary,linkHoverColor:o,separatorColor:i.textTertiary},Card:{headerFontSize:20}}};return n?{...a,...n,token:{...a.token,...n.token},components:{...a.components,...n.components}}:a},h=c(),g={primary:a.red,primaryLight:p(a.red,.9),headerSelectedBg:"rgba(0,0,0,0.04)"},u=r.createContext(!1),x=()=>r.useContext(u),m={siderWidth:280,siderCollapsedWidth:72,topBarHeight:88,pageGutter:40},{Header:b,Content:y}=t.Layout,f=m.siderWidth,v=m.siderCollapsedWidth,w=m.topBarHeight,S=n(t.Layout)`
|
|
2
2
|
min-height: 100vh;
|
|
3
|
+
background: var(--ant-color-bg-layout);
|
|
3
4
|
|
|
4
5
|
/*
|
|
5
6
|
* The Sider is rendered as a plain antd <Sider> (not styled(Sider)) because
|
|
@@ -10,8 +11,8 @@
|
|
|
10
11
|
top: 0;
|
|
11
12
|
height: 100vh;
|
|
12
13
|
overflow: hidden;
|
|
13
|
-
|
|
14
|
-
|
|
14
|
+
background: var(--ant-color-bg-layout);
|
|
15
|
+
border-right: 2px solid var(--ant-color-border);
|
|
15
16
|
|
|
16
17
|
.ant-layout-sider-children {
|
|
17
18
|
display: flex;
|
|
@@ -19,177 +20,568 @@
|
|
|
19
20
|
height: 100%;
|
|
20
21
|
}
|
|
21
22
|
}
|
|
22
|
-
`,
|
|
23
|
+
`,I=n.div`
|
|
23
24
|
flex: 1 1 auto;
|
|
24
25
|
overflow-y: auto;
|
|
25
26
|
overflow-x: hidden;
|
|
27
|
+
padding-top: 8px;
|
|
26
28
|
|
|
27
29
|
.ant-menu-inline,
|
|
28
30
|
.ant-menu-vertical {
|
|
29
31
|
border-inline-end: none !important;
|
|
32
|
+
background: transparent;
|
|
30
33
|
}
|
|
31
|
-
|
|
34
|
+
|
|
35
|
+
/* Section titles: "RECEIVABLES AND COLLECTIONS" */
|
|
36
|
+
.ant-menu-item-group-title {
|
|
37
|
+
padding: 22px 24px 8px;
|
|
38
|
+
font-size: 12px;
|
|
39
|
+
font-weight: 600;
|
|
40
|
+
letter-spacing: 0.14em;
|
|
41
|
+
text-transform: uppercase;
|
|
42
|
+
color: var(--ant-color-text-tertiary);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.ant-menu-item-group + .ant-menu-item-group > .ant-menu-item-group-title,
|
|
46
|
+
.ant-menu-item-group + .ant-menu-item-group::before {
|
|
47
|
+
border-top: 2px solid var(--ant-color-border-secondary);
|
|
48
|
+
margin-top: 12px;
|
|
49
|
+
padding-top: 26px;
|
|
50
|
+
}
|
|
51
|
+
.ant-menu-item-group + .ant-menu-item-group::before {
|
|
52
|
+
content: none;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.ant-menu-item,
|
|
56
|
+
.ant-menu-submenu-title {
|
|
57
|
+
font-size: 17px;
|
|
58
|
+
font-weight: 500;
|
|
59
|
+
position: relative;
|
|
60
|
+
width: 100%;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.ant-menu-item .ant-menu-item-icon,
|
|
64
|
+
.ant-menu-submenu-title .ant-menu-item-icon {
|
|
65
|
+
font-size: 18px;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
/* open parent ("Billing") in primary */
|
|
69
|
+
.ant-menu-submenu-open > .ant-menu-submenu-title,
|
|
70
|
+
.ant-menu-submenu-selected > .ant-menu-submenu-title {
|
|
71
|
+
color: var(--ant-color-primary);
|
|
72
|
+
font-weight: 700;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
/* child items are indented by antd; keep them slightly smaller */
|
|
76
|
+
.ant-menu-sub.ant-menu-inline > .ant-menu-item {
|
|
77
|
+
font-size: 16px;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
/* active item: tint + 4px accent bar */
|
|
81
|
+
.ant-menu-item-selected {
|
|
82
|
+
font-weight: 700;
|
|
83
|
+
|
|
84
|
+
&::before {
|
|
85
|
+
content: "";
|
|
86
|
+
position: absolute;
|
|
87
|
+
left: 0;
|
|
88
|
+
top: 0;
|
|
89
|
+
bottom: 0;
|
|
90
|
+
width: 5px;
|
|
91
|
+
background: var(--ant-color-primary);
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
&.hisd3-collapsed .ant-menu-item-group-title {
|
|
96
|
+
display: none;
|
|
97
|
+
}
|
|
98
|
+
`,T=n.a`
|
|
32
99
|
display: flex;
|
|
33
100
|
align-items: center;
|
|
34
|
-
gap:
|
|
35
|
-
height: ${
|
|
36
|
-
padding: 0 ${({$collapsed:e})=>e?
|
|
101
|
+
gap: 16px;
|
|
102
|
+
height: ${w}px;
|
|
103
|
+
padding: 0 ${({$collapsed:e})=>e?14:24}px;
|
|
37
104
|
justify-content: ${({$collapsed:e})=>e?"center":"flex-start"};
|
|
38
105
|
color: inherit;
|
|
39
106
|
text-decoration: none;
|
|
40
107
|
overflow: hidden;
|
|
41
108
|
white-space: nowrap;
|
|
42
109
|
flex: 0 0 auto;
|
|
110
|
+
border-bottom: 2px solid var(--ant-color-border);
|
|
111
|
+
|
|
112
|
+
.hisd3-brand-mark {
|
|
113
|
+
width: 40px;
|
|
114
|
+
height: 40px;
|
|
115
|
+
flex: 0 0 auto;
|
|
116
|
+
background: var(--ant-color-primary);
|
|
117
|
+
display: flex;
|
|
118
|
+
align-items: center;
|
|
119
|
+
justify-content: center;
|
|
120
|
+
}
|
|
43
121
|
|
|
44
122
|
img {
|
|
45
|
-
height:
|
|
46
|
-
width:
|
|
123
|
+
height: 40px;
|
|
124
|
+
width: 40px;
|
|
47
125
|
object-fit: contain;
|
|
48
126
|
flex: 0 0 auto;
|
|
49
127
|
}
|
|
50
128
|
|
|
51
129
|
h1 {
|
|
52
130
|
margin: 0;
|
|
53
|
-
font-
|
|
54
|
-
font-
|
|
55
|
-
|
|
131
|
+
font-family: var(--font-heading);
|
|
132
|
+
font-size: 22px;
|
|
133
|
+
font-weight: var(--font-weight-heading, 800);
|
|
134
|
+
letter-spacing: 0.04em;
|
|
135
|
+
text-transform: uppercase;
|
|
136
|
+
color: var(--ant-color-text);
|
|
56
137
|
overflow: hidden;
|
|
57
138
|
text-overflow: ellipsis;
|
|
58
139
|
}
|
|
59
|
-
`,
|
|
140
|
+
`,D=n(b)`
|
|
60
141
|
display: flex;
|
|
61
142
|
align-items: center;
|
|
62
|
-
gap:
|
|
63
|
-
height: ${
|
|
64
|
-
line-height: ${
|
|
65
|
-
padding: 0
|
|
143
|
+
gap: 24px;
|
|
144
|
+
height: ${w}px;
|
|
145
|
+
line-height: ${w}px;
|
|
146
|
+
padding: 0 ${m.pageGutter}px;
|
|
66
147
|
position: sticky;
|
|
67
148
|
top: 0;
|
|
68
149
|
z-index: 100;
|
|
69
|
-
|
|
70
|
-
|
|
150
|
+
background: var(--ant-color-bg-layout);
|
|
151
|
+
border-bottom: 2px solid var(--ant-color-border);
|
|
71
152
|
|
|
72
153
|
.ant-menu-horizontal {
|
|
73
154
|
flex: 1 1 auto;
|
|
74
155
|
min-width: 0;
|
|
75
156
|
border-bottom: none;
|
|
76
|
-
|
|
157
|
+
background: transparent;
|
|
158
|
+
line-height: ${w-2}px;
|
|
159
|
+
font-size: 16px;
|
|
160
|
+
font-weight: 500;
|
|
77
161
|
}
|
|
78
|
-
`,
|
|
162
|
+
`,E=n(b)`
|
|
79
163
|
display: flex;
|
|
80
164
|
align-items: center;
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
165
|
+
gap: 16px;
|
|
166
|
+
height: ${w}px;
|
|
167
|
+
line-height: ${w}px;
|
|
168
|
+
padding: 0 ${m.pageGutter}px;
|
|
84
169
|
position: sticky;
|
|
85
170
|
top: 0;
|
|
86
171
|
z-index: 99;
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
`,
|
|
90
|
-
border:
|
|
172
|
+
background: var(--ant-color-bg-layout);
|
|
173
|
+
border-bottom: 2px solid var(--ant-color-border);
|
|
174
|
+
`,k=n.button`
|
|
175
|
+
border: 2px solid var(--ant-color-border);
|
|
91
176
|
background: transparent;
|
|
92
177
|
cursor: pointer;
|
|
93
178
|
font-size: 16px;
|
|
94
|
-
|
|
95
|
-
|
|
179
|
+
width: 40px;
|
|
180
|
+
height: 40px;
|
|
96
181
|
color: inherit;
|
|
97
182
|
display: inline-flex;
|
|
98
183
|
align-items: center;
|
|
184
|
+
justify-content: center;
|
|
185
|
+
flex: 0 0 auto;
|
|
99
186
|
|
|
100
187
|
&:hover {
|
|
101
|
-
background: rgba(0, 0, 0, 0.
|
|
102
|
-
}
|
|
103
|
-
`,g=o(l)`
|
|
104
|
-
padding: 24px;
|
|
105
|
-
min-height: calc(100vh - ${d}px);
|
|
106
|
-
`;o(i.List)`
|
|
107
|
-
& .ant-list-item {
|
|
108
|
-
padding: 5px 12px;
|
|
109
|
-
cursor: pointer;
|
|
188
|
+
background: rgba(0, 0, 0, 0.05);
|
|
110
189
|
}
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
190
|
+
`,C=n(y)`
|
|
191
|
+
padding: 32px ${m.pageGutter}px 48px;
|
|
192
|
+
min-height: calc(100vh - ${w}px);
|
|
193
|
+
`,L=n.div`
|
|
194
|
+
flex: 0 0 auto;
|
|
116
195
|
display: flex;
|
|
117
196
|
flex-direction: column;
|
|
118
197
|
justify-content: center;
|
|
198
|
+
line-height: 1.25;
|
|
119
199
|
transition: all 0.2s ease;
|
|
120
|
-
|
|
121
|
-
min-width: ${({$inHeader:e
|
|
122
|
-
border-top: ${({$inHeader:e
|
|
123
|
-
|
|
124
|
-
@media screen and (min-width: ${({theme:e})=>e?.breakpoints?.md||768}px) {
|
|
125
|
-
${({$inHeader:e})=>e?"":"padding-top: 10px; padding-bottom: 10px; min-height: 71px;"}
|
|
126
|
-
}
|
|
200
|
+
padding: ${({$inHeader:e,$collapsed:t})=>e?"0 4px":t?"16px 0":"20px 24px"};
|
|
201
|
+
min-width: ${({$inHeader:e})=>e?"220px":"0"};
|
|
202
|
+
border-top: ${({$inHeader:e})=>e?"none":"2px solid var(--ant-color-border)"};
|
|
127
203
|
|
|
128
204
|
& .ant-dropdown-link {
|
|
129
205
|
color: inherit;
|
|
130
|
-
|
|
131
|
-
& .anticon {
|
|
132
|
-
font-size: ${({theme:e})=>e?.font?.size?.sm||"14px"};
|
|
133
|
-
}
|
|
134
206
|
}
|
|
135
|
-
`,
|
|
207
|
+
`,j=n.a`
|
|
136
208
|
display: flex;
|
|
137
209
|
align-items: center;
|
|
210
|
+
justify-content: center;
|
|
138
211
|
cursor: pointer;
|
|
139
212
|
color: inherit;
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
213
|
+
gap: 16px;
|
|
214
|
+
`,A=n.span`
|
|
215
|
+
width: 48px;
|
|
216
|
+
height: 48px;
|
|
217
|
+
flex: 0 0 auto;
|
|
145
218
|
display: flex;
|
|
146
219
|
align-items: center;
|
|
147
220
|
justify-content: center;
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
221
|
+
font-size: 16px;
|
|
222
|
+
font-weight: 700;
|
|
223
|
+
color: var(--ant-color-text);
|
|
224
|
+
background: ${({$src:e})=>e?`center / cover no-repeat url("${e}")`:"#D9D6D2"};
|
|
225
|
+
`,O=n.span`
|
|
226
|
+
flex: 1 1 auto;
|
|
153
227
|
min-width: 0;
|
|
154
|
-
|
|
155
|
-
[dir="rtl"] & {
|
|
156
|
-
margin-left: 0;
|
|
157
|
-
margin-right: 16px;
|
|
158
|
-
}
|
|
159
|
-
`,w=o.span`
|
|
228
|
+
`,R=n.span`
|
|
160
229
|
display: flex;
|
|
161
|
-
align-items:
|
|
230
|
+
align-items: flex-start;
|
|
162
231
|
justify-content: space-between;
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
font-
|
|
167
|
-
|
|
232
|
+
gap: 8px;
|
|
233
|
+
`,z=n.h3`
|
|
234
|
+
margin: 0;
|
|
235
|
+
font-family: var(--font-body);
|
|
236
|
+
font-size: 17px;
|
|
237
|
+
font-weight: 700;
|
|
238
|
+
letter-spacing: 0;
|
|
239
|
+
color: var(--ant-color-text);
|
|
168
240
|
overflow: hidden;
|
|
169
241
|
text-overflow: ellipsis;
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
242
|
+
display: -webkit-box;
|
|
243
|
+
-webkit-line-clamp: 2;
|
|
244
|
+
-webkit-box-orient: vertical;
|
|
245
|
+
`,B=n.span`
|
|
246
|
+
width: 20px;
|
|
247
|
+
height: 22px;
|
|
174
248
|
display: flex;
|
|
175
249
|
align-items: center;
|
|
176
250
|
justify-content: center;
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
margin-left: 0;
|
|
180
|
-
margin-right: 12px;
|
|
181
|
-
}
|
|
251
|
+
flex: 0 0 auto;
|
|
252
|
+
color: var(--ant-color-text);
|
|
182
253
|
|
|
183
254
|
& svg {
|
|
184
255
|
display: block;
|
|
185
256
|
}
|
|
186
|
-
`,
|
|
257
|
+
`,H=n.span`
|
|
187
258
|
display: block;
|
|
188
|
-
margin-top:
|
|
189
|
-
|
|
190
|
-
font-
|
|
259
|
+
margin-top: 4px;
|
|
260
|
+
font-size: 12px;
|
|
261
|
+
font-weight: 500;
|
|
262
|
+
letter-spacing: 0.12em;
|
|
263
|
+
text-transform: uppercase;
|
|
264
|
+
color: var(--ant-color-text-tertiary);
|
|
191
265
|
overflow: hidden;
|
|
192
266
|
text-overflow: ellipsis;
|
|
193
267
|
white-space: nowrap;
|
|
194
|
-
`,
|
|
268
|
+
`,N=(e,t)=>e.key??e.path??`menu-${t}`,F=(e,t)=>(e??[]).filter((e=>e&&!e.hideInMenu)).map(((e,r)=>{const n=N(e,r);return Array.isArray(e.children)&&e.children.length>0?{key:n,icon:e.icon,label:e.name,disabled:e.disabled,type:e.group?"group":void 0,children:F(e.children,t)}:{key:n,icon:e.icon,disabled:e.disabled,label:t(e,e.name)}})),U=(e,t)=>r.createElement("a",{href:e.path||"/"},t),M=({account:r,avatarSrc:n,settingsUrl:i,onLogout:a,collapsed:l=!1,placement:s="topRight",extraItems:d=[]})=>{const{modal:p}=t.App.useApp(),c=[...d??[],{key:"settings",icon:e.jsx(o.SettingOutlined,{}),label:"Settings",onClick:()=>{window.location.href=i??"/settings"}},{key:"logout",icon:e.jsx(o.LogoutOutlined,{}),label:"Logout",onClick:()=>{p.confirm({title:"Are you sure you want to logout?",content:"Please click OK to continue",icon:e.jsx(o.ExclamationCircleOutlined,{}),onOk:a})}}],h=(r.fullName||"").replace(/\(.*?\)/g," ").split(/[\s,]+/).map((e=>e.replace(/[^\p{L}\p{N}]/gu,""))).filter(Boolean).slice(0,2).map((e=>e[0].toUpperCase())).join("")||"?";return e.jsx(L,{className:"cr-user-info-light",$collapsed:l,$inHeader:"bottomRight"===s,children:e.jsx(t.Dropdown,{trigger:["click"],placement:s,menu:{items:c},children:e.jsxs(j,{className:"ant-dropdown-link",onClick:e=>e.preventDefault(),children:[e.jsx(A,{$src:n,"aria-hidden":!0,children:!n&&h}),!l&&e.jsxs(O,{children:[e.jsxs(R,{children:[e.jsx(z,{title:r.fullName,children:r.fullName}),e.jsx(B,{children:e.jsx(o.DownOutlined,{})})]}),r.positionType&&e.jsx(H,{title:r.positionType,children:r.positionType})]})]})})})},{Sider:$}=t.Layout,_=m.pageGutter,P=n.div`
|
|
269
|
+
display: flex;
|
|
270
|
+
align-items: center;
|
|
271
|
+
gap: 24px;
|
|
272
|
+
height: ${m.topBarHeight}px; /* same as the sidebar brand block */
|
|
273
|
+
padding: 0 ${_}px;
|
|
274
|
+
border-bottom: 2px solid var(--ant-color-border);
|
|
275
|
+
background: var(--ant-color-bg-layout);
|
|
276
|
+
position: sticky;
|
|
277
|
+
top: 0;
|
|
278
|
+
z-index: 20;
|
|
279
|
+
|
|
280
|
+
.ant-breadcrumb {
|
|
281
|
+
font-size: 16px;
|
|
282
|
+
flex: 1 1 auto;
|
|
283
|
+
min-width: 0;
|
|
284
|
+
}
|
|
285
|
+
|
|
286
|
+
.ant-breadcrumb ol {
|
|
287
|
+
flex-wrap: nowrap;
|
|
288
|
+
}
|
|
289
|
+
`,W=n.div`
|
|
290
|
+
display: flex;
|
|
291
|
+
align-items: center;
|
|
292
|
+
gap: 16px;
|
|
293
|
+
flex: 0 0 auto;
|
|
294
|
+
`,G=n.div`
|
|
295
|
+
display: flex;
|
|
296
|
+
align-items: baseline;
|
|
297
|
+
gap: 24px;
|
|
298
|
+
flex-wrap: wrap;
|
|
299
|
+
padding: 36px ${_}px 28px;
|
|
300
|
+
border-bottom: 2px solid var(--ant-color-border-secondary);
|
|
301
|
+
|
|
302
|
+
h1 {
|
|
303
|
+
margin: 0;
|
|
304
|
+
font-family: var(--font-heading);
|
|
305
|
+
font-size: 56px;
|
|
306
|
+
line-height: 1.05;
|
|
307
|
+
font-weight: var(--font-weight-heading, 800);
|
|
308
|
+
letter-spacing: -0.02em;
|
|
309
|
+
color: var(--ant-color-text);
|
|
310
|
+
}
|
|
311
|
+
|
|
312
|
+
p {
|
|
313
|
+
margin: 0;
|
|
314
|
+
font-size: 20px;
|
|
315
|
+
color: var(--ant-color-text-secondary);
|
|
316
|
+
}
|
|
317
|
+
`,K=n.div`
|
|
318
|
+
padding: 32px ${_}px 48px;
|
|
319
|
+
`,q=n.div`
|
|
320
|
+
.ant-table-wrapper .ant-table {
|
|
321
|
+
background: transparent;
|
|
322
|
+
}
|
|
323
|
+
|
|
324
|
+
.ant-table-wrapper .ant-table-thead > tr > th {
|
|
325
|
+
font-size: 13px;
|
|
326
|
+
font-weight: 700;
|
|
327
|
+
letter-spacing: 0.1em;
|
|
328
|
+
text-transform: uppercase;
|
|
329
|
+
color: var(--ant-color-text-tertiary);
|
|
330
|
+
padding-block: 14px;
|
|
331
|
+
border-bottom: 2px solid var(--ant-color-border);
|
|
332
|
+
background: transparent;
|
|
333
|
+
}
|
|
334
|
+
|
|
335
|
+
.ant-table-wrapper .ant-table-tbody > tr > td {
|
|
336
|
+
border-bottom: 2px solid var(--ant-color-border-secondary);
|
|
337
|
+
font-size: 16px;
|
|
338
|
+
}
|
|
339
|
+
|
|
340
|
+
.ant-table-wrapper .ant-table-tbody > tr:last-child > td {
|
|
341
|
+
border-bottom: 2px solid var(--ant-color-border);
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
.ant-table-wrapper .ant-table-thead > tr > th:first-child,
|
|
345
|
+
.ant-table-wrapper .ant-table-tbody > tr > td:first-child {
|
|
346
|
+
padding-left: 0;
|
|
347
|
+
}
|
|
348
|
+
|
|
349
|
+
.ant-table-wrapper .ant-table-thead > tr > th:last-child,
|
|
350
|
+
.ant-table-wrapper .ant-table-tbody > tr > td:last-child {
|
|
351
|
+
padding-right: 0;
|
|
352
|
+
}
|
|
353
|
+
|
|
354
|
+
.ant-table-wrapper .ant-table-cell-row-hover {
|
|
355
|
+
background: rgba(0, 0, 0, 0.025) !important;
|
|
356
|
+
}
|
|
357
|
+
|
|
358
|
+
/* Highlighted / linked cell text, e.g. bill numbers */
|
|
359
|
+
.hisd3-cell-primary {
|
|
360
|
+
color: var(--ant-color-primary);
|
|
361
|
+
font-weight: 700;
|
|
362
|
+
}
|
|
363
|
+
.hisd3-cell-link {
|
|
364
|
+
color: var(--ant-color-primary);
|
|
365
|
+
}
|
|
366
|
+
.hisd3-cell-muted {
|
|
367
|
+
color: var(--ant-color-text-tertiary);
|
|
368
|
+
}
|
|
369
|
+
`,X=n.div`
|
|
370
|
+
padding: 22px 0 14px;
|
|
371
|
+
font-size: 13px;
|
|
372
|
+
font-weight: 600;
|
|
373
|
+
letter-spacing: 0.1em;
|
|
374
|
+
text-transform: uppercase;
|
|
375
|
+
color: var(--ant-color-text-tertiary);
|
|
376
|
+
`,V=n.div`
|
|
377
|
+
display: flex;
|
|
378
|
+
align-items: center;
|
|
379
|
+
gap: 24px;
|
|
380
|
+
padding: 20px 0 8px;
|
|
381
|
+
|
|
382
|
+
.hisd3-total {
|
|
383
|
+
flex: 1 1 auto;
|
|
384
|
+
font-size: 16px;
|
|
385
|
+
color: var(--ant-color-text-secondary);
|
|
386
|
+
}
|
|
387
|
+
|
|
388
|
+
.ant-pagination {
|
|
389
|
+
display: inline-flex;
|
|
390
|
+
border: 2px solid var(--ant-color-border);
|
|
391
|
+
|
|
392
|
+
.ant-pagination-item,
|
|
393
|
+
.ant-pagination-prev,
|
|
394
|
+
.ant-pagination-next,
|
|
395
|
+
.ant-pagination-jump-prev,
|
|
396
|
+
.ant-pagination-jump-next {
|
|
397
|
+
margin: 0;
|
|
398
|
+
min-width: 56px;
|
|
399
|
+
height: 56px;
|
|
400
|
+
line-height: 56px;
|
|
401
|
+
border: 0;
|
|
402
|
+
border-right: 2px solid var(--ant-color-border);
|
|
403
|
+
border-radius: 0;
|
|
404
|
+
font-weight: 700;
|
|
405
|
+
font-size: 16px;
|
|
406
|
+
background: transparent;
|
|
407
|
+
|
|
408
|
+
&:last-child {
|
|
409
|
+
border-right: 0;
|
|
410
|
+
}
|
|
411
|
+
|
|
412
|
+
a {
|
|
413
|
+
color: var(--ant-color-text);
|
|
414
|
+
}
|
|
415
|
+
}
|
|
416
|
+
|
|
417
|
+
.ant-pagination-item-active {
|
|
418
|
+
background: var(--ant-color-primary);
|
|
419
|
+
a {
|
|
420
|
+
color: #fff;
|
|
421
|
+
}
|
|
422
|
+
}
|
|
423
|
+
|
|
424
|
+
.ant-pagination-prev .ant-pagination-item-link,
|
|
425
|
+
.ant-pagination-next .ant-pagination-item-link {
|
|
426
|
+
color: var(--ant-color-text);
|
|
427
|
+
font-size: 14px;
|
|
428
|
+
}
|
|
429
|
+
|
|
430
|
+
.ant-pagination-jump-prev .ant-pagination-item-container .ant-pagination-item-ellipsis,
|
|
431
|
+
.ant-pagination-jump-next .ant-pagination-item-container .ant-pagination-item-ellipsis {
|
|
432
|
+
color: var(--ant-color-text);
|
|
433
|
+
font-weight: 700;
|
|
434
|
+
}
|
|
435
|
+
}
|
|
436
|
+
`,Y=n.div`
|
|
437
|
+
display: inline-flex;
|
|
438
|
+
border: 2px solid var(--ant-color-border);
|
|
439
|
+
|
|
440
|
+
button {
|
|
441
|
+
height: 56px;
|
|
442
|
+
padding: 0 22px;
|
|
443
|
+
border: 0;
|
|
444
|
+
border-right: 2px solid var(--ant-color-border);
|
|
445
|
+
background: transparent;
|
|
446
|
+
font: inherit;
|
|
447
|
+
font-size: 16px;
|
|
448
|
+
color: var(--ant-color-text);
|
|
449
|
+
cursor: pointer;
|
|
450
|
+
|
|
451
|
+
&:last-child {
|
|
452
|
+
border-right: 0;
|
|
453
|
+
}
|
|
454
|
+
|
|
455
|
+
&[aria-pressed="true"] {
|
|
456
|
+
background: var(--ant-color-primary);
|
|
457
|
+
color: #fff;
|
|
458
|
+
}
|
|
459
|
+
}
|
|
460
|
+
`,J=e=>`Total ${e.toLocaleString()} items`;const Q=n(t.Tabs)`
|
|
461
|
+
&.ant-tabs .ant-tabs-nav {
|
|
462
|
+
margin: 0;
|
|
463
|
+
|
|
464
|
+
&::before {
|
|
465
|
+
border-bottom: 2px solid var(--ant-color-border-secondary);
|
|
466
|
+
}
|
|
467
|
+
}
|
|
468
|
+
|
|
469
|
+
&.ant-tabs .ant-tabs-tab {
|
|
470
|
+
padding: 14px 0 18px;
|
|
471
|
+
font-weight: 600;
|
|
472
|
+
font-size: 18px;
|
|
473
|
+
|
|
474
|
+
+ .ant-tabs-tab {
|
|
475
|
+
margin-left: 48px;
|
|
476
|
+
}
|
|
477
|
+
}
|
|
478
|
+
|
|
479
|
+
&.ant-tabs .ant-tabs-ink-bar {
|
|
480
|
+
height: 4px;
|
|
481
|
+
}
|
|
482
|
+
|
|
483
|
+
.hisd3-tab-count {
|
|
484
|
+
margin-left: 10px;
|
|
485
|
+
font-size: 14px;
|
|
486
|
+
font-weight: 500;
|
|
487
|
+
color: var(--ant-color-text-tertiary);
|
|
488
|
+
}
|
|
489
|
+
|
|
490
|
+
.ant-tabs-tab-active .hisd3-tab-count {
|
|
491
|
+
color: var(--ant-color-primary);
|
|
492
|
+
}
|
|
493
|
+
`,Z={default:"var(--ant-color-text)",primary:"var(--ant-color-primary)",success:"var(--ant-color-success)",warning:"var(--ant-color-warning)",danger:"var(--ant-color-error)"},ee={default:"rgba(0,0,0,0.05)",primary:"var(--ant-color-primary-bg)",success:"var(--ant-color-success-bg)",warning:"var(--ant-color-warning-bg)",danger:"var(--ant-color-error-bg)"},te=n.span`
|
|
494
|
+
display: inline-flex;
|
|
495
|
+
align-items: center;
|
|
496
|
+
gap: 6px;
|
|
497
|
+
height: 32px;
|
|
498
|
+
padding: 0 14px;
|
|
499
|
+
font-size: 12px;
|
|
500
|
+
font-weight: 500;
|
|
501
|
+
letter-spacing: 0.06em;
|
|
502
|
+
text-transform: uppercase;
|
|
503
|
+
white-space: nowrap;
|
|
504
|
+
line-height: 1;
|
|
505
|
+
border: 2px solid transparent;
|
|
506
|
+
border-radius: 0;
|
|
507
|
+
|
|
508
|
+
${({$variant:e,$tone:t})=>{const r=Z[t],n=ee[t];switch(e){case"soft":return`color: ${r}; background: ${n};`;case"outline":return`color: ${r}; border-color: ${r}; background: transparent;`;case"solid":return`color: #fff; background: ${"default"===t?"var(--ant-color-text)":r};`;default:return"color: var(--ant-color-text); background: rgba(0,0,0,0.05);"}}}
|
|
509
|
+
`,re=n(t.Button)`
|
|
510
|
+
&.ant-btn {
|
|
511
|
+
text-transform: none;
|
|
512
|
+
letter-spacing: 0;
|
|
513
|
+
display: inline-flex;
|
|
514
|
+
align-items: center;
|
|
515
|
+
gap: 8px;
|
|
516
|
+
height: var(--hisd3-btn-height, 52px);
|
|
517
|
+
padding-inline: 20px;
|
|
518
|
+
font-size: 16px;
|
|
519
|
+
font-weight: 600;
|
|
520
|
+
box-shadow: none;
|
|
521
|
+
}
|
|
522
|
+
|
|
523
|
+
&.ant-btn-sm {
|
|
524
|
+
--hisd3-btn-height: 36px;
|
|
525
|
+
font-size: 14px;
|
|
526
|
+
padding-inline: 14px;
|
|
527
|
+
}
|
|
528
|
+
|
|
529
|
+
&.ant-btn-lg {
|
|
530
|
+
--hisd3-btn-height: 56px;
|
|
531
|
+
}
|
|
532
|
+
|
|
533
|
+
&.ant-btn-default {
|
|
534
|
+
border-width: 2px;
|
|
535
|
+
}
|
|
536
|
+
|
|
537
|
+
.anticon {
|
|
538
|
+
font-size: 1.05em;
|
|
539
|
+
}
|
|
540
|
+
`,ne={primary:{type:"primary"},secondary:{type:"default"},ghost:{type:"text"},danger:{type:"primary",danger:!0}},oe=n(t.Input)`
|
|
541
|
+
&.ant-input,
|
|
542
|
+
&.ant-input-affix-wrapper {
|
|
543
|
+
border-width: 2px;
|
|
544
|
+
font-size: 16px;
|
|
545
|
+
}
|
|
546
|
+
|
|
547
|
+
&.ant-input-affix-wrapper .ant-input-prefix {
|
|
548
|
+
margin-inline-end: 14px;
|
|
549
|
+
color: var(--ant-color-text-tertiary);
|
|
550
|
+
font-size: 18px;
|
|
551
|
+
}
|
|
552
|
+
`,ie=n(oe)`
|
|
553
|
+
&.ant-input-affix-wrapper {
|
|
554
|
+
background: var(--hisd3-bg-filled, #e6e4e1);
|
|
555
|
+
border-color: var(--ant-color-border-secondary);
|
|
556
|
+
height: 72px;
|
|
557
|
+
padding-inline: 24px;
|
|
558
|
+
|
|
559
|
+
&:hover,
|
|
560
|
+
&:focus-within {
|
|
561
|
+
border-color: var(--ant-color-border);
|
|
562
|
+
background: var(--hisd3-bg-filled, #e6e4e1);
|
|
563
|
+
}
|
|
564
|
+
|
|
565
|
+
.ant-input {
|
|
566
|
+
background: transparent;
|
|
567
|
+
font-size: 20px;
|
|
568
|
+
}
|
|
569
|
+
|
|
570
|
+
.ant-input-prefix {
|
|
571
|
+
font-size: 22px;
|
|
572
|
+
}
|
|
573
|
+
}
|
|
574
|
+
|
|
575
|
+
&.hisd3-search-compact.ant-input-affix-wrapper {
|
|
576
|
+
height: 48px;
|
|
577
|
+
padding-inline: 16px;
|
|
578
|
+
|
|
579
|
+
.ant-input {
|
|
580
|
+
font-size: 16px;
|
|
581
|
+
}
|
|
582
|
+
.ant-input-prefix {
|
|
583
|
+
font-size: 18px;
|
|
584
|
+
}
|
|
585
|
+
}
|
|
586
|
+
`;var ae,le,se,de,pe,ce,he,ge,ue,xe,me,be,ye;exports.ThemeStyle=void 0,(ae=exports.ThemeStyle||(exports.ThemeStyle={})).MODERN="modern",ae.STANDARD="standard",exports.ThemeStyleRadius=void 0,(le=exports.ThemeStyleRadius||(exports.ThemeStyleRadius={})).MODERN="30px",le.STANDARD="16px",exports.ThemeMode=void 0,(se=exports.ThemeMode||(exports.ThemeMode={})).LIGHT="light",se.SEMI_DARK="semi-dark",se.DARK="dark",exports.LayoutType=void 0,(de=exports.LayoutType||(exports.LayoutType={})).FULL_WIDTH="full-width",de.BOXED="boxed",de.FRAMED="framed",exports.MenuStyle=void 0,(pe=exports.MenuStyle||(exports.MenuStyle={})).DEFAULT="default",pe.STANDARD="standard",pe.ROUNDED="rounded",pe.ROUNDED_REVERSE="rounded-reverse",pe.CURVED_MENU="curved-menu",exports.NavStyle=void 0,(ce=exports.NavStyle||(exports.NavStyle={})).DEFAULT="default",ce.MINI="mini",ce.MINI_SIDEBAR_TOGGLE="mini-sidebar-toggle",ce.STANDARD="standard",ce.HEADER_USER="user-header",ce.HEADER_USER_MINI="user-mini-header",ce.DRAWER="drawer",ce.BIT_BUCKET="bit-bucket",ce.H_DEFAULT="h-default",ce.HOR_HEADER_FIXED="hor-header-fixed",ce.HOR_DARK_LAYOUT="hor-dark-layout",exports.FooterType=void 0,(he=exports.FooterType||(exports.FooterType={})).FIXED="fixed",he.FLUID="fluid",exports.LayoutDirection=void 0,(ge=exports.LayoutDirection||(exports.LayoutDirection={})).RTL="rtl",ge.LTR="ltr",exports.HeaderType=void 0,(ue=exports.HeaderType||(exports.HeaderType={})).DARK="dark",ue.LIGHT="light",exports.RouteTransition=void 0,(xe=exports.RouteTransition||(exports.RouteTransition={})).NONE="none",xe.FADE="fade",xe.SLIDE_LEFT="slideLeft",xe.SLIDE_RIGHT="slideRight",xe.SLIDE_UP="slideUp",xe.SLIDE_DOWN="slideDown",exports.Fonts=void 0,(me=exports.Fonts||(exports.Fonts={})).LIGHT="300",me.REGULAR="400",me.MEDIUM="500",me.BOLD="600",exports.AuthType=void 0,(be=exports.AuthType||(exports.AuthType={})).FIREBASE="firebase",be.AWS_COGNITO="aws_cognito",be.AUTH0="auth0",be.JWT_AUTH="jwt_auth",exports.AppAnimates=void 0,(ye=exports.AppAnimates||(exports.AppAnimates={})).SLIDEUPIN="transition.slideUpIn",ye.SLIDEUPOUT="transition.slideUpOut",ye.SLIDEDOWNIN="transition.slideDownIn",ye.SLIDEDOWNOUT="transition.slideDownOut",ye.SLIDELEFTIN="transition.slideLeftIn",ye.SLIDELEFTOUT="transition.slideLeftOut",ye.SLIDERIGHTIN="transition.slideRightIn",ye.SLIDERIGHTOUT="transition.slideRightOut",ye.FADEIN="transition.fadeIn",ye.FADEOUT="transition.fadeOut";var fe,ve;exports.MessageType=void 0,(fe=exports.MessageType||(exports.MessageType={}))[fe.MEDIA=1]="MEDIA",fe[fe.TEXT=2]="TEXT",exports.RoutePermittedRole=void 0,(ve=exports.RoutePermittedRole||(exports.RoutePermittedRole={})).Admin="admin",ve.User="user",exports.AppAnimateGroups={SLIDEUPIN:{hidden:{y:0},visible:{opacity:1,y:0,transition:{ease:"easeIn",delay:0,when:"beforeChildren",duration:.2,staggerChildren:.05}}},SLIDEUPOUT:{hidden:{y:0},visible:{opacity:0,y:"100vh",transition:{ease:"easeOut",delay:0,when:"beforeChildren",duration:.4,staggerChildren:.15}}},SLIDEDOWNIN:{hidden:{opacity:0,y:"-100vh"},visible:{opacity:1,y:0,transition:{ease:"easeIn",delay:0,when:"beforeChildren",duration:.4,staggerChildren:.15}}},SLIDEDOWNOUT:{hidden:{y:0},visible:{opacity:0,y:"-100vh",transition:{ease:"easeOut",delay:0,when:"beforeChildren",duration:.4,staggerChildren:.15}}},SLIDELEFTIN:{hidden:{x:"100vw"},visible:{opacity:1,x:0,transition:{ease:"easeIn",delay:0,when:"beforeChildren",duration:.4,staggerChildren:.15}}},SLIDELEFTOUT:{hidden:{x:0},visible:{opacity:0,x:"100vw",transition:{ease:"easeOut",delay:0,when:"beforeChildren",duration:.4,staggerChildren:.15}}},SLIDERIGHTIN:{hidden:{x:"-100vw"},visible:{opacity:1,x:0,transition:{ease:"easeIn",delay:0,when:"beforeChildren",duration:.4,staggerChildren:.15}}},SLIDERIGHTOUT:{hidden:{x:0},visible:{opacity:0,x:"-100vw",transition:{ease:"easeOut",delay:0,when:"beforeChildren",duration:.4,staggerChildren:.15}}},FADEIN:{hidden:{opacity:0,scale:1},visible:{opacity:1,scale:1,transition:{ease:"easeIn",when:"beforeChildren",staggerChildren:.15}}},FADEOUT:{hidden:{opacity:1,scale:1},visible:{opacity:0,scale:1,transition:{ease:"easeOut",when:"beforeChildren",staggerChildren:.15}}},NOANIMATION:{hidden:{opacity:1},visible:{opacity:1}}},exports.AppMotionAnimate={SLIDEUPIN:{variants:{hidden:{y:100,opacity:0},visible:{opacity:1,y:0}},transition:{ease:"easeIn",when:"beforeChildren"}},SLIDEUPOUT:{variants:{hidden:{y:0,opacity:1},visible:{opacity:0,y:"-100vh"}},transition:{ease:"easeOut",when:"beforeChildren"}},SLIDEDOWNIN:{variants:{hidden:{y:-100,opacity:0},visible:{opacity:1,y:0}},transition:{ease:"easeIn",when:"beforeChildren"}},SLIDEDOWNOUT:{variants:{hidden:{y:0,opacity:1},visible:{opacity:0,y:"100vh"}},transition:{ease:"easeOut",when:"beforeChildren"}},SLIDELEFTIN:{variants:{hidden:{x:100,opacity:0},visible:{opacity:1,x:0}},transition:{ease:"easeIn",when:"beforeChildren"}},SLIDELEFTOUT:{variants:{hidden:{x:0,opacity:1},visible:{opacity:0,x:"-100vw"}},transition:{ease:"easeOut",when:"beforeChildren"}},SLIDERIGHTIN:{variants:{hidden:{x:-100,opacity:0},visible:{opacity:1,x:0}},transition:{ease:"easeIn",when:"beforeChildren"}},SLIDERIGHTOUT:{variants:{hidden:{x:0,opacity:1},visible:{opacity:0,x:"-100vw"}},transition:{ease:"easeOut",when:"beforeChildren"}},FADEIN:{variants:{hidden:{opacity:0},visible:{opacity:1}},transition:{duration:.1,ease:"easeIn",when:"beforeChildren"}},FADEOUT:{variants:{hidden:{opacity:1},visible:{opacity:0}},transition:{duration:.1,ease:"easeOut",when:"beforeChildren"}}},exports.HISD3Button=({variant:t="secondary",...r})=>e.jsx(re,{...ne[t],...r}),exports.HISD3Input=t=>e.jsx(oe,{...t}),exports.HISD3PageBody=K,exports.HISD3PageHeader=({title:r,subtitle:n,breadcrumb:o,extra:i,leading:a,hideTopBar:l=!1,className:s})=>e.jsxs("header",{className:s,children:[!l&&e.jsxs(P,{children:[a,o&&o.length>0&&e.jsx(t.Breadcrumb,{items:o.map((t=>({title:t.href?e.jsx("a",{href:t.href,children:t.title}):t.title,onClick:t.onClick})))}),!o?.length&&e.jsx("span",{style:{flex:1}}),i&&e.jsx(W,{children:i})]}),e.jsxs(G,{children:[e.jsx("h1",{children:r}),n&&e.jsx("p",{children:n})]})]}),exports.HISD3Provider=({primary:o,radius:i,lineWidth:a,overrides:l,theme:s,styledTheme:d={},children:p})=>{const h=r.useMemo((()=>s??c({primary:o,radius:i,lineWidth:a,overrides:l})),[s,o,i,a,l]);return e.jsx(u.Provider,{value:!0,children:e.jsx(t.ConfigProvider,{theme:h,children:e.jsx(n.ThemeProvider,{theme:d,children:e.jsx(t.App,{component:!1,children:p})})})})},exports.HISD3SearchInput=({compact:t=!1,className:r,...n})=>e.jsx(ie,{allowClear:!0,prefix:e.jsx(o.SearchOutlined,{}),className:[t?"hisd3-search-compact":"",r??""].join(" ").trim(),...n}),exports.HISD3Sidebar=({children:i,account:a,logoUrl:l,appName:s,menuItems:d,onLogout:p,pathname:c,avatarSrc:g,styledTheme:u,settingsUrl:m,antdTheme:b,renderMenuLink:y=U,headerExtra:w,userMenuItems:L,onCollapse:j,collapsed:A=!1,loading:O=!1,hideSidebar:R=!1,layoutTop:z=!1,hideCollapseTrigger:B=!1,siderWidth:H=f,bareContent:_=!1,hideHeaderBar:P=!1,brandHref:W="/"})=>{const G=x(),K=void 0===b?G?null:h:b,[q,X]=r.useState(A);r.useEffect((()=>{X(A)}),[A]);const V=r.useMemo((()=>F(d,y)),[d,y]),Y=r.useMemo((()=>((e,t)=>{let r;const n=(e,o)=>{(e??[]).forEach(((e,i)=>{const a=N(e,i);if(e.path&&t.startsWith(e.path)){const n=t===e.path,i=e.path.length+(n?1:0);(!r||i>r.length)&&(r={key:a,parents:o,length:i})}e.children?.length&&n(e.children,[...o,a])}))};return n(e,[]),{selectedKey:r?.key,openKeys:r?.parents??[]}})(d,c)),[d,c]),[J,Q]=r.useState((()=>Y.openKeys));r.useEffect((()=>{Q((e=>Array.from(new Set([...e,...Y.openKeys]))))}),[Y.openKeys.join("|")]);const Z=e=>{X(e),j?.(e)},ee=Y.selectedKey?[Y.selectedKey]:[],te=e.jsxs(T,{href:W,$collapsed:!z&&q,children:[l?e.jsx("img",{src:l,alt:s}):e.jsx("span",{className:"hisd3-brand-mark","aria-hidden":!0}),(z||!q)&&e.jsx("h1",{children:s})]}),re=_?i:e.jsx(C,{children:i});if("undefined"==typeof document)return null;const ne=e.jsx(t.App,{component:!1,children:e.jsx(t.Spin,{spinning:O,size:"large",children:R?e.jsx(e.Fragment,{children:i}):z?e.jsxs(S,{children:[e.jsxs(D,{children:[te,e.jsx(t.Menu,{mode:"horizontal",items:V,selectedKeys:ee}),w,e.jsx(M,{account:a,avatarSrc:g,settingsUrl:m,onLogout:p,placement:"bottomRight",extraItems:L})]}),re]}):e.jsxs(S,{hasSider:!0,children:[e.jsxs($,{className:"hisd3-sider",width:H,collapsedWidth:v,collapsible:!0,collapsed:q,trigger:null,theme:"light",breakpoint:"lg",onBreakpoint:e=>{e&&Z(!0)},children:[te,e.jsx(I,{className:q?"hisd3-collapsed":void 0,children:e.jsx(t.Menu,{mode:"inline",theme:"light",inlineCollapsed:q,items:V,selectedKeys:ee,openKeys:q?void 0:J,onOpenChange:e=>Q(e)})}),e.jsx(M,{account:a,avatarSrc:g,settingsUrl:m,onLogout:p,collapsed:q,placement:"topRight",extraItems:L})]}),e.jsxs(t.Layout,{style:{background:"transparent"},children:[!P&&e.jsxs(E,{children:[!B&&e.jsx(k,{type:"button","aria-label":q?"Expand menu":"Collapse menu",onClick:()=>Z(!q),children:q?e.jsx(o.MenuUnfoldOutlined,{}):e.jsx(o.MenuFoldOutlined,{})}),e.jsx("span",{style:{flex:1}}),w]}),re]})]})})});return G&&!u?K?e.jsx(t.ConfigProvider,{theme:K,children:ne}):ne:e.jsx(n.ThemeProvider,{theme:u??{},children:K?e.jsx(t.ConfigProvider,{theme:K,children:ne}):ne})},exports.HISD3Table=function({pagination:r,footer:n,...i}){const a=r||void 0,l=a?.pageSizeOptions??[10,20,50];return e.jsxs(q,{children:[e.jsx(t.Table,{...i,pagination:!1}),n&&e.jsx(X,{children:n}),a&&e.jsxs(V,{children:[e.jsx("span",{className:"hisd3-total",children:(a.renderTotal??J)(a.total,[(a.current-1)*a.pageSize+1,Math.min(a.current*a.pageSize,a.total)])}),e.jsx(t.Pagination,{current:a.current,pageSize:a.pageSize,total:a.total,showSizeChanger:!1,onChange:(e,t)=>a.onChange(e,t),itemRender:(t,r,n)=>"prev"===r?e.jsx("span",{className:"ant-pagination-item-link",children:e.jsx(o.LeftOutlined,{})}):"next"===r?e.jsx("span",{className:"ant-pagination-item-link",children:e.jsx(o.RightOutlined,{})}):n}),!a.hidePageSize&&e.jsx(Y,{role:"group","aria-label":"Rows per page",children:l.map((t=>e.jsxs("button",{type:"button","aria-pressed":t===a.pageSize,onClick:()=>a.onChange(1,t),children:[t," / page"]},t)))})]})]})},exports.HISD3Tabs=({items:t,...r})=>e.jsx(Q,{...r,items:t.map((({count:t,label:r,...n})=>({...n,label:e.jsxs(e.Fragment,{children:[r,void 0!==t&&e.jsx("span",{className:"hisd3-tab-count",children:t})]})})))}),exports.HISD3Tag=({variant:t="neutral",tone:r=("neutral"===t?"default":"primary"),children:n,...o})=>e.jsx(te,{$variant:t,$tone:r,...o,children:n}),exports.HISD3_COLORS=g,exports.HISD3_FONT_FAMILY=s,exports.HISD3_FONT_WEIGHT_BODY=400,exports.HISD3_FONT_WEIGHT_HEADING=800,exports.HISD3_LAYOUT=m,exports.HISD3_NEUTRALS=l,exports.HISD3_PRESETS=a,exports.UserMenu=M,exports.createHisd3Theme=c,exports.hisd3AntdTheme=h,exports.resolvePrimary=d,exports.tint=p,exports.useInsideHISD3Provider=x;
|
|
195
587
|
//# sourceMappingURL=index.cjs.js.map
|