@ctlyst.id/internal-ui 2.1.5 → 2.1.6
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/components/accordion/__stories__/accordion.stories.d.ts +9 -0
- package/dist/components/accordion/components/accordion-indicator.d.ts +1 -0
- package/dist/components/accordion/components/index.d.ts +2 -0
- package/dist/components/accordion/index.d.ts +1 -0
- package/dist/components/badge/__stories__/badge.stories.d.ts +8 -0
- package/dist/components/header/components/header.d.ts +1 -0
- package/dist/components/header/components/profile.d.ts +1 -0
- package/dist/components/toast/__stories__/toast.stories.d.ts +13 -0
- package/dist/components/toast/components/toast.d.ts +20 -0
- package/dist/components/toast/index.d.ts +1 -0
- package/dist/config/__stories__/globals.stories.d.ts +10 -0
- package/dist/config/theme/components/accordion.d.ts +53 -0
- package/dist/config/theme/components/alert.d.ts +2 -2
- package/dist/config/theme/components/index.d.ts +1 -0
- package/dist/config/theme/components/switch.d.ts +9 -0
- package/dist/internal-ui.cjs.development.js +214 -127
- 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 +216 -129
- package/dist/internal-ui.esm.js.map +1 -1
- package/dist/provider/__stories__/provider.stories.d.ts +3 -0
- package/dist/provider/components/provider.d.ts +1 -0
- package/package.json +6 -4
package/dist/internal-ui.esm.js
CHANGED
@@ -18,10 +18,12 @@ import { AsyncPaginate } from 'react-select-async-paginate';
|
|
18
18
|
import ReactSelectAsyncCreatable from 'react-select/async-creatable';
|
19
19
|
import ReactSelectCreatable from 'react-select/creatable';
|
20
20
|
import { useDropzone } from 'react-dropzone';
|
21
|
-
import { alertAnatomy, checkboxAnatomy, inputAnatomy, popoverAnatomy, radioAnatomy, switchAnatomy, tableAnatomy } from '@chakra-ui/anatomy';
|
22
|
-
import { createMultiStyleConfigHelpers,
|
21
|
+
import { accordionAnatomy, alertAnatomy, checkboxAnatomy, inputAnatomy, popoverAnatomy, radioAnatomy, switchAnatomy, tableAnatomy } from '@chakra-ui/anatomy';
|
22
|
+
import { createMultiStyleConfigHelpers, defineStyle as defineStyle$1, cssVar, defineStyleConfig } from '@chakra-ui/styled-system';
|
23
23
|
import { mode, calc, cssVar as cssVar$1 } from '@chakra-ui/theme-tools';
|
24
24
|
import axios from 'axios';
|
25
|
+
import 'react-toastify/dist/ReactToastify.css';
|
26
|
+
import { ToastContainer } from 'react-toastify';
|
25
27
|
|
26
28
|
/* eslint-disable react/require-default-props */
|
27
29
|
function CheckIcon() {
|
@@ -135,6 +137,9 @@ const Loader = /*#__PURE__*/forwardRef$1((props, ref) => {
|
|
135
137
|
__css: styles
|
136
138
|
});
|
137
139
|
});
|
140
|
+
Loader.defaultProps = {
|
141
|
+
size: 'md'
|
142
|
+
};
|
138
143
|
|
139
144
|
const Button = /*#__PURE__*/forwardRef$1((props, ref) => {
|
140
145
|
const {
|
@@ -263,9 +268,6 @@ const Badge = props => {
|
|
263
268
|
} = props;
|
264
269
|
return /*#__PURE__*/React__default.createElement(Badge$2, Object.assign({
|
265
270
|
borderRadius: pill ? 'xl' : 'sm',
|
266
|
-
variant: "primary-solid",
|
267
|
-
px: "2",
|
268
|
-
h: "4.5",
|
269
271
|
display: "inline-flex",
|
270
272
|
alignItems: "center",
|
271
273
|
justifyContent: "space-between",
|
@@ -1978,6 +1980,7 @@ Logo.defaultProps = {
|
|
1978
1980
|
};
|
1979
1981
|
|
1980
1982
|
const Profile = ({
|
1983
|
+
color,
|
1981
1984
|
brandColor,
|
1982
1985
|
data,
|
1983
1986
|
onLogout
|
@@ -2001,17 +2004,19 @@ const Profile = ({
|
|
2001
2004
|
textDecor: 'none'
|
2002
2005
|
},
|
2003
2006
|
m: 0,
|
2004
|
-
onClick: onToggle
|
2007
|
+
onClick: onToggle,
|
2008
|
+
color: color
|
2005
2009
|
}, /*#__PURE__*/createElement(HStack, null, /*#__PURE__*/createElement(VStack, {
|
2006
2010
|
alignItems: "flex-end",
|
2007
2011
|
spacing: 0,
|
2008
2012
|
ml: "2",
|
2009
|
-
color:
|
2013
|
+
color: color
|
2010
2014
|
}, /*#__PURE__*/createElement(Text, {
|
2011
2015
|
textStyle: "text.xs",
|
2012
|
-
mb: 1
|
2013
|
-
|
2014
|
-
|
2016
|
+
mb: 1
|
2017
|
+
}, data === null || data === void 0 ? void 0 : data.email), /*#__PURE__*/createElement(Flex, {
|
2018
|
+
alignItems: "center"
|
2019
|
+
}, (data === null || data === void 0 ? void 0 : data.userRole) && /*#__PURE__*/createElement(Text, {
|
2015
2020
|
textStyle: "text.xs"
|
2016
2021
|
}, (data === null || data === void 0 ? void 0 : data.userRole) || 'user'), /*#__PURE__*/createElement(Box, {
|
2017
2022
|
h: "3",
|
@@ -2058,7 +2063,8 @@ const Profile = ({
|
|
2058
2063
|
Profile.defaultProps = {
|
2059
2064
|
brandColor: 'primary.500',
|
2060
2065
|
data: undefined,
|
2061
|
-
onLogout: undefined
|
2066
|
+
onLogout: undefined,
|
2067
|
+
color: undefined
|
2062
2068
|
};
|
2063
2069
|
|
2064
2070
|
const SwitchMode = () => {
|
@@ -2096,15 +2102,9 @@ const Version = ({
|
|
2096
2102
|
version,
|
2097
2103
|
environment,
|
2098
2104
|
onOpenModalRelease
|
2099
|
-
}) => /*#__PURE__*/createElement(Fragment, null, version && /*#__PURE__*/createElement(Badge
|
2105
|
+
}) => /*#__PURE__*/createElement(Fragment, null, version && /*#__PURE__*/createElement(Badge, {
|
2100
2106
|
"data-test-id": "dzl3esjhCphobaaIXpiUE",
|
2101
2107
|
variant: "neutral-light",
|
2102
|
-
textStyle: "text.xs",
|
2103
|
-
py: 1,
|
2104
|
-
px: 2.5,
|
2105
|
-
fontWeight: "semibold",
|
2106
|
-
textTransform: "lowercase",
|
2107
|
-
borderRadius: "md",
|
2108
2108
|
onClick: onOpenModalRelease,
|
2109
2109
|
cursor: onOpenModalRelease ? 'pointer' : 'auto'
|
2110
2110
|
}, version), !hideEnv && environmentName(environment) !== null && version && /*#__PURE__*/createElement(Box, {
|
@@ -2129,32 +2129,36 @@ const Header = ({
|
|
2129
2129
|
onLogout,
|
2130
2130
|
onOpenModalRelease,
|
2131
2131
|
hideSwitchMode,
|
2132
|
-
mainLogo
|
2133
|
-
centerLogo
|
2132
|
+
mainLogo,
|
2133
|
+
centerLogo,
|
2134
2134
|
mainLogoSize,
|
2135
2135
|
centerLogoSize = 4,
|
2136
2136
|
hideEnv = false,
|
2137
2137
|
urlLogo,
|
2138
2138
|
children,
|
2139
|
+
profile,
|
2139
2140
|
...props
|
2140
|
-
}) => /*#__PURE__*/createElement(
|
2141
|
+
}) => /*#__PURE__*/createElement(Flex, Object.assign({
|
2141
2142
|
minH: 15,
|
2142
|
-
bg:
|
2143
|
+
bg: props.bg,
|
2144
|
+
bgColor: props.bgColor,
|
2143
2145
|
shadow: "raised",
|
2144
2146
|
px: 6,
|
2145
|
-
py: 3
|
2147
|
+
py: 3,
|
2148
|
+
alignItems: "center"
|
2146
2149
|
}, props), /*#__PURE__*/createElement(Flex, {
|
2150
|
+
h: "auto",
|
2147
2151
|
w: "full",
|
2148
2152
|
alignItems: "center",
|
2149
|
-
justifyContent:
|
2153
|
+
justifyContent: profile ? 'flex-end' : 'space-between',
|
2150
2154
|
pos: "relative"
|
2151
|
-
}, /*#__PURE__*/createElement(Flex, {
|
2155
|
+
}, mainLogo && /*#__PURE__*/createElement(Flex, {
|
2152
2156
|
alignItems: "center"
|
2153
2157
|
}, /*#__PURE__*/createElement(Logo, {
|
2154
2158
|
url: urlLogo,
|
2155
2159
|
imageUrl: mainLogo,
|
2156
2160
|
height: mainLogoSize
|
2157
|
-
}), children && children), /*#__PURE__*/createElement(HStack, {
|
2161
|
+
}), children && children), centerLogo && /*#__PURE__*/createElement(HStack, {
|
2158
2162
|
w: "fit-content",
|
2159
2163
|
spacing: 2,
|
2160
2164
|
alignItems: "center",
|
@@ -2170,9 +2174,10 @@ const Header = ({
|
|
2170
2174
|
version: data === null || data === void 0 ? void 0 : data.version,
|
2171
2175
|
environment: data === null || data === void 0 ? void 0 : data.environment,
|
2172
2176
|
onOpenModalRelease: onOpenModalRelease
|
2173
|
-
})), /*#__PURE__*/createElement(Flex, {
|
2177
|
+
})), profile || /*#__PURE__*/createElement(Flex, {
|
2174
2178
|
alignItems: "center"
|
2175
2179
|
}, !hideSwitchMode && /*#__PURE__*/createElement(SwitchMode, null), /*#__PURE__*/createElement(Profile, {
|
2180
|
+
color: props.color,
|
2176
2181
|
brandColor: brandColor,
|
2177
2182
|
data: data,
|
2178
2183
|
onLogout: onLogout
|
@@ -2188,7 +2193,8 @@ Header.defaultProps = {
|
|
2188
2193
|
centerLogo: undefined,
|
2189
2194
|
centerLogoSize: undefined,
|
2190
2195
|
hideEnv: false,
|
2191
|
-
urlLogo: undefined
|
2196
|
+
urlLogo: undefined,
|
2197
|
+
profile: undefined
|
2192
2198
|
};
|
2193
2199
|
|
2194
2200
|
const ModalBody = /*#__PURE__*/React__default.forwardRef(({
|
@@ -3261,7 +3267,7 @@ const Tab = /*#__PURE__*/forwardRef$1((props, ref) => {
|
|
3261
3267
|
p: 4,
|
3262
3268
|
fontSize: "text.md",
|
3263
3269
|
_selected: {
|
3264
|
-
borderColor: 'primary.
|
3270
|
+
borderColor: 'primary.500',
|
3265
3271
|
color: 'primary.500',
|
3266
3272
|
transform: 'translateY(-2px)',
|
3267
3273
|
_hover: {
|
@@ -3397,50 +3403,97 @@ Uploader.defaultProps = {
|
|
3397
3403
|
const {
|
3398
3404
|
definePartsStyle,
|
3399
3405
|
defineMultiStyleConfig
|
3400
|
-
} = /*#__PURE__*/createMultiStyleConfigHelpers(
|
3401
|
-
const
|
3402
|
-
|
3403
|
-
|
3404
|
-
const
|
3405
|
-
|
3406
|
-
|
3407
|
-
|
3408
|
-
|
3409
|
-
|
3410
|
-
|
3411
|
-
|
3412
|
-
|
3413
|
-
textStyle: 'text.sm',
|
3414
|
-
marginEnd: '2'
|
3406
|
+
} = /*#__PURE__*/createMultiStyleConfigHelpers(accordionAnatomy.keys);
|
3407
|
+
const baseStyleContainer = /*#__PURE__*/defineStyle$1({
|
3408
|
+
border: 'none'
|
3409
|
+
});
|
3410
|
+
const baseStyleButton = /*#__PURE__*/defineStyle$1({
|
3411
|
+
height: 14,
|
3412
|
+
transitionProperty: 'common',
|
3413
|
+
transitionDuration: 'normal',
|
3414
|
+
gap: 4,
|
3415
|
+
fontSize: 'text.md',
|
3416
|
+
bg: 'neutral.50',
|
3417
|
+
_focusVisible: {
|
3418
|
+
bg: 'neutral.100'
|
3415
3419
|
},
|
3416
|
-
|
3417
|
-
|
3420
|
+
_hover: {
|
3421
|
+
bg: 'neutral.100'
|
3418
3422
|
},
|
3419
|
-
|
3420
|
-
|
3421
|
-
|
3422
|
-
marginEnd: '3',
|
3423
|
-
w: '4',
|
3424
|
-
h: '4'
|
3423
|
+
_disabled: {
|
3424
|
+
opacity: 0.4,
|
3425
|
+
cursor: 'not-allowed'
|
3425
3426
|
},
|
3426
|
-
|
3427
|
-
|
3428
|
-
|
3429
|
-
|
3427
|
+
py: 2,
|
3428
|
+
px: 4,
|
3429
|
+
position: 'relative'
|
3430
|
+
});
|
3431
|
+
const baseStylePanel = /*#__PURE__*/defineStyle$1({
|
3432
|
+
pt: '2',
|
3433
|
+
px: '4',
|
3434
|
+
pb: '5'
|
3435
|
+
});
|
3436
|
+
const baseStyleIcon = /*#__PURE__*/defineStyle$1({
|
3437
|
+
fontSize: '1.25em'
|
3438
|
+
});
|
3439
|
+
const baseStyle = /*#__PURE__*/definePartsStyle({
|
3440
|
+
container: baseStyleContainer,
|
3441
|
+
button: baseStyleButton,
|
3442
|
+
panel: baseStylePanel,
|
3443
|
+
icon: baseStyleIcon
|
3444
|
+
});
|
3445
|
+
const accordionTheme = /*#__PURE__*/defineMultiStyleConfig({
|
3446
|
+
baseStyle
|
3447
|
+
});
|
3448
|
+
|
3449
|
+
const {
|
3450
|
+
definePartsStyle: definePartsStyle$1,
|
3451
|
+
defineMultiStyleConfig: defineMultiStyleConfig$1
|
3452
|
+
} = /*#__PURE__*/createMultiStyleConfigHelpers(alertAnatomy.keys);
|
3453
|
+
const $fg = /*#__PURE__*/cssVar('alert-fg');
|
3454
|
+
const $bg = /*#__PURE__*/cssVar('alert-bg');
|
3455
|
+
const baseStyle$1 = /*#__PURE__*/definePartsStyle$1(props => {
|
3456
|
+
return {
|
3457
|
+
container: {
|
3458
|
+
bg: $bg.reference,
|
3459
|
+
px: '4',
|
3460
|
+
py: '2',
|
3461
|
+
borderRadius: 'sm'
|
3462
|
+
},
|
3463
|
+
title: {
|
3464
|
+
fontWeight: 'regular',
|
3465
|
+
textStyle: 'text.sm',
|
3466
|
+
marginEnd: '2'
|
3467
|
+
},
|
3468
|
+
description: {
|
3469
|
+
lineHeight: '6'
|
3470
|
+
},
|
3471
|
+
icon: {
|
3472
|
+
color: $fg.reference,
|
3473
|
+
flexShrink: 0,
|
3474
|
+
marginEnd: '3',
|
3475
|
+
w: '4',
|
3476
|
+
h: '4'
|
3477
|
+
},
|
3478
|
+
action: {
|
3479
|
+
color: props.colorScheme === 'neutral' && props.variant === 'light' ? 'primary.500' : 'inherit',
|
3480
|
+
'& +.chakra-alert__close': {
|
3481
|
+
ml: '3'
|
3482
|
+
}
|
3483
|
+
},
|
3484
|
+
close: {
|
3485
|
+
color: $fg.reference,
|
3486
|
+
w: '4',
|
3487
|
+
h: '4'
|
3488
|
+
},
|
3489
|
+
spinner: {
|
3490
|
+
color: $fg.reference,
|
3491
|
+
flexShrink: 0,
|
3492
|
+
marginEnd: '3',
|
3493
|
+
w: '5',
|
3494
|
+
h: '5'
|
3430
3495
|
}
|
3431
|
-
}
|
3432
|
-
close: {
|
3433
|
-
color: $fg.reference,
|
3434
|
-
w: '4',
|
3435
|
-
h: '4'
|
3436
|
-
},
|
3437
|
-
spinner: {
|
3438
|
-
color: $fg.reference,
|
3439
|
-
flexShrink: 0,
|
3440
|
-
marginEnd: '3',
|
3441
|
-
w: '5',
|
3442
|
-
h: '5'
|
3443
|
-
}
|
3496
|
+
};
|
3444
3497
|
});
|
3445
3498
|
function getBg(props) {
|
3446
3499
|
const {
|
@@ -3450,7 +3503,7 @@ function getBg(props) {
|
|
3450
3503
|
light: c === 'neutral' ? `colors.${c}.300` : `colors.${c}.50`
|
3451
3504
|
};
|
3452
3505
|
}
|
3453
|
-
const variantLight = /*#__PURE__*/definePartsStyle(props => {
|
3506
|
+
const variantLight = /*#__PURE__*/definePartsStyle$1(props => {
|
3454
3507
|
const {
|
3455
3508
|
colorScheme: c
|
3456
3509
|
} = props;
|
@@ -3463,7 +3516,7 @@ const variantLight = /*#__PURE__*/definePartsStyle(props => {
|
|
3463
3516
|
}
|
3464
3517
|
};
|
3465
3518
|
});
|
3466
|
-
const variantSolid = /*#__PURE__*/definePartsStyle(props => {
|
3519
|
+
const variantSolid = /*#__PURE__*/definePartsStyle$1(props => {
|
3467
3520
|
const {
|
3468
3521
|
colorScheme: c
|
3469
3522
|
} = props;
|
@@ -3478,8 +3531,8 @@ const variants = {
|
|
3478
3531
|
light: variantLight,
|
3479
3532
|
solid: variantSolid
|
3480
3533
|
};
|
3481
|
-
const alertTheme = /*#__PURE__*/defineMultiStyleConfig({
|
3482
|
-
baseStyle,
|
3534
|
+
const alertTheme = /*#__PURE__*/defineMultiStyleConfig$1({
|
3535
|
+
baseStyle: baseStyle$1,
|
3483
3536
|
variants,
|
3484
3537
|
defaultProps: {
|
3485
3538
|
variant: 'light',
|
@@ -3682,6 +3735,12 @@ const Button$1 = /*#__PURE__*/defineStyleConfig({
|
|
3682
3735
|
},
|
3683
3736
|
_disabled: {
|
3684
3737
|
border: 0
|
3738
|
+
},
|
3739
|
+
'.chakra-button__group[data-attached][data-orientation=horizontal] > &:not(:last-of-type)': {
|
3740
|
+
marginEnd: '-1px'
|
3741
|
+
},
|
3742
|
+
'.chakra-button__group[data-attached][data-orientation=vertical] > &:not(:last-of-type)': {
|
3743
|
+
marginBottom: '-1px'
|
3685
3744
|
}
|
3686
3745
|
};
|
3687
3746
|
const disabledLoading = {
|
@@ -3839,10 +3898,10 @@ const CardStyle = /*#__PURE__*/defineStyleConfig({
|
|
3839
3898
|
});
|
3840
3899
|
|
3841
3900
|
const {
|
3842
|
-
definePartsStyle: definePartsStyle$
|
3843
|
-
defineMultiStyleConfig: defineMultiStyleConfig$
|
3901
|
+
definePartsStyle: definePartsStyle$2,
|
3902
|
+
defineMultiStyleConfig: defineMultiStyleConfig$2
|
3844
3903
|
} = /*#__PURE__*/createMultiStyleConfigHelpers$1(checkboxAnatomy.keys);
|
3845
|
-
const baseStyle$
|
3904
|
+
const baseStyle$2 = /*#__PURE__*/definePartsStyle$2({
|
3846
3905
|
control: {
|
3847
3906
|
borderRadius: 'sm',
|
3848
3907
|
w: 4,
|
@@ -3864,7 +3923,7 @@ const baseStyle$1 = /*#__PURE__*/definePartsStyle$1({
|
|
3864
3923
|
cursor: 'not-allowed'
|
3865
3924
|
}
|
3866
3925
|
});
|
3867
|
-
const errors = /*#__PURE__*/definePartsStyle$
|
3926
|
+
const errors = /*#__PURE__*/definePartsStyle$2({
|
3868
3927
|
control: {
|
3869
3928
|
borderColor: 'danger.500',
|
3870
3929
|
_checked: {
|
@@ -3887,7 +3946,7 @@ const errors = /*#__PURE__*/definePartsStyle$1({
|
|
3887
3946
|
fontSize: '8px'
|
3888
3947
|
}
|
3889
3948
|
});
|
3890
|
-
const unstyled = /*#__PURE__*/definePartsStyle$
|
3949
|
+
const unstyled = /*#__PURE__*/definePartsStyle$2({
|
3891
3950
|
control: {
|
3892
3951
|
borderColor: 'neutral.600',
|
3893
3952
|
_checked: {
|
@@ -3931,8 +3990,8 @@ const variants$1 = {
|
|
3931
3990
|
errors,
|
3932
3991
|
unstyled
|
3933
3992
|
};
|
3934
|
-
const Checkbox = /*#__PURE__*/defineMultiStyleConfig$
|
3935
|
-
baseStyle: baseStyle$
|
3993
|
+
const Checkbox = /*#__PURE__*/defineMultiStyleConfig$2({
|
3994
|
+
baseStyle: baseStyle$2,
|
3936
3995
|
variants: variants$1,
|
3937
3996
|
defaultProps: {
|
3938
3997
|
variant: 'unstyled'
|
@@ -3980,7 +4039,10 @@ const Chips$1 = /*#__PURE__*/defineStyleConfig({
|
|
3980
4039
|
bg: 'neutral.200',
|
3981
4040
|
color: 'black.low',
|
3982
4041
|
borderColor: 'neutral.200',
|
3983
|
-
cursor: 'not-allowed'
|
4042
|
+
cursor: 'not-allowed',
|
4043
|
+
_hover: {
|
4044
|
+
bg: 'neutral.200'
|
4045
|
+
}
|
3984
4046
|
};
|
3985
4047
|
chipsProps = {
|
3986
4048
|
...chipsProps,
|
@@ -4005,21 +4067,21 @@ const Chips$1 = /*#__PURE__*/defineStyleConfig({
|
|
4005
4067
|
}
|
4006
4068
|
});
|
4007
4069
|
|
4008
|
-
const baseStyle$
|
4070
|
+
const baseStyle$3 = /*#__PURE__*/defineStyle$1({
|
4009
4071
|
fontSize: 'field.sm',
|
4010
4072
|
fontWeight: 'normal',
|
4011
4073
|
marginEnd: 1,
|
4012
4074
|
mb: 1
|
4013
4075
|
});
|
4014
4076
|
const FormLabel = /*#__PURE__*/defineStyleConfig({
|
4015
|
-
baseStyle: baseStyle$
|
4077
|
+
baseStyle: baseStyle$3
|
4016
4078
|
});
|
4017
4079
|
|
4018
4080
|
const {
|
4019
|
-
definePartsStyle: definePartsStyle$
|
4020
|
-
defineMultiStyleConfig: defineMultiStyleConfig$
|
4081
|
+
definePartsStyle: definePartsStyle$3,
|
4082
|
+
defineMultiStyleConfig: defineMultiStyleConfig$3
|
4021
4083
|
} = /*#__PURE__*/createMultiStyleConfigHelpers(inputAnatomy.keys);
|
4022
|
-
const baseStyle$
|
4084
|
+
const baseStyle$4 = /*#__PURE__*/definePartsStyle$3({
|
4023
4085
|
field: {
|
4024
4086
|
width: '100%',
|
4025
4087
|
minWidth: 0,
|
@@ -4062,20 +4124,20 @@ const size = {
|
|
4062
4124
|
})
|
4063
4125
|
};
|
4064
4126
|
const sizes = {
|
4065
|
-
lg: /*#__PURE__*/definePartsStyle$
|
4127
|
+
lg: /*#__PURE__*/definePartsStyle$3({
|
4066
4128
|
field: size.lg,
|
4067
4129
|
addon: size.lg
|
4068
4130
|
}),
|
4069
|
-
md: /*#__PURE__*/definePartsStyle$
|
4131
|
+
md: /*#__PURE__*/definePartsStyle$3({
|
4070
4132
|
field: size.md,
|
4071
4133
|
addon: size.md
|
4072
4134
|
}),
|
4073
|
-
sm: /*#__PURE__*/definePartsStyle$
|
4135
|
+
sm: /*#__PURE__*/definePartsStyle$3({
|
4074
4136
|
field: size.sm,
|
4075
4137
|
addon: size.sm
|
4076
4138
|
})
|
4077
4139
|
};
|
4078
|
-
const outline = /*#__PURE__*/definePartsStyle$
|
4140
|
+
const outline = /*#__PURE__*/definePartsStyle$3(props => {
|
4079
4141
|
const field = {
|
4080
4142
|
border: 0,
|
4081
4143
|
outline: 0,
|
@@ -4093,7 +4155,7 @@ const outline = /*#__PURE__*/definePartsStyle$2(props => {
|
|
4093
4155
|
field
|
4094
4156
|
};
|
4095
4157
|
});
|
4096
|
-
const unstyled$1 = /*#__PURE__*/definePartsStyle$
|
4158
|
+
const unstyled$1 = /*#__PURE__*/definePartsStyle$3({
|
4097
4159
|
field: {
|
4098
4160
|
bg: 'transparent',
|
4099
4161
|
px: '0',
|
@@ -4109,8 +4171,8 @@ const variants$2 = {
|
|
4109
4171
|
outline,
|
4110
4172
|
unstyled: unstyled$1
|
4111
4173
|
};
|
4112
|
-
const Input = /*#__PURE__*/defineMultiStyleConfig$
|
4113
|
-
baseStyle: baseStyle$
|
4174
|
+
const Input = /*#__PURE__*/defineMultiStyleConfig$3({
|
4175
|
+
baseStyle: baseStyle$4,
|
4114
4176
|
sizes,
|
4115
4177
|
variants: variants$2,
|
4116
4178
|
defaultProps: {
|
@@ -4129,6 +4191,9 @@ const rotate = /*#__PURE__*/keyframes({
|
|
4129
4191
|
}
|
4130
4192
|
});
|
4131
4193
|
const getLoaderColor = color => {
|
4194
|
+
if (!color) {
|
4195
|
+
return 'var(--chakra-colors-white-high)';
|
4196
|
+
}
|
4132
4197
|
const colorValue = color.split('.');
|
4133
4198
|
let backgroundColor;
|
4134
4199
|
switch (colorValue.length) {
|
@@ -4231,10 +4296,10 @@ const LoaderStyle = /*#__PURE__*/defineStyleConfig({
|
|
4231
4296
|
});
|
4232
4297
|
|
4233
4298
|
const {
|
4234
|
-
definePartsStyle: definePartsStyle$
|
4299
|
+
definePartsStyle: definePartsStyle$4
|
4235
4300
|
} = /*#__PURE__*/createMultiStyleConfigHelpers(popoverAnatomy.keys);
|
4236
4301
|
const Popover = {
|
4237
|
-
baseStyle: props => definePartsStyle$
|
4302
|
+
baseStyle: props => definePartsStyle$4({
|
4238
4303
|
popper: {
|
4239
4304
|
background: mode('white', 'inherit')(props)
|
4240
4305
|
}
|
@@ -4242,10 +4307,10 @@ const Popover = {
|
|
4242
4307
|
};
|
4243
4308
|
|
4244
4309
|
const {
|
4245
|
-
definePartsStyle: definePartsStyle$
|
4246
|
-
defineMultiStyleConfig: defineMultiStyleConfig$
|
4310
|
+
definePartsStyle: definePartsStyle$5,
|
4311
|
+
defineMultiStyleConfig: defineMultiStyleConfig$4
|
4247
4312
|
} = /*#__PURE__*/createMultiStyleConfigHelpers$1(radioAnatomy.keys);
|
4248
|
-
const baseStyle$
|
4313
|
+
const baseStyle$5 = /*#__PURE__*/definePartsStyle$5({
|
4249
4314
|
control: {
|
4250
4315
|
border: '1px solid',
|
4251
4316
|
width: '16px',
|
@@ -4261,7 +4326,7 @@ const baseStyle$4 = /*#__PURE__*/definePartsStyle$4({
|
|
4261
4326
|
}
|
4262
4327
|
}
|
4263
4328
|
});
|
4264
|
-
const errors$1 = /*#__PURE__*/definePartsStyle$
|
4329
|
+
const errors$1 = /*#__PURE__*/definePartsStyle$5({
|
4265
4330
|
control: {
|
4266
4331
|
borderColor: 'danger.500',
|
4267
4332
|
_checked: {
|
@@ -4296,7 +4361,7 @@ const errors$1 = /*#__PURE__*/definePartsStyle$4({
|
|
4296
4361
|
fontSize: '12px'
|
4297
4362
|
}
|
4298
4363
|
});
|
4299
|
-
const unstyled$2 = /*#__PURE__*/definePartsStyle$
|
4364
|
+
const unstyled$2 = /*#__PURE__*/definePartsStyle$5({
|
4300
4365
|
control: {
|
4301
4366
|
borderColor: 'neutral.600',
|
4302
4367
|
_checked: {
|
@@ -4335,8 +4400,8 @@ const variants$3 = {
|
|
4335
4400
|
errors: errors$1,
|
4336
4401
|
unstyled: unstyled$2
|
4337
4402
|
};
|
4338
|
-
const Radio = /*#__PURE__*/defineMultiStyleConfig$
|
4339
|
-
baseStyle: baseStyle$
|
4403
|
+
const Radio = /*#__PURE__*/defineMultiStyleConfig$4({
|
4404
|
+
baseStyle: baseStyle$5,
|
4340
4405
|
variants: variants$3,
|
4341
4406
|
defaultProps: {
|
4342
4407
|
variant: 'unstyled'
|
@@ -4344,8 +4409,8 @@ const Radio = /*#__PURE__*/defineMultiStyleConfig$3({
|
|
4344
4409
|
});
|
4345
4410
|
|
4346
4411
|
const {
|
4347
|
-
defineMultiStyleConfig: defineMultiStyleConfig$
|
4348
|
-
definePartsStyle: definePartsStyle$
|
4412
|
+
defineMultiStyleConfig: defineMultiStyleConfig$5,
|
4413
|
+
definePartsStyle: definePartsStyle$6
|
4349
4414
|
} = /*#__PURE__*/createMultiStyleConfigHelpers(switchAnatomy.keys);
|
4350
4415
|
const $width = /*#__PURE__*/cssVar$1('switch-track-width');
|
4351
4416
|
const $height = /*#__PURE__*/cssVar$1('switch-track-height');
|
@@ -4363,7 +4428,7 @@ const baseStyleThumb = /*#__PURE__*/defineStyle$1({
|
|
4363
4428
|
transform: `translateX(${$translateX.reference})`
|
4364
4429
|
}
|
4365
4430
|
});
|
4366
|
-
const baseStyle$
|
4431
|
+
const baseStyle$6 = /*#__PURE__*/definePartsStyle$6(() => ({
|
4367
4432
|
container: {
|
4368
4433
|
[$diff.variable]: diffValue,
|
4369
4434
|
[$translateX.variable]: $diff.reference,
|
@@ -4388,27 +4453,39 @@ const baseStyle$5 = /*#__PURE__*/definePartsStyle$5(() => ({
|
|
4388
4453
|
thumb: baseStyleThumb
|
4389
4454
|
}));
|
4390
4455
|
const sizes$1 = {
|
4391
|
-
sm: /*#__PURE__*/definePartsStyle$
|
4456
|
+
sm: /*#__PURE__*/definePartsStyle$6({
|
4392
4457
|
container: {
|
4393
|
-
[$width.variable]: '
|
4394
|
-
[$height.variable]: '
|
4458
|
+
[$width.variable]: '1.875rem',
|
4459
|
+
[$height.variable]: '0.75rem'
|
4460
|
+
},
|
4461
|
+
thumb: {
|
4462
|
+
[$width.variable]: '0.75rem',
|
4463
|
+
[$height.variable]: '0.75rem'
|
4395
4464
|
}
|
4396
4465
|
}),
|
4397
|
-
md: /*#__PURE__*/definePartsStyle$
|
4466
|
+
md: /*#__PURE__*/definePartsStyle$6({
|
4398
4467
|
container: {
|
4399
|
-
[$width.variable]: '2.
|
4400
|
-
[$height.variable]: '
|
4468
|
+
[$width.variable]: '2.375rem',
|
4469
|
+
[$height.variable]: '1rem'
|
4470
|
+
},
|
4471
|
+
thumb: {
|
4472
|
+
[$width.variable]: '1rem',
|
4473
|
+
[$height.variable]: '1rem'
|
4401
4474
|
}
|
4402
4475
|
}),
|
4403
|
-
lg: /*#__PURE__*/definePartsStyle$
|
4476
|
+
lg: /*#__PURE__*/definePartsStyle$6({
|
4404
4477
|
container: {
|
4405
|
-
[$width.variable]: '3.
|
4406
|
-
[$height.variable]: '1.
|
4478
|
+
[$width.variable]: '3.25rem',
|
4479
|
+
[$height.variable]: '1.375rem'
|
4480
|
+
},
|
4481
|
+
thumb: {
|
4482
|
+
[$width.variable]: '1.375rem',
|
4483
|
+
[$height.variable]: '1.375rem'
|
4407
4484
|
}
|
4408
4485
|
})
|
4409
4486
|
};
|
4410
|
-
const Switch$1 = /*#__PURE__*/defineMultiStyleConfig$
|
4411
|
-
baseStyle: baseStyle$
|
4487
|
+
const Switch$1 = /*#__PURE__*/defineMultiStyleConfig$5({
|
4488
|
+
baseStyle: baseStyle$6,
|
4412
4489
|
sizes: sizes$1,
|
4413
4490
|
defaultProps: {
|
4414
4491
|
size: 'md'
|
@@ -4416,10 +4493,10 @@ const Switch$1 = /*#__PURE__*/defineMultiStyleConfig$4({
|
|
4416
4493
|
});
|
4417
4494
|
|
4418
4495
|
const {
|
4419
|
-
defineMultiStyleConfig: defineMultiStyleConfig$
|
4420
|
-
definePartsStyle: definePartsStyle$
|
4496
|
+
defineMultiStyleConfig: defineMultiStyleConfig$6,
|
4497
|
+
definePartsStyle: definePartsStyle$7
|
4421
4498
|
} = /*#__PURE__*/createMultiStyleConfigHelpers(tableAnatomy.keys);
|
4422
|
-
const baseStyle$
|
4499
|
+
const baseStyle$7 = /*#__PURE__*/definePartsStyle$7({
|
4423
4500
|
table: {
|
4424
4501
|
fontVariantNumeric: 'lining-nums tabular-nums',
|
4425
4502
|
borderCollapse: 'collapse',
|
@@ -4452,7 +4529,7 @@ const numericStyles = /*#__PURE__*/defineStyle$1({
|
|
4452
4529
|
textAlign: 'end'
|
4453
4530
|
}
|
4454
4531
|
});
|
4455
|
-
const variantSimple = /*#__PURE__*/definePartsStyle$
|
4532
|
+
const variantSimple = /*#__PURE__*/definePartsStyle$7(props => {
|
4456
4533
|
const {
|
4457
4534
|
colorScheme: c
|
4458
4535
|
} = props;
|
@@ -4482,7 +4559,7 @@ const variantSimple = /*#__PURE__*/definePartsStyle$6(props => {
|
|
4482
4559
|
}
|
4483
4560
|
};
|
4484
4561
|
});
|
4485
|
-
const variantStripe = /*#__PURE__*/definePartsStyle$
|
4562
|
+
const variantStripe = /*#__PURE__*/definePartsStyle$7(props => {
|
4486
4563
|
const {
|
4487
4564
|
colorScheme: c
|
4488
4565
|
} = props;
|
@@ -4531,7 +4608,7 @@ const variants$4 = {
|
|
4531
4608
|
unstyled: /*#__PURE__*/defineStyle$1({})
|
4532
4609
|
};
|
4533
4610
|
const sizes$2 = {
|
4534
|
-
sm: /*#__PURE__*/definePartsStyle$
|
4611
|
+
sm: /*#__PURE__*/definePartsStyle$7({
|
4535
4612
|
th: {
|
4536
4613
|
px: '4',
|
4537
4614
|
py: '1',
|
@@ -4550,7 +4627,7 @@ const sizes$2 = {
|
|
4550
4627
|
fontSize: 'xs'
|
4551
4628
|
}
|
4552
4629
|
}),
|
4553
|
-
md: /*#__PURE__*/definePartsStyle$
|
4630
|
+
md: /*#__PURE__*/definePartsStyle$7({
|
4554
4631
|
th: {
|
4555
4632
|
px: '2',
|
4556
4633
|
py: '4',
|
@@ -4580,7 +4657,7 @@ const sizes$2 = {
|
|
4580
4657
|
fontSize: 'sm'
|
4581
4658
|
}
|
4582
4659
|
}),
|
4583
|
-
lg: /*#__PURE__*/definePartsStyle$
|
4660
|
+
lg: /*#__PURE__*/definePartsStyle$7({
|
4584
4661
|
th: {
|
4585
4662
|
px: '8',
|
4586
4663
|
py: '4',
|
@@ -4599,8 +4676,8 @@ const sizes$2 = {
|
|
4599
4676
|
}
|
4600
4677
|
})
|
4601
4678
|
};
|
4602
|
-
const tableTheme = /*#__PURE__*/defineMultiStyleConfig$
|
4603
|
-
baseStyle: baseStyle$
|
4679
|
+
const tableTheme = /*#__PURE__*/defineMultiStyleConfig$6({
|
4680
|
+
baseStyle: baseStyle$7,
|
4604
4681
|
variants: variants$4,
|
4605
4682
|
sizes: sizes$2,
|
4606
4683
|
defaultProps: {
|
@@ -4693,6 +4770,7 @@ const Textarea = /*#__PURE__*/defineStyleConfig$1({
|
|
4693
4770
|
|
4694
4771
|
var components = {
|
4695
4772
|
__proto__: null,
|
4773
|
+
Accordion: accordionTheme,
|
4696
4774
|
Alert: alertTheme,
|
4697
4775
|
Badge: Badge$1,
|
4698
4776
|
Button: Button$1,
|
@@ -4721,8 +4799,17 @@ const getTheme = foundations => {
|
|
4721
4799
|
},
|
4722
4800
|
styles: {
|
4723
4801
|
global: {
|
4724
|
-
'
|
4725
|
-
|
4802
|
+
'&::-webkit-scrollbar': {
|
4803
|
+
width: '10px',
|
4804
|
+
height: '10px'
|
4805
|
+
},
|
4806
|
+
'&::-webkit-scrollbar-track': {
|
4807
|
+
background: 'white'
|
4808
|
+
},
|
4809
|
+
'&::-webkit-scrollbar-thumb': {
|
4810
|
+
background: 'neutral.400',
|
4811
|
+
borderRadius: '24px',
|
4812
|
+
border: '2px solid white'
|
4726
4813
|
},
|
4727
4814
|
body: {
|
4728
4815
|
fontSize: 'text.sm',
|
@@ -4782,7 +4869,7 @@ const Provider = ({
|
|
4782
4869
|
}), []);
|
4783
4870
|
return /*#__PURE__*/React__default.createElement(ProviderContext.Provider, {
|
4784
4871
|
value: provider
|
4785
|
-
}, children);
|
4872
|
+
}, /*#__PURE__*/React__default.createElement(ToastContainer, null), children);
|
4786
4873
|
};
|
4787
4874
|
Provider.displayName = 'Provider';
|
4788
4875
|
|