@ctlyst.id/internal-ui 2.1.1-canary.0 → 2.1.2
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/components/alert/components/alert-context.d.ts +4 -0
- package/dist/components/alert/components/alert.d.ts +1 -1
- package/dist/components/breadcrumb/__stories__/breadcrumb.stories.d.ts +2 -1
- package/dist/components/breadcrumb/components/bread-crumb.d.ts +1 -0
- package/dist/components/button/__stories__/button.stories.d.ts +1 -0
- package/dist/components/header/__stories__/header.stories.d.ts +3 -1
- package/dist/components/header/components/header.d.ts +6 -0
- package/dist/components/header/components/logo.d.ts +7 -0
- package/dist/components/header/components/profile.d.ts +2 -0
- package/dist/components/header/components/version.d.ts +1 -0
- package/dist/components/header/types.d.ts +1 -1
- package/dist/components/tabs/__stories__/tabs.stories.d.ts +1 -0
- package/dist/components/tabs/components/tab.d.ts +1 -0
- package/dist/config/theme/components/alert.d.ts +6 -16
- package/dist/config/theme/components/checkbox.d.ts +6 -7
- package/dist/config/theme/components/chips.d.ts +9 -8
- package/dist/config/theme/components/loader.d.ts +1 -1
- package/dist/internal-ui.cjs.development.js +176 -125
- package/dist/internal-ui.cjs.development.js.map +1 -1
- package/dist/internal-ui.cjs.production.min.js +5 -5
- package/dist/internal-ui.cjs.production.min.js.map +1 -1
- package/dist/internal-ui.esm.js +178 -127
- package/dist/internal-ui.esm.js.map +1 -1
- package/package.json +4 -4
@@ -75,6 +75,10 @@ const STATUSES = {
|
|
75
75
|
error: {
|
76
76
|
icon: WarningIcon,
|
77
77
|
colorScheme: 'danger'
|
78
|
+
},
|
79
|
+
neutral: {
|
80
|
+
icon: InfoIcon,
|
81
|
+
colorScheme: 'neutral'
|
78
82
|
}
|
79
83
|
};
|
80
84
|
function getStatusColorScheme(status) {
|
@@ -174,10 +178,9 @@ function AlertAction({
|
|
174
178
|
const css = styles.action;
|
175
179
|
return /*#__PURE__*/React__default.createElement(Button, {
|
176
180
|
"data-test-id": "alert-action",
|
177
|
-
className: utils.cx('chakra-
|
181
|
+
className: utils.cx('chakra-alert__action', className),
|
178
182
|
variant: "link",
|
179
|
-
|
180
|
-
fontWeight: "700",
|
183
|
+
fontWeight: "semibold",
|
181
184
|
__css: css
|
182
185
|
}, children);
|
183
186
|
}
|
@@ -265,10 +268,10 @@ const Badge = props => {
|
|
265
268
|
...rest
|
266
269
|
} = props;
|
267
270
|
return /*#__PURE__*/React__default.createElement(react.Badge, Object.assign({
|
268
|
-
borderRadius: pill ?
|
271
|
+
borderRadius: pill ? 'xl' : 'sm',
|
269
272
|
variant: "primary-solid",
|
270
|
-
|
271
|
-
|
273
|
+
px: "2",
|
274
|
+
h: "4.5",
|
272
275
|
display: "inline-flex",
|
273
276
|
alignItems: "center",
|
274
277
|
justifyContent: "space-between",
|
@@ -287,9 +290,10 @@ const BreadCrumb = props => {
|
|
287
290
|
parents,
|
288
291
|
className,
|
289
292
|
disableHome,
|
290
|
-
spacing = 2
|
293
|
+
spacing = 2,
|
294
|
+
backButton
|
291
295
|
} = props;
|
292
|
-
const [
|
296
|
+
const [neutral600, primary500] = react.useToken('colors', ['neutral.600', 'primary.500']);
|
293
297
|
return /*#__PURE__*/React.createElement(react.Box, {
|
294
298
|
"data-test-id": "CT_component_breadcrumb_breadcrumb",
|
295
299
|
className: className,
|
@@ -300,22 +304,29 @@ const BreadCrumb = props => {
|
|
300
304
|
}, /*#__PURE__*/React.createElement(react.Box, {
|
301
305
|
display: "flex",
|
302
306
|
alignItems: "center"
|
303
|
-
}, /*#__PURE__*/React.createElement(
|
304
|
-
|
305
|
-
|
306
|
-
|
307
|
-
|
307
|
+
}, backButton && /*#__PURE__*/React.createElement(Button, {
|
308
|
+
variant: "icon",
|
309
|
+
"data-test-id": "button",
|
310
|
+
size: "md",
|
311
|
+
mr: "2",
|
312
|
+
onClick: backButton
|
313
|
+
}, /*#__PURE__*/React.createElement(fi.FiChevronLeft, {
|
314
|
+
size: react.theme.sizes[5]
|
315
|
+
})), /*#__PURE__*/React.createElement(react.Text, {
|
316
|
+
pr: "2",
|
317
|
+
textStyle: "heading.6",
|
318
|
+
color: "neutral.700"
|
308
319
|
}, title), /*#__PURE__*/React.createElement(react.Box, {
|
309
|
-
h: "
|
320
|
+
h: "5.5",
|
310
321
|
borderLeft: "1px solid",
|
311
|
-
borderColor:
|
322
|
+
borderColor: neutral600
|
312
323
|
}), /*#__PURE__*/React.createElement(react.Breadcrumb, {
|
313
324
|
separator: /*#__PURE__*/React.createElement(fi.FiChevronsRight, {
|
314
|
-
color:
|
315
|
-
size:
|
325
|
+
color: neutral600,
|
326
|
+
size: react.theme.sizes['3.5']
|
316
327
|
}),
|
317
|
-
pl: 2
|
318
|
-
pr: 4,
|
328
|
+
pl: "2",
|
329
|
+
pr: "4",
|
319
330
|
spacing: spacing,
|
320
331
|
sx: {
|
321
332
|
ol: {
|
@@ -335,8 +346,8 @@ const BreadCrumb = props => {
|
|
335
346
|
}
|
336
347
|
}, /*#__PURE__*/React.createElement(fi.FiHome, {
|
337
348
|
className: "align-top",
|
338
|
-
size:
|
339
|
-
color:
|
349
|
+
size: react.theme.sizes['3.5'],
|
350
|
+
color: primary500
|
340
351
|
}))), parents === null || parents === void 0 ? void 0 : parents.map(val => /*#__PURE__*/React.createElement(react.BreadcrumbItem, {
|
341
352
|
key: val.name
|
342
353
|
}, /*#__PURE__*/React.createElement(react.BreadcrumbLink, {
|
@@ -352,18 +363,16 @@ const BreadCrumb = props => {
|
|
352
363
|
textDecoration: 'none'
|
353
364
|
}
|
354
365
|
}, /*#__PURE__*/React.createElement(react.Text, {
|
355
|
-
color: val.disable ?
|
356
|
-
|
357
|
-
fontWeight: 400
|
366
|
+
color: val.disable ? neutral600 : primary500,
|
367
|
+
textStyle: "text.sm"
|
358
368
|
}, val.name)))), /*#__PURE__*/React.createElement(react.BreadcrumbItem, null, /*#__PURE__*/React.createElement(react.BreadcrumbLink, {
|
359
369
|
_hover: {
|
360
370
|
textDecor: 'none',
|
361
371
|
cursor: 'default'
|
362
372
|
}
|
363
373
|
}, /*#__PURE__*/React.createElement(react.Text, {
|
364
|
-
color:
|
365
|
-
|
366
|
-
fontWeight: 400
|
374
|
+
color: "neutral.600",
|
375
|
+
textStyle: "text.sm"
|
367
376
|
}, title))))), children && /*#__PURE__*/React.createElement(react.Box, null, children));
|
368
377
|
};
|
369
378
|
BreadCrumb.defaultProps = {
|
@@ -371,7 +380,8 @@ BreadCrumb.defaultProps = {
|
|
371
380
|
parents: undefined,
|
372
381
|
className: undefined,
|
373
382
|
disableHome: undefined,
|
374
|
-
spacing: 2
|
383
|
+
spacing: 2,
|
384
|
+
backButton: undefined
|
375
385
|
};
|
376
386
|
|
377
387
|
const CardCustom = /*#__PURE__*/React.forwardRef(({
|
@@ -1943,17 +1953,22 @@ TextareaField.defaultProps = {
|
|
1943
1953
|
isLoading: undefined
|
1944
1954
|
};
|
1945
1955
|
|
1946
|
-
const
|
1947
|
-
|
1948
|
-
|
1949
|
-
})
|
1950
|
-
|
1951
|
-
|
1952
|
-
|
1953
|
-
|
1954
|
-
|
1956
|
+
const Logo = ({
|
1957
|
+
imageUrl,
|
1958
|
+
height
|
1959
|
+
}) => /*#__PURE__*/React__default.createElement(react.Image, {
|
1960
|
+
w: "100%",
|
1961
|
+
h: height !== null && height !== void 0 ? height : 9,
|
1962
|
+
maxH: height !== null && height !== void 0 ? height : 9,
|
1963
|
+
src: imageUrl,
|
1964
|
+
alt: imageUrl
|
1965
|
+
});
|
1966
|
+
Logo.defaultProps = {
|
1967
|
+
height: undefined
|
1968
|
+
};
|
1955
1969
|
|
1956
1970
|
const Profile = ({
|
1971
|
+
brandColor,
|
1957
1972
|
data,
|
1958
1973
|
onLogout
|
1959
1974
|
}) => {
|
@@ -1979,27 +1994,31 @@ const Profile = ({
|
|
1979
1994
|
onClick: onToggle
|
1980
1995
|
}, /*#__PURE__*/React.createElement(react.HStack, null, /*#__PURE__*/React.createElement(react.VStack, {
|
1981
1996
|
alignItems: "flex-end",
|
1982
|
-
spacing:
|
1983
|
-
ml: "2"
|
1997
|
+
spacing: 0,
|
1998
|
+
ml: "2",
|
1999
|
+
color: "primary.500"
|
1984
2000
|
}, /*#__PURE__*/React.createElement(react.Text, {
|
1985
|
-
|
2001
|
+
textStyle: "text.xs",
|
1986
2002
|
mb: 1,
|
1987
|
-
|
1988
|
-
|
1989
|
-
|
1990
|
-
}, data === null || data === void 0 ? void 0 : data.
|
1991
|
-
|
1992
|
-
|
1993
|
-
|
1994
|
-
|
1995
|
-
}, (data === null || data === void 0 ? void 0 : data.office)
|
1996
|
-
|
1997
|
-
|
1998
|
-
|
1999
|
-
|
2000
|
-
|
2001
|
-
|
2002
|
-
|
2003
|
+
color: "neutral.800"
|
2004
|
+
}, data === null || data === void 0 ? void 0 : data.email), /*#__PURE__*/React.createElement(react.Flex, null, (data === null || data === void 0 ? void 0 : data.userRole) && /*#__PURE__*/React.createElement(react.Text, {
|
2005
|
+
textStyle: "text.xs"
|
2006
|
+
}, (data === null || data === void 0 ? void 0 : data.userRole) || 'user'), /*#__PURE__*/React.createElement(react.Box, {
|
2007
|
+
h: "3",
|
2008
|
+
mx: "1",
|
2009
|
+
borderLeft: "1px solid",
|
2010
|
+
borderColor: "neutral.400"
|
2011
|
+
}), typeof (data === null || data === void 0 ? void 0 : data.office) === 'object' ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(react.Text, {
|
2012
|
+
textStyle: "text.xs"
|
2013
|
+
}, data.office[0]), data.office.length > 1 && /*#__PURE__*/React.createElement(Badge, {
|
2014
|
+
ml: "1",
|
2015
|
+
pill: true,
|
2016
|
+
variant: "neutral-light"
|
2017
|
+
}, data.office.length - 1, "+")) : /*#__PURE__*/React.createElement(react.Text, {
|
2018
|
+
textStyle: "text.xs"
|
2019
|
+
}, (data === null || data === void 0 ? void 0 : data.office) || 'office'))), /*#__PURE__*/React.createElement(react.PopoverTrigger, null, /*#__PURE__*/React.createElement(react.Avatar, {
|
2020
|
+
size: "sm",
|
2021
|
+
bg: brandColor,
|
2003
2022
|
color: "white",
|
2004
2023
|
name: (_data$name = data === null || data === void 0 ? void 0 : data.name) !== null && _data$name !== void 0 ? _data$name : data === null || data === void 0 ? void 0 : data.email
|
2005
2024
|
})))), /*#__PURE__*/React.createElement(react.PopoverContent, {
|
@@ -2021,12 +2040,13 @@ const Profile = ({
|
|
2021
2040
|
color: 'white'
|
2022
2041
|
},
|
2023
2042
|
onClick: onLogout,
|
2024
|
-
|
2043
|
+
textStyle: "text.xs"
|
2025
2044
|
}, /*#__PURE__*/React.createElement(fi.FiPower, null), /*#__PURE__*/React.createElement(react.Text, {
|
2026
2045
|
ml: 2
|
2027
2046
|
}, "Logout")))));
|
2028
2047
|
};
|
2029
2048
|
Profile.defaultProps = {
|
2049
|
+
brandColor: 'primary.500',
|
2030
2050
|
data: undefined,
|
2031
2051
|
onLogout: undefined
|
2032
2052
|
};
|
@@ -2062,22 +2082,22 @@ function environmentName(env) {
|
|
2062
2082
|
|
2063
2083
|
/* eslint-disable react-hooks/rules-of-hooks */
|
2064
2084
|
const Version = ({
|
2085
|
+
hideEnv,
|
2065
2086
|
version,
|
2066
2087
|
environment,
|
2067
2088
|
onOpenModalRelease
|
2068
2089
|
}) => /*#__PURE__*/React.createElement(React.Fragment, null, version && /*#__PURE__*/React.createElement(react.Badge, {
|
2069
2090
|
"data-test-id": "dzl3esjhCphobaaIXpiUE",
|
2070
|
-
|
2071
|
-
|
2072
|
-
fontSize: "text.xs",
|
2091
|
+
variant: "neutral-light",
|
2092
|
+
textStyle: "text.xs",
|
2073
2093
|
py: 1,
|
2074
2094
|
px: 2.5,
|
2075
|
-
fontWeight: "
|
2095
|
+
fontWeight: "semibold",
|
2076
2096
|
textTransform: "lowercase",
|
2077
2097
|
borderRadius: "md",
|
2078
2098
|
onClick: onOpenModalRelease,
|
2079
2099
|
cursor: onOpenModalRelease ? 'pointer' : 'auto'
|
2080
|
-
}, version), environmentName(environment) !== null && version && /*#__PURE__*/React.createElement(react.Box, {
|
2100
|
+
}, version), !hideEnv && environmentName(environment) !== null && version && /*#__PURE__*/React.createElement(react.Box, {
|
2081
2101
|
background: "primary.50",
|
2082
2102
|
color: "primary.500",
|
2083
2103
|
fontSize: "text.xs",
|
@@ -2087,45 +2107,74 @@ const Version = ({
|
|
2087
2107
|
borderRadius: "md"
|
2088
2108
|
}, environmentName(environment)));
|
2089
2109
|
Version.defaultProps = {
|
2110
|
+
hideEnv: false,
|
2090
2111
|
environment: undefined,
|
2091
2112
|
version: undefined,
|
2092
2113
|
onOpenModalRelease: undefined
|
2093
2114
|
};
|
2094
2115
|
|
2095
2116
|
const Header = ({
|
2117
|
+
brandColor,
|
2096
2118
|
data,
|
2097
2119
|
onLogout,
|
2098
2120
|
onOpenModalRelease,
|
2099
2121
|
hideSwitchMode,
|
2122
|
+
mainLogo = 'https://assets.voila.id/xms/logo-xms.jpg',
|
2123
|
+
centerLogo = 'https://assets.voila.id/xms/logo-voila-black.png?v=1',
|
2124
|
+
mainLogoSize,
|
2125
|
+
centerLogoSize = 4,
|
2126
|
+
hideEnv = false,
|
2127
|
+
children,
|
2100
2128
|
...props
|
2101
2129
|
}) => /*#__PURE__*/React.createElement(react.Box, Object.assign({
|
2102
|
-
minH:
|
2103
|
-
bg:
|
2104
|
-
|
2105
|
-
px:
|
2106
|
-
py:
|
2130
|
+
minH: 15,
|
2131
|
+
bg: "white",
|
2132
|
+
shadow: "raised",
|
2133
|
+
px: 6,
|
2134
|
+
py: 3
|
2107
2135
|
}, props), /*#__PURE__*/React.createElement(react.Flex, {
|
2108
|
-
|
2136
|
+
w: "full",
|
2109
2137
|
alignItems: "center",
|
2110
|
-
justifyContent: "space-between"
|
2111
|
-
|
2112
|
-
|
2138
|
+
justifyContent: "space-between",
|
2139
|
+
pos: "relative"
|
2140
|
+
}, /*#__PURE__*/React.createElement(react.Flex, {
|
2113
2141
|
alignItems: "center"
|
2114
|
-
}, /*#__PURE__*/React.createElement(
|
2142
|
+
}, /*#__PURE__*/React.createElement(Logo, {
|
2143
|
+
imageUrl: mainLogo,
|
2144
|
+
height: mainLogoSize
|
2145
|
+
}), children && children), /*#__PURE__*/React.createElement(react.HStack, {
|
2146
|
+
w: "fit-content",
|
2147
|
+
spacing: 2,
|
2148
|
+
alignItems: "center",
|
2149
|
+
pos: "absolute",
|
2150
|
+
left: "50%",
|
2151
|
+
transform: "translate(-50%,0)"
|
2152
|
+
}, /*#__PURE__*/React.createElement(Logo, {
|
2153
|
+
imageUrl: centerLogo,
|
2154
|
+
height: centerLogoSize
|
2155
|
+
}), /*#__PURE__*/React.createElement(Version, {
|
2156
|
+
hideEnv: hideEnv,
|
2115
2157
|
version: data === null || data === void 0 ? void 0 : data.version,
|
2116
2158
|
environment: data === null || data === void 0 ? void 0 : data.environment,
|
2117
2159
|
onOpenModalRelease: onOpenModalRelease
|
2118
2160
|
})), /*#__PURE__*/React.createElement(react.Flex, {
|
2119
2161
|
alignItems: "center"
|
2120
2162
|
}, !hideSwitchMode && /*#__PURE__*/React.createElement(SwitchMode, null), /*#__PURE__*/React.createElement(Profile, {
|
2163
|
+
brandColor: brandColor,
|
2121
2164
|
data: data,
|
2122
2165
|
onLogout: onLogout
|
2123
2166
|
}))));
|
2124
2167
|
Header.defaultProps = {
|
2168
|
+
brandColor: undefined,
|
2125
2169
|
data: undefined,
|
2126
2170
|
onLogout: undefined,
|
2127
2171
|
onOpenModalRelease: undefined,
|
2128
|
-
hideSwitchMode:
|
2172
|
+
hideSwitchMode: true,
|
2173
|
+
mainLogo: undefined,
|
2174
|
+
mainLogoSize: undefined,
|
2175
|
+
centerLogo: undefined,
|
2176
|
+
centerLogoSize: undefined,
|
2177
|
+
hideEnv: false
|
2129
2178
|
};
|
2130
2179
|
|
2131
2180
|
const ModalBody = /*#__PURE__*/React__default.forwardRef(({
|
@@ -2166,8 +2215,8 @@ const ModalHeader = /*#__PURE__*/React.forwardRef(({
|
|
2166
2215
|
return /*#__PURE__*/React__default.createElement(react.ModalHeader, Object.assign({
|
2167
2216
|
ref: ref,
|
2168
2217
|
background: react.useColorModeValue('neutral.200', 'mirage.900'),
|
2169
|
-
borderTopRadius:
|
2170
|
-
|
2218
|
+
borderTopRadius: "md",
|
2219
|
+
textStyle: "text-lg"
|
2171
2220
|
}, rest), children);
|
2172
2221
|
});
|
2173
2222
|
|
@@ -2326,8 +2375,8 @@ const PaginationButton = /*#__PURE__*/react.forwardRef(({
|
|
2326
2375
|
ref: ref,
|
2327
2376
|
className: className,
|
2328
2377
|
style: style,
|
2329
|
-
borderRadius:
|
2330
|
-
fontWeight:
|
2378
|
+
borderRadius: "full",
|
2379
|
+
fontWeight: "semibold",
|
2331
2380
|
m: 0,
|
2332
2381
|
px: 3,
|
2333
2382
|
py: 2,
|
@@ -2423,8 +2472,8 @@ const Pagination = ({
|
|
2423
2472
|
width: 2
|
2424
2473
|
})
|
2425
2474
|
})), /*#__PURE__*/React.createElement(react.Box, {
|
2426
|
-
|
2427
|
-
borderRadius:
|
2475
|
+
bg: "neutral.300",
|
2476
|
+
borderRadius: "full"
|
2428
2477
|
}, /*#__PURE__*/React.createElement(PaginationButtonTrigger, {
|
2429
2478
|
"data-test-id": "Pagination-Button",
|
2430
2479
|
color: previousButtonColor,
|
@@ -3099,19 +3148,28 @@ const Tab = /*#__PURE__*/react.forwardRef((props, ref) => {
|
|
3099
3148
|
const isSelected = !!tabProps['aria-selected'];
|
3100
3149
|
const styles = react.useMultiStyleConfig('Tabs', tabProps);
|
3101
3150
|
return /*#__PURE__*/React.createElement(react.Button, Object.assign({
|
3102
|
-
|
3151
|
+
"data-test-id": props['data-test-id'],
|
3152
|
+
p: 4,
|
3103
3153
|
fontSize: "text.md",
|
3104
3154
|
_selected: {
|
3105
|
-
borderColor:
|
3106
|
-
color:
|
3155
|
+
borderColor: 'primary.400',
|
3156
|
+
color: 'primary.500',
|
3107
3157
|
transform: 'translateY(-2px)'
|
3108
3158
|
},
|
3109
|
-
color:
|
3159
|
+
color: "black.medium",
|
3110
3160
|
_focus: {
|
3111
3161
|
bg: 'none'
|
3112
3162
|
},
|
3163
|
+
_hover: {
|
3164
|
+
'& .chakra-badge': {
|
3165
|
+
bg: 'primary.400'
|
3166
|
+
},
|
3167
|
+
color: 'primary.400'
|
3168
|
+
},
|
3113
3169
|
__css: styles.tab
|
3114
|
-
}, tabProps), /*#__PURE__*/React.createElement(react.Flex,
|
3170
|
+
}, tabProps), /*#__PURE__*/React.createElement(react.Flex, {
|
3171
|
+
alignItems: "center"
|
3172
|
+
}, (_props$leftAddon = props.leftAddon) === null || _props$leftAddon === void 0 ? void 0 : _props$leftAddon.call(props, {
|
3115
3173
|
isSelected
|
3116
3174
|
}), tabProps.children, (_props$rightAddon = props.rightAddon) === null || _props$rightAddon === void 0 ? void 0 : _props$rightAddon.call(props, {
|
3117
3175
|
isSelected
|
@@ -3226,6 +3284,7 @@ const {
|
|
3226
3284
|
defineMultiStyleConfig
|
3227
3285
|
} = /*#__PURE__*/styledSystem.createMultiStyleConfigHelpers(anatomy.alertAnatomy.keys);
|
3228
3286
|
const $fg = /*#__PURE__*/styledSystem.cssVar('alert-fg');
|
3287
|
+
const $ac = /*#__PURE__*/styledSystem.cssVar('alert-ac');
|
3229
3288
|
const $bg = /*#__PURE__*/styledSystem.cssVar('alert-bg');
|
3230
3289
|
const baseStyle = /*#__PURE__*/definePartsStyle({
|
3231
3290
|
container: {
|
@@ -3235,8 +3294,8 @@ const baseStyle = /*#__PURE__*/definePartsStyle({
|
|
3235
3294
|
borderRadius: 'md'
|
3236
3295
|
},
|
3237
3296
|
title: {
|
3238
|
-
fontWeight: '
|
3239
|
-
|
3297
|
+
fontWeight: 'regular',
|
3298
|
+
textStyle: 'text.sm',
|
3240
3299
|
marginEnd: '2'
|
3241
3300
|
},
|
3242
3301
|
description: {
|
@@ -3250,6 +3309,7 @@ const baseStyle = /*#__PURE__*/definePartsStyle({
|
|
3250
3309
|
h: '4'
|
3251
3310
|
},
|
3252
3311
|
action: {
|
3312
|
+
color: $ac.reference,
|
3253
3313
|
'& +.chakra-alert__close': {
|
3254
3314
|
ml: '3'
|
3255
3315
|
}
|
@@ -3269,16 +3329,13 @@ const baseStyle = /*#__PURE__*/definePartsStyle({
|
|
3269
3329
|
});
|
3270
3330
|
function getBg(props) {
|
3271
3331
|
const {
|
3272
|
-
theme,
|
3273
3332
|
colorScheme: c
|
3274
3333
|
} = props;
|
3275
|
-
const darkBg = themeTools.transparentize(`${c}.200`, 0.16)(theme);
|
3276
3334
|
return {
|
3277
|
-
light: `colors.${c}.50
|
3278
|
-
dark: darkBg
|
3335
|
+
light: c === 'neutral' ? `colors.${c}.300` : `colors.${c}.50`
|
3279
3336
|
};
|
3280
3337
|
}
|
3281
|
-
const
|
3338
|
+
const variantLight = /*#__PURE__*/definePartsStyle(props => {
|
3282
3339
|
const {
|
3283
3340
|
colorScheme: c
|
3284
3341
|
} = props;
|
@@ -3287,10 +3344,6 @@ const variantSubtle = /*#__PURE__*/definePartsStyle(props => {
|
|
3287
3344
|
container: {
|
3288
3345
|
[$fg.variable]: `colors.${c}.700`,
|
3289
3346
|
[$bg.variable]: bg.light,
|
3290
|
-
_dark: {
|
3291
|
-
[$fg.variable]: `colors.${c}.200`,
|
3292
|
-
[$bg.variable]: bg.dark
|
3293
|
-
},
|
3294
3347
|
color: $fg.reference
|
3295
3348
|
}
|
3296
3349
|
};
|
@@ -3302,24 +3355,19 @@ const variantSolid = /*#__PURE__*/definePartsStyle(props => {
|
|
3302
3355
|
return {
|
3303
3356
|
container: {
|
3304
3357
|
[$fg.variable]: `colors.white.high`,
|
3305
|
-
[$bg.variable]: `colors.${c}.500
|
3306
|
-
_dark: {
|
3307
|
-
[$fg.variable]: `colors.gray.900`,
|
3308
|
-
[$bg.variable]: `colors.${c}.200`
|
3309
|
-
},
|
3310
|
-
color: $fg.reference
|
3358
|
+
[$bg.variable]: c === 'neutral' ? `colors.${c}.700` : `colors.${c}.500`
|
3311
3359
|
}
|
3312
3360
|
};
|
3313
3361
|
});
|
3314
3362
|
const variants = {
|
3315
|
-
|
3363
|
+
light: variantLight,
|
3316
3364
|
solid: variantSolid
|
3317
3365
|
};
|
3318
3366
|
const alertTheme = /*#__PURE__*/defineMultiStyleConfig({
|
3319
3367
|
baseStyle,
|
3320
3368
|
variants,
|
3321
3369
|
defaultProps: {
|
3322
|
-
variant: '
|
3370
|
+
variant: 'light',
|
3323
3371
|
colorScheme: 'info'
|
3324
3372
|
}
|
3325
3373
|
});
|
@@ -3327,9 +3375,9 @@ const alertTheme = /*#__PURE__*/defineMultiStyleConfig({
|
|
3327
3375
|
const Badge$1 = {
|
3328
3376
|
baseStyle: {
|
3329
3377
|
display: 'inline-block',
|
3330
|
-
fontSize:
|
3331
|
-
fontWeight:
|
3332
|
-
lineHeight: '
|
3378
|
+
fontSize: 'text.xs',
|
3379
|
+
fontWeight: 'semibold',
|
3380
|
+
lineHeight: '14',
|
3333
3381
|
textTransform: 'none',
|
3334
3382
|
px: 2,
|
3335
3383
|
py: '0.5'
|
@@ -3682,18 +3730,17 @@ const {
|
|
3682
3730
|
const baseStyle$1 = /*#__PURE__*/definePartsStyle$1({
|
3683
3731
|
control: {
|
3684
3732
|
borderRadius: '4px',
|
3685
|
-
|
3686
|
-
|
3733
|
+
w: 4,
|
3734
|
+
h: 4,
|
3687
3735
|
border: '1px solid'
|
3688
3736
|
},
|
3689
3737
|
icon: {
|
3690
3738
|
color: 'neutral.50'
|
3691
3739
|
},
|
3692
3740
|
label: {
|
3693
|
-
|
3694
|
-
lineHeight: '18px',
|
3741
|
+
textStyle: 'text.sm',
|
3695
3742
|
color: 'black.high',
|
3696
|
-
ml:
|
3743
|
+
ml: 2
|
3697
3744
|
},
|
3698
3745
|
_disabled: {
|
3699
3746
|
background: 'neutral.200',
|
@@ -3719,10 +3766,10 @@ const errors = /*#__PURE__*/definePartsStyle$1({
|
|
3719
3766
|
}
|
3720
3767
|
},
|
3721
3768
|
label: {
|
3722
|
-
|
3769
|
+
textStyle: 'text.xs'
|
3723
3770
|
},
|
3724
3771
|
icon: {
|
3725
|
-
fontSize: '
|
3772
|
+
fontSize: '8px'
|
3726
3773
|
}
|
3727
3774
|
});
|
3728
3775
|
const unstyled = /*#__PURE__*/definePartsStyle$1({
|
@@ -3756,13 +3803,13 @@ const unstyled = /*#__PURE__*/definePartsStyle$1({
|
|
3756
3803
|
}
|
3757
3804
|
},
|
3758
3805
|
label: {
|
3759
|
-
|
3806
|
+
textStyle: 'text.xs',
|
3760
3807
|
_disabled: {
|
3761
3808
|
opacity: 1
|
3762
3809
|
}
|
3763
3810
|
},
|
3764
3811
|
icon: {
|
3765
|
-
fontSize: '
|
3812
|
+
fontSize: '8px'
|
3766
3813
|
}
|
3767
3814
|
});
|
3768
3815
|
const variants$1 = {
|
@@ -3785,14 +3832,17 @@ const Chips$1 = /*#__PURE__*/styledSystem.defineStyleConfig({
|
|
3785
3832
|
} = props;
|
3786
3833
|
const defaultProps = {
|
3787
3834
|
color: 'primary.500',
|
3788
|
-
|
3835
|
+
textStyle: 'text.sm',
|
3789
3836
|
borderRadius: '24px',
|
3790
3837
|
borderWidth: '1px',
|
3791
3838
|
borderColor: 'primary.500',
|
3792
3839
|
bg: 'white.high',
|
3793
|
-
|
3794
|
-
|
3795
|
-
cursor: 'default'
|
3840
|
+
px: 3,
|
3841
|
+
py: 1,
|
3842
|
+
cursor: 'default',
|
3843
|
+
_hover: {
|
3844
|
+
bg: 'primary.50'
|
3845
|
+
}
|
3796
3846
|
};
|
3797
3847
|
let chipsProps = {
|
3798
3848
|
...defaultProps
|
@@ -3800,7 +3850,10 @@ const Chips$1 = /*#__PURE__*/styledSystem.defineStyleConfig({
|
|
3800
3850
|
if (isActive) {
|
3801
3851
|
const isActiveProps = {
|
3802
3852
|
bg: 'primary.500',
|
3803
|
-
color: 'white.high'
|
3853
|
+
color: 'white.high',
|
3854
|
+
_hover: {
|
3855
|
+
bg: 'primary.500'
|
3856
|
+
}
|
3804
3857
|
};
|
3805
3858
|
chipsProps = {
|
3806
3859
|
...chipsProps,
|
@@ -3825,13 +3878,11 @@ const Chips$1 = /*#__PURE__*/styledSystem.defineStyleConfig({
|
|
3825
3878
|
},
|
3826
3879
|
sizes: {
|
3827
3880
|
sm: {
|
3828
|
-
|
3829
|
-
lineHeight: 4
|
3881
|
+
textStyle: 'text.sm'
|
3830
3882
|
},
|
3831
3883
|
md: {
|
3832
|
-
|
3833
|
-
|
3834
|
-
lineHeight: 5
|
3884
|
+
textStyle: 'text.md',
|
3885
|
+
py: 2
|
3835
3886
|
}
|
3836
3887
|
},
|
3837
3888
|
defaultProps: {
|