@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
package/dist/internal-ui.esm.js
CHANGED
@@ -4,9 +4,9 @@ import React__default, { createElement, forwardRef as forwardRef$2, useMemo, use
|
|
4
4
|
import { createContext } from '@chakra-ui/react-context';
|
5
5
|
import { CheckCircle, Info, AlertTriangle, Close, EyeOff, Eye, Rating as Rating$1, Check } from '@ctlyst.id/internal-icon';
|
6
6
|
import { cx as cx$1 } from '@chakra-ui/utils';
|
7
|
-
import { forwardRef as forwardRef$1, useStyleConfig, Box, Button as Button$2, Badge as Badge$2, useToken,
|
7
|
+
import { forwardRef as forwardRef$1, useStyleConfig, Box, Button as Button$2, Badge as Badge$2, useToken, theme as theme$1, Text, Breadcrumb, BreadcrumbItem, BreadcrumbLink, Card, Checkbox as Checkbox$1, FormControl, FormLabel as FormLabel$1, FormHelperText, FormErrorMessage, CheckboxGroup, Stack, Flex, Spinner, Table, Thead, Tr, useColorModeValue, Th, Tbody, Td, defineStyle, InputGroup, Input as Input$1, InputRightAddon, InputRightElement, InputLeftAddon, Textarea as Textarea$1, Image, useDisclosure, Popover as Popover$1, HStack, VStack, PopoverTrigger, Avatar, PopoverContent, PopoverArrow, PopoverBody, useColorMode as useColorMode$1, ModalBody as ModalBody$1, ModalCloseButton as ModalCloseButton$1, ModalFooter as ModalFooter$1, ModalHeader as ModalHeader$1, createIcon, Icon, Portal, Link, VisuallyHidden, Select as Select$1, Radio as Radio$1, RadioGroup, Grid, useMultiStyleConfig as useMultiStyleConfig$1, omitThemingProps as omitThemingProps$1, useCheckbox, chakra as chakra$1, useTab, TabList as TabList$1, TabPanel as TabPanel$1, Heading, createMultiStyleConfigHelpers as createMultiStyleConfigHelpers$1, defineStyleConfig as defineStyleConfig$1, extendTheme } from '@chakra-ui/react';
|
8
8
|
export { AlertDialog, ModalBody as AlertDialogBody, ModalCloseButton as AlertDialogCloseButton, AlertDialogContent, ModalFooter as AlertDialogFooter, ModalHeader as AlertDialogHeader, ModalOverlay as AlertDialogOverlay, Box, ButtonGroup, Center, ChakraProvider, Table as ChakraTable, CloseButton, Code, Collapse, ColorModeScript, Container, Divider, Drawer, ModalBody as DrawerBody, ModalCloseButton as DrawerCloseButton, DrawerContent, ModalFooter as DrawerFooter, ModalHeader as DrawerHeader, ModalOverlay as DrawerOverlay, Flex, FormControl, FormErrorMessage, FormHelperText, FormLabel, Grid, GridItem, HStack, Heading, Icon, IconButton, Image, InputLeftElement as InputElementLeft, InputRightElement as InputElementRight, InputGroup, InputLeftAddon, InputLeftElement, InputRightAddon, InputRightElement, Link, List, ListIcon, ListItem, Modal, ModalContent, ModalContextProvider, ModalFocusScope, ModalOverlay, OrderedList, Popover, PopoverAnchor, PopoverArrow, PopoverBody, PopoverCloseButton, PopoverContent, PopoverFooter, PopoverHeader, PopoverTrigger, Portal, RequiredIndicator, ScaleFade, SimpleGrid, Skeleton, Spacer, Stack, TabIndicator, TabPanels, Tabs, TabsDescendantsProvider, TabsProvider, Tbody, Td, Text, Th, Thead, Tooltip, Tr, UnorderedList, VStack, Wrap, WrapItem, extendTheme, forwardRef, useBoolean, useColorMode, useColorModeValue, useDisclosure, useDrawerContext, useModal, useModalContext, useModalStyles, useTab, useTabIndicator, useTabList, useTabPanel, useTabPanels, useTabs, useTabsContext, useTabsDescendant, useTabsDescendants, useTabsDescendantsContext, useTabsStyles, useToken } from '@chakra-ui/react';
|
9
|
-
import { FiChevronsRight, FiHome, FiCalendar, FiX, FiPower, FiMoon, FiSun, FiShoppingBag, FiShoppingCart, FiRepeat, FiBox, FiLayers, FiDollarSign, FiUsers, FiRotateCcw, FiSettings, FiLayout, FiGift, FiChevronDown } from 'react-icons/fi';
|
9
|
+
import { FiChevronLeft, FiChevronsRight, FiHome, FiCalendar, FiX, FiPower, FiMoon, FiSun, FiShoppingBag, FiShoppingCart, FiRepeat, FiBox, FiLayers, FiDollarSign, FiUsers, FiRotateCcw, FiSettings, FiLayout, FiGift, FiChevronDown } from 'react-icons/fi';
|
10
10
|
import { ChevronUpIcon, ChevronDownIcon, UpDownIcon, ArrowLeftIcon, ChevronLeftIcon, ChevronRightIcon, ArrowRightIcon } from '@chakra-ui/icons';
|
11
11
|
import { css, Global, keyframes } from '@emotion/react';
|
12
12
|
import { useReactTable, getCoreRowModel, getSortedRowModel, flexRender } from '@tanstack/react-table';
|
@@ -20,7 +20,7 @@ import ReactSelectCreatable from 'react-select/creatable';
|
|
20
20
|
import { useDropzone } from 'react-dropzone';
|
21
21
|
import { alertAnatomy, checkboxAnatomy, inputAnatomy, popoverAnatomy, radioAnatomy, switchAnatomy, tableAnatomy } from '@chakra-ui/anatomy';
|
22
22
|
import { createMultiStyleConfigHelpers, cssVar, defineStyleConfig, defineStyle as defineStyle$1 } from '@chakra-ui/styled-system';
|
23
|
-
import {
|
23
|
+
import { mode, calc, cssVar as cssVar$1 } from '@chakra-ui/theme-tools';
|
24
24
|
import axios from 'axios';
|
25
25
|
|
26
26
|
/* eslint-disable react/require-default-props */
|
@@ -69,6 +69,10 @@ const STATUSES = {
|
|
69
69
|
error: {
|
70
70
|
icon: WarningIcon,
|
71
71
|
colorScheme: 'danger'
|
72
|
+
},
|
73
|
+
neutral: {
|
74
|
+
icon: InfoIcon,
|
75
|
+
colorScheme: 'neutral'
|
72
76
|
}
|
73
77
|
};
|
74
78
|
function getStatusColorScheme(status) {
|
@@ -168,10 +172,9 @@ function AlertAction({
|
|
168
172
|
const css = styles.action;
|
169
173
|
return /*#__PURE__*/React__default.createElement(Button, {
|
170
174
|
"data-test-id": "alert-action",
|
171
|
-
className: cx$1('chakra-
|
175
|
+
className: cx$1('chakra-alert__action', className),
|
172
176
|
variant: "link",
|
173
|
-
|
174
|
-
fontWeight: "700",
|
177
|
+
fontWeight: "semibold",
|
175
178
|
__css: css
|
176
179
|
}, children);
|
177
180
|
}
|
@@ -259,10 +262,10 @@ const Badge = props => {
|
|
259
262
|
...rest
|
260
263
|
} = props;
|
261
264
|
return /*#__PURE__*/React__default.createElement(Badge$2, Object.assign({
|
262
|
-
borderRadius: pill ?
|
265
|
+
borderRadius: pill ? 'xl' : 'sm',
|
263
266
|
variant: "primary-solid",
|
264
|
-
|
265
|
-
|
267
|
+
px: "2",
|
268
|
+
h: "4.5",
|
266
269
|
display: "inline-flex",
|
267
270
|
alignItems: "center",
|
268
271
|
justifyContent: "space-between",
|
@@ -281,9 +284,10 @@ const BreadCrumb = props => {
|
|
281
284
|
parents,
|
282
285
|
className,
|
283
286
|
disableHome,
|
284
|
-
spacing = 2
|
287
|
+
spacing = 2,
|
288
|
+
backButton
|
285
289
|
} = props;
|
286
|
-
const [
|
290
|
+
const [neutral600, primary500] = useToken('colors', ['neutral.600', 'primary.500']);
|
287
291
|
return /*#__PURE__*/createElement(Box, {
|
288
292
|
"data-test-id": "CT_component_breadcrumb_breadcrumb",
|
289
293
|
className: className,
|
@@ -294,22 +298,29 @@ const BreadCrumb = props => {
|
|
294
298
|
}, /*#__PURE__*/createElement(Box, {
|
295
299
|
display: "flex",
|
296
300
|
alignItems: "center"
|
297
|
-
}, /*#__PURE__*/createElement(
|
298
|
-
|
299
|
-
|
300
|
-
|
301
|
-
|
301
|
+
}, backButton && /*#__PURE__*/createElement(Button, {
|
302
|
+
variant: "icon",
|
303
|
+
"data-test-id": "button",
|
304
|
+
size: "md",
|
305
|
+
mr: "2",
|
306
|
+
onClick: backButton
|
307
|
+
}, /*#__PURE__*/createElement(FiChevronLeft, {
|
308
|
+
size: theme$1.sizes[5]
|
309
|
+
})), /*#__PURE__*/createElement(Text, {
|
310
|
+
pr: "2",
|
311
|
+
textStyle: "heading.6",
|
312
|
+
color: "neutral.700"
|
302
313
|
}, title), /*#__PURE__*/createElement(Box, {
|
303
|
-
h: "
|
314
|
+
h: "5.5",
|
304
315
|
borderLeft: "1px solid",
|
305
|
-
borderColor:
|
316
|
+
borderColor: neutral600
|
306
317
|
}), /*#__PURE__*/createElement(Breadcrumb, {
|
307
318
|
separator: /*#__PURE__*/createElement(FiChevronsRight, {
|
308
|
-
color:
|
309
|
-
size:
|
319
|
+
color: neutral600,
|
320
|
+
size: theme$1.sizes['3.5']
|
310
321
|
}),
|
311
|
-
pl: 2
|
312
|
-
pr: 4,
|
322
|
+
pl: "2",
|
323
|
+
pr: "4",
|
313
324
|
spacing: spacing,
|
314
325
|
sx: {
|
315
326
|
ol: {
|
@@ -329,8 +340,8 @@ const BreadCrumb = props => {
|
|
329
340
|
}
|
330
341
|
}, /*#__PURE__*/createElement(FiHome, {
|
331
342
|
className: "align-top",
|
332
|
-
size:
|
333
|
-
color:
|
343
|
+
size: theme$1.sizes['3.5'],
|
344
|
+
color: primary500
|
334
345
|
}))), parents === null || parents === void 0 ? void 0 : parents.map(val => /*#__PURE__*/createElement(BreadcrumbItem, {
|
335
346
|
key: val.name
|
336
347
|
}, /*#__PURE__*/createElement(BreadcrumbLink, {
|
@@ -346,18 +357,16 @@ const BreadCrumb = props => {
|
|
346
357
|
textDecoration: 'none'
|
347
358
|
}
|
348
359
|
}, /*#__PURE__*/createElement(Text, {
|
349
|
-
color: val.disable ?
|
350
|
-
|
351
|
-
fontWeight: 400
|
360
|
+
color: val.disable ? neutral600 : primary500,
|
361
|
+
textStyle: "text.sm"
|
352
362
|
}, val.name)))), /*#__PURE__*/createElement(BreadcrumbItem, null, /*#__PURE__*/createElement(BreadcrumbLink, {
|
353
363
|
_hover: {
|
354
364
|
textDecor: 'none',
|
355
365
|
cursor: 'default'
|
356
366
|
}
|
357
367
|
}, /*#__PURE__*/createElement(Text, {
|
358
|
-
color:
|
359
|
-
|
360
|
-
fontWeight: 400
|
368
|
+
color: "neutral.600",
|
369
|
+
textStyle: "text.sm"
|
361
370
|
}, title))))), children && /*#__PURE__*/createElement(Box, null, children));
|
362
371
|
};
|
363
372
|
BreadCrumb.defaultProps = {
|
@@ -365,7 +374,8 @@ BreadCrumb.defaultProps = {
|
|
365
374
|
parents: undefined,
|
366
375
|
className: undefined,
|
367
376
|
disableHome: undefined,
|
368
|
-
spacing: 2
|
377
|
+
spacing: 2,
|
378
|
+
backButton: undefined
|
369
379
|
};
|
370
380
|
|
371
381
|
const CardCustom = /*#__PURE__*/forwardRef$2(({
|
@@ -1937,17 +1947,22 @@ TextareaField.defaultProps = {
|
|
1937
1947
|
isLoading: undefined
|
1938
1948
|
};
|
1939
1949
|
|
1940
|
-
const
|
1941
|
-
|
1942
|
-
|
1943
|
-
})
|
1944
|
-
|
1945
|
-
|
1946
|
-
|
1947
|
-
|
1950
|
+
const Logo = ({
|
1951
|
+
imageUrl,
|
1952
|
+
height
|
1953
|
+
}) => /*#__PURE__*/React__default.createElement(Image, {
|
1954
|
+
w: "100%",
|
1955
|
+
h: height !== null && height !== void 0 ? height : 9,
|
1956
|
+
maxH: height !== null && height !== void 0 ? height : 9,
|
1957
|
+
src: imageUrl,
|
1958
|
+
alt: imageUrl
|
1948
1959
|
});
|
1960
|
+
Logo.defaultProps = {
|
1961
|
+
height: undefined
|
1962
|
+
};
|
1949
1963
|
|
1950
1964
|
const Profile = ({
|
1965
|
+
brandColor,
|
1951
1966
|
data,
|
1952
1967
|
onLogout
|
1953
1968
|
}) => {
|
@@ -1973,27 +1988,31 @@ const Profile = ({
|
|
1973
1988
|
onClick: onToggle
|
1974
1989
|
}, /*#__PURE__*/createElement(HStack, null, /*#__PURE__*/createElement(VStack, {
|
1975
1990
|
alignItems: "flex-end",
|
1976
|
-
spacing:
|
1977
|
-
ml: "2"
|
1991
|
+
spacing: 0,
|
1992
|
+
ml: "2",
|
1993
|
+
color: "primary.500"
|
1978
1994
|
}, /*#__PURE__*/createElement(Text, {
|
1979
|
-
|
1995
|
+
textStyle: "text.xs",
|
1980
1996
|
mb: 1,
|
1981
|
-
|
1982
|
-
|
1983
|
-
|
1984
|
-
}, data === null || data === void 0 ? void 0 : data.
|
1985
|
-
|
1986
|
-
|
1987
|
-
|
1988
|
-
|
1989
|
-
}, (data === null || data === void 0 ? void 0 : data.office)
|
1990
|
-
|
1991
|
-
|
1992
|
-
|
1993
|
-
|
1994
|
-
|
1995
|
-
|
1996
|
-
|
1997
|
+
color: "neutral.800"
|
1998
|
+
}, data === null || data === void 0 ? void 0 : data.email), /*#__PURE__*/createElement(Flex, null, (data === null || data === void 0 ? void 0 : data.userRole) && /*#__PURE__*/createElement(Text, {
|
1999
|
+
textStyle: "text.xs"
|
2000
|
+
}, (data === null || data === void 0 ? void 0 : data.userRole) || 'user'), /*#__PURE__*/createElement(Box, {
|
2001
|
+
h: "3",
|
2002
|
+
mx: "1",
|
2003
|
+
borderLeft: "1px solid",
|
2004
|
+
borderColor: "neutral.400"
|
2005
|
+
}), typeof (data === null || data === void 0 ? void 0 : data.office) === 'object' ? /*#__PURE__*/createElement(Fragment, null, /*#__PURE__*/createElement(Text, {
|
2006
|
+
textStyle: "text.xs"
|
2007
|
+
}, data.office[0]), data.office.length > 1 && /*#__PURE__*/createElement(Badge, {
|
2008
|
+
ml: "1",
|
2009
|
+
pill: true,
|
2010
|
+
variant: "neutral-light"
|
2011
|
+
}, data.office.length - 1, "+")) : /*#__PURE__*/createElement(Text, {
|
2012
|
+
textStyle: "text.xs"
|
2013
|
+
}, (data === null || data === void 0 ? void 0 : data.office) || 'office'))), /*#__PURE__*/createElement(PopoverTrigger, null, /*#__PURE__*/createElement(Avatar, {
|
2014
|
+
size: "sm",
|
2015
|
+
bg: brandColor,
|
1997
2016
|
color: "white",
|
1998
2017
|
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
|
1999
2018
|
})))), /*#__PURE__*/createElement(PopoverContent, {
|
@@ -2015,12 +2034,13 @@ const Profile = ({
|
|
2015
2034
|
color: 'white'
|
2016
2035
|
},
|
2017
2036
|
onClick: onLogout,
|
2018
|
-
|
2037
|
+
textStyle: "text.xs"
|
2019
2038
|
}, /*#__PURE__*/createElement(FiPower, null), /*#__PURE__*/createElement(Text, {
|
2020
2039
|
ml: 2
|
2021
2040
|
}, "Logout")))));
|
2022
2041
|
};
|
2023
2042
|
Profile.defaultProps = {
|
2043
|
+
brandColor: 'primary.500',
|
2024
2044
|
data: undefined,
|
2025
2045
|
onLogout: undefined
|
2026
2046
|
};
|
@@ -2056,22 +2076,22 @@ function environmentName(env) {
|
|
2056
2076
|
|
2057
2077
|
/* eslint-disable react-hooks/rules-of-hooks */
|
2058
2078
|
const Version = ({
|
2079
|
+
hideEnv,
|
2059
2080
|
version,
|
2060
2081
|
environment,
|
2061
2082
|
onOpenModalRelease
|
2062
2083
|
}) => /*#__PURE__*/createElement(Fragment, null, version && /*#__PURE__*/createElement(Badge$2, {
|
2063
2084
|
"data-test-id": "dzl3esjhCphobaaIXpiUE",
|
2064
|
-
|
2065
|
-
|
2066
|
-
fontSize: "text.xs",
|
2085
|
+
variant: "neutral-light",
|
2086
|
+
textStyle: "text.xs",
|
2067
2087
|
py: 1,
|
2068
2088
|
px: 2.5,
|
2069
|
-
fontWeight: "
|
2089
|
+
fontWeight: "semibold",
|
2070
2090
|
textTransform: "lowercase",
|
2071
2091
|
borderRadius: "md",
|
2072
2092
|
onClick: onOpenModalRelease,
|
2073
2093
|
cursor: onOpenModalRelease ? 'pointer' : 'auto'
|
2074
|
-
}, version), environmentName(environment) !== null && version && /*#__PURE__*/createElement(Box, {
|
2094
|
+
}, version), !hideEnv && environmentName(environment) !== null && version && /*#__PURE__*/createElement(Box, {
|
2075
2095
|
background: "primary.50",
|
2076
2096
|
color: "primary.500",
|
2077
2097
|
fontSize: "text.xs",
|
@@ -2081,45 +2101,74 @@ const Version = ({
|
|
2081
2101
|
borderRadius: "md"
|
2082
2102
|
}, environmentName(environment)));
|
2083
2103
|
Version.defaultProps = {
|
2104
|
+
hideEnv: false,
|
2084
2105
|
environment: undefined,
|
2085
2106
|
version: undefined,
|
2086
2107
|
onOpenModalRelease: undefined
|
2087
2108
|
};
|
2088
2109
|
|
2089
2110
|
const Header = ({
|
2111
|
+
brandColor,
|
2090
2112
|
data,
|
2091
2113
|
onLogout,
|
2092
2114
|
onOpenModalRelease,
|
2093
2115
|
hideSwitchMode,
|
2116
|
+
mainLogo = 'https://assets.voila.id/xms/logo-xms.jpg',
|
2117
|
+
centerLogo = 'https://assets.voila.id/xms/logo-voila-black.png?v=1',
|
2118
|
+
mainLogoSize,
|
2119
|
+
centerLogoSize = 4,
|
2120
|
+
hideEnv = false,
|
2121
|
+
children,
|
2094
2122
|
...props
|
2095
2123
|
}) => /*#__PURE__*/createElement(Box, Object.assign({
|
2096
|
-
minH:
|
2097
|
-
bg:
|
2098
|
-
|
2099
|
-
px:
|
2100
|
-
py:
|
2124
|
+
minH: 15,
|
2125
|
+
bg: "white",
|
2126
|
+
shadow: "raised",
|
2127
|
+
px: 6,
|
2128
|
+
py: 3
|
2101
2129
|
}, props), /*#__PURE__*/createElement(Flex, {
|
2102
|
-
|
2130
|
+
w: "full",
|
2103
2131
|
alignItems: "center",
|
2104
|
-
justifyContent: "space-between"
|
2105
|
-
|
2106
|
-
|
2132
|
+
justifyContent: "space-between",
|
2133
|
+
pos: "relative"
|
2134
|
+
}, /*#__PURE__*/createElement(Flex, {
|
2107
2135
|
alignItems: "center"
|
2108
|
-
}, /*#__PURE__*/createElement(
|
2136
|
+
}, /*#__PURE__*/createElement(Logo, {
|
2137
|
+
imageUrl: mainLogo,
|
2138
|
+
height: mainLogoSize
|
2139
|
+
}), children && children), /*#__PURE__*/createElement(HStack, {
|
2140
|
+
w: "fit-content",
|
2141
|
+
spacing: 2,
|
2142
|
+
alignItems: "center",
|
2143
|
+
pos: "absolute",
|
2144
|
+
left: "50%",
|
2145
|
+
transform: "translate(-50%,0)"
|
2146
|
+
}, /*#__PURE__*/createElement(Logo, {
|
2147
|
+
imageUrl: centerLogo,
|
2148
|
+
height: centerLogoSize
|
2149
|
+
}), /*#__PURE__*/createElement(Version, {
|
2150
|
+
hideEnv: hideEnv,
|
2109
2151
|
version: data === null || data === void 0 ? void 0 : data.version,
|
2110
2152
|
environment: data === null || data === void 0 ? void 0 : data.environment,
|
2111
2153
|
onOpenModalRelease: onOpenModalRelease
|
2112
2154
|
})), /*#__PURE__*/createElement(Flex, {
|
2113
2155
|
alignItems: "center"
|
2114
2156
|
}, !hideSwitchMode && /*#__PURE__*/createElement(SwitchMode, null), /*#__PURE__*/createElement(Profile, {
|
2157
|
+
brandColor: brandColor,
|
2115
2158
|
data: data,
|
2116
2159
|
onLogout: onLogout
|
2117
2160
|
}))));
|
2118
2161
|
Header.defaultProps = {
|
2162
|
+
brandColor: undefined,
|
2119
2163
|
data: undefined,
|
2120
2164
|
onLogout: undefined,
|
2121
2165
|
onOpenModalRelease: undefined,
|
2122
|
-
hideSwitchMode:
|
2166
|
+
hideSwitchMode: true,
|
2167
|
+
mainLogo: undefined,
|
2168
|
+
mainLogoSize: undefined,
|
2169
|
+
centerLogo: undefined,
|
2170
|
+
centerLogoSize: undefined,
|
2171
|
+
hideEnv: false
|
2123
2172
|
};
|
2124
2173
|
|
2125
2174
|
const ModalBody = /*#__PURE__*/React__default.forwardRef(({
|
@@ -2160,8 +2209,8 @@ const ModalHeader = /*#__PURE__*/forwardRef$2(({
|
|
2160
2209
|
return /*#__PURE__*/React__default.createElement(ModalHeader$1, Object.assign({
|
2161
2210
|
ref: ref,
|
2162
2211
|
background: useColorModeValue('neutral.200', 'mirage.900'),
|
2163
|
-
borderTopRadius:
|
2164
|
-
|
2212
|
+
borderTopRadius: "md",
|
2213
|
+
textStyle: "text-lg"
|
2165
2214
|
}, rest), children);
|
2166
2215
|
});
|
2167
2216
|
|
@@ -2320,8 +2369,8 @@ const PaginationButton = /*#__PURE__*/forwardRef$1(({
|
|
2320
2369
|
ref: ref,
|
2321
2370
|
className: className,
|
2322
2371
|
style: style,
|
2323
|
-
borderRadius:
|
2324
|
-
fontWeight:
|
2372
|
+
borderRadius: "full",
|
2373
|
+
fontWeight: "semibold",
|
2325
2374
|
m: 0,
|
2326
2375
|
px: 3,
|
2327
2376
|
py: 2,
|
@@ -2417,8 +2466,8 @@ const Pagination = ({
|
|
2417
2466
|
width: 2
|
2418
2467
|
})
|
2419
2468
|
})), /*#__PURE__*/createElement(Box, {
|
2420
|
-
|
2421
|
-
borderRadius:
|
2469
|
+
bg: "neutral.300",
|
2470
|
+
borderRadius: "full"
|
2422
2471
|
}, /*#__PURE__*/createElement(PaginationButtonTrigger, {
|
2423
2472
|
"data-test-id": "Pagination-Button",
|
2424
2473
|
color: previousButtonColor,
|
@@ -3093,19 +3142,28 @@ const Tab = /*#__PURE__*/forwardRef$1((props, ref) => {
|
|
3093
3142
|
const isSelected = !!tabProps['aria-selected'];
|
3094
3143
|
const styles = useMultiStyleConfig$1('Tabs', tabProps);
|
3095
3144
|
return /*#__PURE__*/createElement(Button$2, Object.assign({
|
3096
|
-
|
3145
|
+
"data-test-id": props['data-test-id'],
|
3146
|
+
p: 4,
|
3097
3147
|
fontSize: "text.md",
|
3098
3148
|
_selected: {
|
3099
|
-
borderColor:
|
3100
|
-
color:
|
3149
|
+
borderColor: 'primary.400',
|
3150
|
+
color: 'primary.500',
|
3101
3151
|
transform: 'translateY(-2px)'
|
3102
3152
|
},
|
3103
|
-
color:
|
3153
|
+
color: "black.medium",
|
3104
3154
|
_focus: {
|
3105
3155
|
bg: 'none'
|
3106
3156
|
},
|
3157
|
+
_hover: {
|
3158
|
+
'& .chakra-badge': {
|
3159
|
+
bg: 'primary.400'
|
3160
|
+
},
|
3161
|
+
color: 'primary.400'
|
3162
|
+
},
|
3107
3163
|
__css: styles.tab
|
3108
|
-
}, tabProps), /*#__PURE__*/createElement(Flex,
|
3164
|
+
}, tabProps), /*#__PURE__*/createElement(Flex, {
|
3165
|
+
alignItems: "center"
|
3166
|
+
}, (_props$leftAddon = props.leftAddon) === null || _props$leftAddon === void 0 ? void 0 : _props$leftAddon.call(props, {
|
3109
3167
|
isSelected
|
3110
3168
|
}), tabProps.children, (_props$rightAddon = props.rightAddon) === null || _props$rightAddon === void 0 ? void 0 : _props$rightAddon.call(props, {
|
3111
3169
|
isSelected
|
@@ -3220,6 +3278,7 @@ const {
|
|
3220
3278
|
defineMultiStyleConfig
|
3221
3279
|
} = /*#__PURE__*/createMultiStyleConfigHelpers(alertAnatomy.keys);
|
3222
3280
|
const $fg = /*#__PURE__*/cssVar('alert-fg');
|
3281
|
+
const $ac = /*#__PURE__*/cssVar('alert-ac');
|
3223
3282
|
const $bg = /*#__PURE__*/cssVar('alert-bg');
|
3224
3283
|
const baseStyle = /*#__PURE__*/definePartsStyle({
|
3225
3284
|
container: {
|
@@ -3229,8 +3288,8 @@ const baseStyle = /*#__PURE__*/definePartsStyle({
|
|
3229
3288
|
borderRadius: 'md'
|
3230
3289
|
},
|
3231
3290
|
title: {
|
3232
|
-
fontWeight: '
|
3233
|
-
|
3291
|
+
fontWeight: 'regular',
|
3292
|
+
textStyle: 'text.sm',
|
3234
3293
|
marginEnd: '2'
|
3235
3294
|
},
|
3236
3295
|
description: {
|
@@ -3244,6 +3303,7 @@ const baseStyle = /*#__PURE__*/definePartsStyle({
|
|
3244
3303
|
h: '4'
|
3245
3304
|
},
|
3246
3305
|
action: {
|
3306
|
+
color: $ac.reference,
|
3247
3307
|
'& +.chakra-alert__close': {
|
3248
3308
|
ml: '3'
|
3249
3309
|
}
|
@@ -3263,16 +3323,13 @@ const baseStyle = /*#__PURE__*/definePartsStyle({
|
|
3263
3323
|
});
|
3264
3324
|
function getBg(props) {
|
3265
3325
|
const {
|
3266
|
-
theme,
|
3267
3326
|
colorScheme: c
|
3268
3327
|
} = props;
|
3269
|
-
const darkBg = transparentize(`${c}.200`, 0.16)(theme);
|
3270
3328
|
return {
|
3271
|
-
light: `colors.${c}.50
|
3272
|
-
dark: darkBg
|
3329
|
+
light: c === 'neutral' ? `colors.${c}.300` : `colors.${c}.50`
|
3273
3330
|
};
|
3274
3331
|
}
|
3275
|
-
const
|
3332
|
+
const variantLight = /*#__PURE__*/definePartsStyle(props => {
|
3276
3333
|
const {
|
3277
3334
|
colorScheme: c
|
3278
3335
|
} = props;
|
@@ -3281,10 +3338,6 @@ const variantSubtle = /*#__PURE__*/definePartsStyle(props => {
|
|
3281
3338
|
container: {
|
3282
3339
|
[$fg.variable]: `colors.${c}.700`,
|
3283
3340
|
[$bg.variable]: bg.light,
|
3284
|
-
_dark: {
|
3285
|
-
[$fg.variable]: `colors.${c}.200`,
|
3286
|
-
[$bg.variable]: bg.dark
|
3287
|
-
},
|
3288
3341
|
color: $fg.reference
|
3289
3342
|
}
|
3290
3343
|
};
|
@@ -3296,24 +3349,19 @@ const variantSolid = /*#__PURE__*/definePartsStyle(props => {
|
|
3296
3349
|
return {
|
3297
3350
|
container: {
|
3298
3351
|
[$fg.variable]: `colors.white.high`,
|
3299
|
-
[$bg.variable]: `colors.${c}.500
|
3300
|
-
_dark: {
|
3301
|
-
[$fg.variable]: `colors.gray.900`,
|
3302
|
-
[$bg.variable]: `colors.${c}.200`
|
3303
|
-
},
|
3304
|
-
color: $fg.reference
|
3352
|
+
[$bg.variable]: c === 'neutral' ? `colors.${c}.700` : `colors.${c}.500`
|
3305
3353
|
}
|
3306
3354
|
};
|
3307
3355
|
});
|
3308
3356
|
const variants = {
|
3309
|
-
|
3357
|
+
light: variantLight,
|
3310
3358
|
solid: variantSolid
|
3311
3359
|
};
|
3312
3360
|
const alertTheme = /*#__PURE__*/defineMultiStyleConfig({
|
3313
3361
|
baseStyle,
|
3314
3362
|
variants,
|
3315
3363
|
defaultProps: {
|
3316
|
-
variant: '
|
3364
|
+
variant: 'light',
|
3317
3365
|
colorScheme: 'info'
|
3318
3366
|
}
|
3319
3367
|
});
|
@@ -3321,9 +3369,9 @@ const alertTheme = /*#__PURE__*/defineMultiStyleConfig({
|
|
3321
3369
|
const Badge$1 = {
|
3322
3370
|
baseStyle: {
|
3323
3371
|
display: 'inline-block',
|
3324
|
-
fontSize:
|
3325
|
-
fontWeight:
|
3326
|
-
lineHeight: '
|
3372
|
+
fontSize: 'text.xs',
|
3373
|
+
fontWeight: 'semibold',
|
3374
|
+
lineHeight: '14',
|
3327
3375
|
textTransform: 'none',
|
3328
3376
|
px: 2,
|
3329
3377
|
py: '0.5'
|
@@ -3676,18 +3724,17 @@ const {
|
|
3676
3724
|
const baseStyle$1 = /*#__PURE__*/definePartsStyle$1({
|
3677
3725
|
control: {
|
3678
3726
|
borderRadius: '4px',
|
3679
|
-
|
3680
|
-
|
3727
|
+
w: 4,
|
3728
|
+
h: 4,
|
3681
3729
|
border: '1px solid'
|
3682
3730
|
},
|
3683
3731
|
icon: {
|
3684
3732
|
color: 'neutral.50'
|
3685
3733
|
},
|
3686
3734
|
label: {
|
3687
|
-
|
3688
|
-
lineHeight: '18px',
|
3735
|
+
textStyle: 'text.sm',
|
3689
3736
|
color: 'black.high',
|
3690
|
-
ml:
|
3737
|
+
ml: 2
|
3691
3738
|
},
|
3692
3739
|
_disabled: {
|
3693
3740
|
background: 'neutral.200',
|
@@ -3713,10 +3760,10 @@ const errors = /*#__PURE__*/definePartsStyle$1({
|
|
3713
3760
|
}
|
3714
3761
|
},
|
3715
3762
|
label: {
|
3716
|
-
|
3763
|
+
textStyle: 'text.xs'
|
3717
3764
|
},
|
3718
3765
|
icon: {
|
3719
|
-
fontSize: '
|
3766
|
+
fontSize: '8px'
|
3720
3767
|
}
|
3721
3768
|
});
|
3722
3769
|
const unstyled = /*#__PURE__*/definePartsStyle$1({
|
@@ -3750,13 +3797,13 @@ const unstyled = /*#__PURE__*/definePartsStyle$1({
|
|
3750
3797
|
}
|
3751
3798
|
},
|
3752
3799
|
label: {
|
3753
|
-
|
3800
|
+
textStyle: 'text.xs',
|
3754
3801
|
_disabled: {
|
3755
3802
|
opacity: 1
|
3756
3803
|
}
|
3757
3804
|
},
|
3758
3805
|
icon: {
|
3759
|
-
fontSize: '
|
3806
|
+
fontSize: '8px'
|
3760
3807
|
}
|
3761
3808
|
});
|
3762
3809
|
const variants$1 = {
|
@@ -3779,14 +3826,17 @@ const Chips$1 = /*#__PURE__*/defineStyleConfig({
|
|
3779
3826
|
} = props;
|
3780
3827
|
const defaultProps = {
|
3781
3828
|
color: 'primary.500',
|
3782
|
-
|
3829
|
+
textStyle: 'text.sm',
|
3783
3830
|
borderRadius: '24px',
|
3784
3831
|
borderWidth: '1px',
|
3785
3832
|
borderColor: 'primary.500',
|
3786
3833
|
bg: 'white.high',
|
3787
|
-
|
3788
|
-
|
3789
|
-
cursor: 'default'
|
3834
|
+
px: 3,
|
3835
|
+
py: 1,
|
3836
|
+
cursor: 'default',
|
3837
|
+
_hover: {
|
3838
|
+
bg: 'primary.50'
|
3839
|
+
}
|
3790
3840
|
};
|
3791
3841
|
let chipsProps = {
|
3792
3842
|
...defaultProps
|
@@ -3794,7 +3844,10 @@ const Chips$1 = /*#__PURE__*/defineStyleConfig({
|
|
3794
3844
|
if (isActive) {
|
3795
3845
|
const isActiveProps = {
|
3796
3846
|
bg: 'primary.500',
|
3797
|
-
color: 'white.high'
|
3847
|
+
color: 'white.high',
|
3848
|
+
_hover: {
|
3849
|
+
bg: 'primary.500'
|
3850
|
+
}
|
3798
3851
|
};
|
3799
3852
|
chipsProps = {
|
3800
3853
|
...chipsProps,
|
@@ -3819,13 +3872,11 @@ const Chips$1 = /*#__PURE__*/defineStyleConfig({
|
|
3819
3872
|
},
|
3820
3873
|
sizes: {
|
3821
3874
|
sm: {
|
3822
|
-
|
3823
|
-
lineHeight: 4
|
3875
|
+
textStyle: 'text.sm'
|
3824
3876
|
},
|
3825
3877
|
md: {
|
3826
|
-
|
3827
|
-
|
3828
|
-
lineHeight: 5
|
3878
|
+
textStyle: 'text.md',
|
3879
|
+
py: 2
|
3829
3880
|
}
|
3830
3881
|
},
|
3831
3882
|
defaultProps: {
|