@zenkigen-inc/component-ui 1.5.1 → 1.6.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/dist/button/button.d.ts +1 -0
- package/dist/index.esm.js +115 -87
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +130 -91
- package/dist/index.js.map +1 -1
- package/dist/modal/modal-context.d.ts +1 -1
- package/dist/modal/modal.d.ts +2 -2
- package/dist/table/table.d.ts +5 -3
- package/package.json +4 -4
package/dist/index.js
CHANGED
|
@@ -89,11 +89,14 @@ function Button(_ref) {
|
|
|
89
89
|
variant = 'fill'
|
|
90
90
|
} = _ref,
|
|
91
91
|
props = _objectWithoutPropertiesLoose(_ref, _excluded$6);
|
|
92
|
-
const baseClasses = clsx('flex
|
|
92
|
+
const baseClasses = clsx('flex shrink-0 items-center justify-center gap-1', buttonColors[variant].hover, buttonColors[variant].active, buttonColors[variant].disabled, focusVisible.normal, {
|
|
93
93
|
'h-6 px-2.5': size === 'small',
|
|
94
94
|
'h-8 px-3': size === 'medium',
|
|
95
95
|
'h-10 px-4 leading-[24px]': size === 'large',
|
|
96
96
|
'inline-flex': props.isAnchor,
|
|
97
|
+
[buttonColors[variant].selected]: props.isSelected,
|
|
98
|
+
[buttonColors[variant].base]: !props.isSelected,
|
|
99
|
+
'hover:text-text-textOnColor active:text-text-textOnColor [&:hover>*]:fill-icon-iconOnColor [&:active>*]:fill-icon-iconOnColor': props.isSelected && variant !== 'outline' && variant !== 'text',
|
|
97
100
|
'pointer-events-none': props.isDisabled,
|
|
98
101
|
'rounded-button': !props.borderRadius,
|
|
99
102
|
'typography-label1regular': size === 'large',
|
|
@@ -169,24 +172,44 @@ function Checkbox({
|
|
|
169
172
|
const handleChange = useCallback(e => {
|
|
170
173
|
!isDisabled && (onChange == null ? void 0 : onChange(e));
|
|
171
174
|
}, [isDisabled, onChange]);
|
|
172
|
-
const
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
const
|
|
175
|
+
const baseInputClasses = clsx$1('peer absolute z-[1] h-5 w-5 opacity-0', {
|
|
176
|
+
'cursor-not-allowed': isDisabled,
|
|
177
|
+
'cursor-pointer': !isDisabled
|
|
178
|
+
});
|
|
179
|
+
const boxClasses = clsx$1('inline-flex h-5 w-5 items-center justify-center rounded-sm border bg-white', focusVisible.normalPeer, {
|
|
180
|
+
'border-disabled-disabled01': isDisabled,
|
|
181
|
+
'border-hover-hoverUiBorder': !isDisabled && isMouseOver,
|
|
182
|
+
'border-border-uiBorder03': !isDisabled && !isMouseOver,
|
|
183
|
+
'border-interactive-interactive02': !isDisabled && !isMouseOver && color === 'gray',
|
|
184
|
+
'border-hover-hoverError': !isDisabled && isMouseOver && color === 'error',
|
|
185
|
+
'border-support-supportError': !isDisabled && !isMouseOver && color === 'error'
|
|
186
|
+
});
|
|
187
|
+
const indicatorClasses = clsx$1('relative flex h-5 w-5 flex-[0_0_auto] items-center justify-center', {
|
|
177
188
|
'bg-disabled-disabled01': isDisabled && isChecked,
|
|
178
189
|
'border-disabled-disabled01': isDisabled
|
|
179
190
|
});
|
|
180
|
-
const afterClasses = clsx$1('absolute
|
|
191
|
+
const afterClasses = clsx$1('absolute inset-0 m-auto block rounded-sm', {
|
|
192
|
+
'bg-disabled-disabled01': isDisabled && isChecked,
|
|
193
|
+
'bg-hover-hover01': !(isDisabled && isChecked) && isMouseOver,
|
|
194
|
+
'bg-interactive-interactive01': !(isDisabled && isChecked) && !isMouseOver,
|
|
195
|
+
'bg-hover-hover02Dark': !(isDisabled && isChecked) && isMouseOver && color === 'gray',
|
|
196
|
+
'bg-interactive-interactive02': !(isDisabled && isChecked) && !isMouseOver && color === 'gray',
|
|
197
|
+
'bg-hover-hoverError': !(isDisabled && isChecked) && isMouseOver && color === 'error',
|
|
198
|
+
'bg-support-supportError': !(isDisabled && isChecked) && !isMouseOver && color === 'error',
|
|
181
199
|
'scale-0': !isChecked,
|
|
182
200
|
'scale-100': isChecked
|
|
183
201
|
});
|
|
184
|
-
const hoverIndicatorClasses = clsx$1('
|
|
185
|
-
|
|
202
|
+
const hoverIndicatorClasses = clsx$1('inline-block h-3 w-3 rounded-[1px]', {
|
|
203
|
+
'bg-hover-hoverUi': !isDisabled && !isChecked && isMouseOver
|
|
204
|
+
});
|
|
205
|
+
const labelClasses = clsx$1('typography-label2regular ml-2 flex-[1_0_0] break-all', {
|
|
206
|
+
'pointer-events-none cursor-not-allowed text-disabled-disabled01': isDisabled,
|
|
207
|
+
'cursor-pointer text-text-text01': !isDisabled
|
|
208
|
+
});
|
|
186
209
|
return /*#__PURE__*/jsxs("div", {
|
|
187
|
-
className:
|
|
210
|
+
className: "flex items-center",
|
|
188
211
|
children: [/*#__PURE__*/jsxs("div", {
|
|
189
|
-
className:
|
|
212
|
+
className: "flex h-6 w-6 items-center justify-center",
|
|
190
213
|
children: [/*#__PURE__*/jsx("input", {
|
|
191
214
|
type: "checkbox",
|
|
192
215
|
value: value,
|
|
@@ -31098,22 +31121,23 @@ const Icon = _ref => {
|
|
|
31098
31121
|
size = 'medium'
|
|
31099
31122
|
} = _ref,
|
|
31100
31123
|
props = _objectWithoutPropertiesLoose(_ref, _excluded$5);
|
|
31124
|
+
const classes = clsx('inline-block shrink-0', {
|
|
31125
|
+
'fill-disabled-disabled01': props.isDisabled,
|
|
31126
|
+
[iconColors.icon01]: !props.isDisabled && props.color === 'icon01',
|
|
31127
|
+
[iconColors.icon01Dark]: !props.isDisabled && props.color === 'icon01Dark',
|
|
31128
|
+
[iconColors.icon02]: !props.isDisabled && props.color === 'icon02',
|
|
31129
|
+
[iconColors.icon02Dark]: !props.isDisabled && props.color === 'icon02Dark',
|
|
31130
|
+
[iconColors.icon03]: !props.isDisabled && props.color === 'icon03',
|
|
31131
|
+
[iconColors.icon03Dark]: !props.isDisabled && props.color === 'icon03Dark',
|
|
31132
|
+
[iconColors.iconOnColor]: !props.isDisabled && props.color === 'iconOnColor',
|
|
31133
|
+
'w-3 h-3': size === 'x-small',
|
|
31134
|
+
'w-4 h-4': size === 'small',
|
|
31135
|
+
'w-6 h-6': size === 'medium',
|
|
31136
|
+
'w-8 h-8': size === 'large',
|
|
31137
|
+
'w-10 h-10': size === 'x-large'
|
|
31138
|
+
});
|
|
31101
31139
|
return /*#__PURE__*/jsx("span", {
|
|
31102
|
-
className:
|
|
31103
|
-
[iconColors.icon01]: props.color === 'icon01',
|
|
31104
|
-
[iconColors.icon01Dark]: props.color === 'icon01Dark',
|
|
31105
|
-
[iconColors.icon02]: props.color === 'icon02',
|
|
31106
|
-
[iconColors.icon02Dark]: props.color === 'icon02Dark',
|
|
31107
|
-
[iconColors.icon03]: props.color === 'icon03',
|
|
31108
|
-
[iconColors.icon03Dark]: props.color === 'icon03Dark',
|
|
31109
|
-
[iconColors.iconOnColor]: props.color === 'iconOnColor'
|
|
31110
|
-
}, {
|
|
31111
|
-
'w-3 h-3': size === 'x-small',
|
|
31112
|
-
'w-4 h-4': size === 'small',
|
|
31113
|
-
'w-6 h-6': size === 'medium',
|
|
31114
|
-
'w-8 h-8': size === 'large',
|
|
31115
|
-
'w-10 h-10': size === 'x-large'
|
|
31116
|
-
}),
|
|
31140
|
+
className: classes,
|
|
31117
31141
|
children: iconElements[props.name]
|
|
31118
31142
|
});
|
|
31119
31143
|
};
|
|
@@ -31141,13 +31165,12 @@ function DropdownItem({
|
|
|
31141
31165
|
setIsVisible(false);
|
|
31142
31166
|
onClick && onClick(event);
|
|
31143
31167
|
};
|
|
31144
|
-
const listItemClasses = clsx$1('flex w-full items-center');
|
|
31145
31168
|
const itemClasses = clsx$1('typography-label2regular flex h-8 w-full items-center px-3 hover:bg-hover-hover02 active:bg-active-active02', focusVisible.inset, {
|
|
31146
31169
|
'bg-background-uiBackground01 fill-icon-icon01 text-interactive-interactive02': color === 'gray',
|
|
31147
31170
|
'fill-support-supportDanger text-support-supportDanger': color === 'red'
|
|
31148
31171
|
});
|
|
31149
31172
|
return /*#__PURE__*/jsx("li", {
|
|
31150
|
-
className:
|
|
31173
|
+
className: "flex w-full items-center",
|
|
31151
31174
|
children: /*#__PURE__*/jsx("button", {
|
|
31152
31175
|
className: itemClasses,
|
|
31153
31176
|
type: "button",
|
|
@@ -31225,11 +31248,15 @@ function Dropdown({
|
|
|
31225
31248
|
setIsVisible(true);
|
|
31226
31249
|
}
|
|
31227
31250
|
}, [isVisible]);
|
|
31228
|
-
const wrapperClasses = clsx$1('relative
|
|
31229
|
-
|
|
31251
|
+
const wrapperClasses = clsx$1('relative flex shrink-0 items-center gap-1 rounded', {
|
|
31252
|
+
'cursor-not-allowed': isDisabled
|
|
31253
|
+
});
|
|
31254
|
+
const childrenButtonClasses = clsx$1('flex items-center justify-center rounded p-1 hover:bg-hover-hover02 active:bg-active-active02', focusVisible.normal, {
|
|
31255
|
+
'pointer-events-none': isDisabled,
|
|
31230
31256
|
'border border-border-uiBorder02': variant === 'outline'
|
|
31231
31257
|
});
|
|
31232
|
-
const buttonClasses = clsx$1('flex items-center
|
|
31258
|
+
const buttonClasses = clsx$1('flex items-center rounded', buttonColors[variant].base, buttonColors[variant].hover, buttonColors[variant].active, buttonColors[variant].disabled, focusVisible.normal, {
|
|
31259
|
+
'pointer-events-none': isDisabled,
|
|
31233
31260
|
'h-6 px-2': size === 'x-small' || size === 'small',
|
|
31234
31261
|
'h-8 px-4': size === 'medium',
|
|
31235
31262
|
'h-10 px-4': size === 'large'
|
|
@@ -31329,8 +31356,7 @@ function EvaluationStar({
|
|
|
31329
31356
|
function Heading(props) {
|
|
31330
31357
|
const TagName = `h${props.level}`;
|
|
31331
31358
|
const classes = clsx(`flex items-center text-text-text01`, typography.heading[TagName], {
|
|
31332
|
-
'gap-2': props.level === 1
|
|
31333
|
-
}, {
|
|
31359
|
+
'gap-2': props.level === 1,
|
|
31334
31360
|
'gap-1': props.level > 1
|
|
31335
31361
|
});
|
|
31336
31362
|
return /*#__PURE__*/jsxs(TagName, {
|
|
@@ -31347,20 +31373,11 @@ function IconButton(_ref) {
|
|
|
31347
31373
|
} = _ref,
|
|
31348
31374
|
props = _objectWithoutPropertiesLoose(_ref, _excluded$4);
|
|
31349
31375
|
const baseClasses = clsx('typography-label1regular flex items-center justify-center gap-1 rounded', buttonColors[variant].base, buttonColors[variant].hover, buttonColors[variant].active, buttonColors[variant].disabled, focusVisible.normal, {
|
|
31350
|
-
'h-
|
|
31351
|
-
|
|
31352
|
-
'h-8 w-8': size === 'medium' && !props.isNoPadding
|
|
31353
|
-
|
|
31354
|
-
'
|
|
31355
|
-
}, {
|
|
31356
|
-
'h-4 w-4': size === 'small' && props.isNoPadding
|
|
31357
|
-
}, {
|
|
31358
|
-
'h-6 w-6': size === 'medium' && props.isNoPadding
|
|
31359
|
-
}, {
|
|
31360
|
-
'h-6 w-6': size === 'large' && props.isNoPadding
|
|
31361
|
-
}, {
|
|
31362
|
-
'inline-flex': props.isAnchor
|
|
31363
|
-
}, {
|
|
31376
|
+
'h-4 w-4': size === 'small' && props.isNoPadding,
|
|
31377
|
+
'h-6 w-6': size === 'small' && !props.isNoPadding || (size === 'medium' || size === 'large') && props.isNoPadding,
|
|
31378
|
+
'h-8 w-8': size === 'medium' && !props.isNoPadding,
|
|
31379
|
+
'h-10 w-10': size === 'large' && !props.isNoPadding,
|
|
31380
|
+
'inline-flex': props.isAnchor,
|
|
31364
31381
|
'pointer-events-none': props.isDisabled
|
|
31365
31382
|
});
|
|
31366
31383
|
const iconSize = size === 'small' ? 'small' : 'medium';
|
|
@@ -31393,8 +31410,12 @@ function Loading({
|
|
|
31393
31410
|
position = 'fixed',
|
|
31394
31411
|
height = '100%'
|
|
31395
31412
|
}) {
|
|
31396
|
-
const wrapperClasses = clsx$1(position, '
|
|
31397
|
-
const svgClasses = clsx$1(
|
|
31413
|
+
const wrapperClasses = clsx$1(position, 'left-0 top-0 z-20 flex w-full items-center justify-center');
|
|
31414
|
+
const svgClasses = clsx$1({
|
|
31415
|
+
'h-4 w-4': size === 'small',
|
|
31416
|
+
'h-8 w-8': size === 'medium',
|
|
31417
|
+
'h-16 w-16': size === 'large'
|
|
31418
|
+
});
|
|
31398
31419
|
return /*#__PURE__*/jsx(Fragment, {
|
|
31399
31420
|
children: /*#__PURE__*/jsxs("div", {
|
|
31400
31421
|
className: wrapperClasses,
|
|
@@ -31458,14 +31479,14 @@ function ModalBody({
|
|
|
31458
31479
|
}
|
|
31459
31480
|
|
|
31460
31481
|
const ModalContext = /*#__PURE__*/createContext({
|
|
31461
|
-
|
|
31482
|
+
onClose: () => null
|
|
31462
31483
|
});
|
|
31463
31484
|
|
|
31464
31485
|
function ModalFooter({
|
|
31465
31486
|
children,
|
|
31466
31487
|
isNoBorder
|
|
31467
31488
|
}) {
|
|
31468
|
-
const wrapperClasses = clsx$1('flex
|
|
31489
|
+
const wrapperClasses = clsx$1('flex w-full shrink-0 items-center rounded-b-lg px-6 py-4', {
|
|
31469
31490
|
'border-t-[1px] border-border-uiBorder01': !isNoBorder
|
|
31470
31491
|
});
|
|
31471
31492
|
return /*#__PURE__*/jsx("div", {
|
|
@@ -31480,7 +31501,7 @@ function ModalHeader({
|
|
|
31480
31501
|
isNoCloseButton
|
|
31481
31502
|
}) {
|
|
31482
31503
|
const {
|
|
31483
|
-
|
|
31504
|
+
onClose
|
|
31484
31505
|
} = useContext(ModalContext);
|
|
31485
31506
|
const headerClasses = clsx$1('typography-h5 flex w-full shrink-0 items-center justify-between rounded-t-lg px-6 text-text-text01', {
|
|
31486
31507
|
'border-b-[1px] border-border-uiBorder01': !isNoBorder,
|
|
@@ -31495,7 +31516,7 @@ function ModalHeader({
|
|
|
31495
31516
|
icon: "close",
|
|
31496
31517
|
size: "small",
|
|
31497
31518
|
variant: "text",
|
|
31498
|
-
onClick: () =>
|
|
31519
|
+
onClick: () => onClose()
|
|
31499
31520
|
})]
|
|
31500
31521
|
});
|
|
31501
31522
|
}
|
|
@@ -31507,14 +31528,14 @@ function Modal({
|
|
|
31507
31528
|
width = 480,
|
|
31508
31529
|
height,
|
|
31509
31530
|
isOpen,
|
|
31510
|
-
|
|
31531
|
+
onClose,
|
|
31511
31532
|
portalTargetRef
|
|
31512
31533
|
}) {
|
|
31513
31534
|
const renderWidth = typeof width === 'number' ? Math.max(width, LIMIT_WIDTH) : width;
|
|
31514
31535
|
const renderHeight = typeof height === 'number' ? Math.max(height, LIMIT_HEIGHT) : height;
|
|
31515
31536
|
return /*#__PURE__*/reactDom.createPortal(isOpen && /*#__PURE__*/jsx(ModalContext.Provider, {
|
|
31516
31537
|
value: {
|
|
31517
|
-
|
|
31538
|
+
onClose
|
|
31518
31539
|
},
|
|
31519
31540
|
children: /*#__PURE__*/jsx("div", {
|
|
31520
31541
|
className: "fixed left-0 top-0 z-overlay flex h-full w-full items-center justify-center bg-background-backgroundOverlayBlack",
|
|
@@ -31549,7 +31570,7 @@ function NotificationInline(_ref) {
|
|
|
31549
31570
|
'p-2': size === 'small',
|
|
31550
31571
|
'p-3': size === 'medium'
|
|
31551
31572
|
});
|
|
31552
|
-
const iconClasses = clsx('flex
|
|
31573
|
+
const iconClasses = clsx('flex items-center', {
|
|
31553
31574
|
'fill-support-supportError': state === 'attention',
|
|
31554
31575
|
'fill-support-supportWarning': state === 'warning',
|
|
31555
31576
|
'fill-blue-blue50': state === 'information',
|
|
@@ -32053,13 +32074,12 @@ function SelectItem({
|
|
|
32053
32074
|
isSortKey,
|
|
32054
32075
|
onClickItem
|
|
32055
32076
|
}) {
|
|
32056
|
-
const listItemClasses = clsx$1('flex w-full items-center');
|
|
32057
32077
|
const itemClasses = clsx$1('typography-label2regular flex h-8 w-full items-center px-3 hover:bg-hover-hover02 active:bg-active-active02', focusVisible.inset, {
|
|
32058
32078
|
'bg-selected-selectedUi fill-interactive-interactive01 text-interactive-interactive01': isSortKey,
|
|
32059
32079
|
'bg-background-uiBackground01 fill-icon-icon01 text-interactive-interactive02': !isSortKey
|
|
32060
32080
|
});
|
|
32061
32081
|
return /*#__PURE__*/jsx("li", {
|
|
32062
|
-
className:
|
|
32082
|
+
className: "flex w-full items-center",
|
|
32063
32083
|
onClick: onClickItem,
|
|
32064
32084
|
children: /*#__PURE__*/jsxs("button", {
|
|
32065
32085
|
className: itemClasses,
|
|
@@ -32132,18 +32152,26 @@ function SelectSort({
|
|
|
32132
32152
|
onChange == null || onChange(value);
|
|
32133
32153
|
setIsOptionListOpen(false);
|
|
32134
32154
|
}, [onChange]);
|
|
32135
|
-
const wrapperClasses = clsx$1('relative
|
|
32155
|
+
const wrapperClasses = clsx$1('relative flex shrink-0 items-center gap-1 rounded', {
|
|
32136
32156
|
'h-6': size === 'x-small' || size === 'small',
|
|
32137
32157
|
'h-8': size === 'medium',
|
|
32138
32158
|
'h-10': size === 'large',
|
|
32139
32159
|
'cursor-not-allowed': isDisabled
|
|
32140
32160
|
});
|
|
32141
|
-
const buttonClasses = clsx$1('flex
|
|
32161
|
+
const buttonClasses = clsx$1('flex h-full w-full items-center rounded', buttonColors[variant].hover, buttonColors[variant].active, buttonColors[variant].disabled, focusVisible.normal, {
|
|
32162
|
+
[buttonColors[variant].selected]: isSortKey,
|
|
32163
|
+
[buttonColors[variant].base]: !isSortKey,
|
|
32142
32164
|
'px-2': size === 'x-small' || size === 'small',
|
|
32143
32165
|
'px-4': size === 'medium' || size === 'large',
|
|
32144
32166
|
'pointer-events-none': isDisabled
|
|
32145
32167
|
});
|
|
32146
|
-
const labelClasses = clsx$1('truncate',
|
|
32168
|
+
const labelClasses = clsx$1('truncate', {
|
|
32169
|
+
'typography-label3regular': size === 'x-small',
|
|
32170
|
+
'typography-label2regular': size === 'small' || size === 'medium',
|
|
32171
|
+
'typography-label1regular': size === 'large',
|
|
32172
|
+
'mr-1': size === 'x-small',
|
|
32173
|
+
'mr-2': size !== 'x-small'
|
|
32174
|
+
});
|
|
32147
32175
|
return /*#__PURE__*/jsxs("div", {
|
|
32148
32176
|
className: wrapperClasses,
|
|
32149
32177
|
style: {
|
|
@@ -32179,11 +32207,11 @@ function SelectSort({
|
|
|
32179
32207
|
}
|
|
32180
32208
|
|
|
32181
32209
|
const TabItem = props => {
|
|
32182
|
-
const classes = clsx('relative
|
|
32183
|
-
|
|
32184
|
-
|
|
32185
|
-
|
|
32186
|
-
|
|
32210
|
+
const classes = clsx('relative z-0 flex py-2 leading-[24px] before:absolute before:inset-x-0 before:bottom-0 before:h-px hover:text-text-text01 disabled:pointer-events-none disabled:text-disabled-disabled01', {
|
|
32211
|
+
'typography-label2regular': !props.isSelected,
|
|
32212
|
+
'text-interactive-interactive02 hover:before:bg-border-uiBorder02Dark': !props.isSelected,
|
|
32213
|
+
'typography-label2bold': props.isSelected,
|
|
32214
|
+
'before:bg-interactive-interactive01 hover:before:bg-interactive-interactive01 pointer-events-none': props.isSelected
|
|
32187
32215
|
});
|
|
32188
32216
|
return /*#__PURE__*/jsx("button", {
|
|
32189
32217
|
type: "button",
|
|
@@ -32199,10 +32227,9 @@ const TabItem = props => {
|
|
|
32199
32227
|
function Tab({
|
|
32200
32228
|
children
|
|
32201
32229
|
}) {
|
|
32202
|
-
const classes = clsx('flex', 'px-6', 'gap-4', 'relative', 'before:bg-border-uiBorder01', 'before:h-px', 'before:bottom-0', 'before:left-0', 'before:right-0', 'before:absolute', {});
|
|
32203
32230
|
return /*#__PURE__*/jsx("div", {
|
|
32204
32231
|
role: "tablist",
|
|
32205
|
-
className:
|
|
32232
|
+
className: "relative flex gap-4 px-6 before:absolute before:inset-x-0 before:bottom-0 before:h-px before:bg-border-uiBorder01",
|
|
32206
32233
|
children: children
|
|
32207
32234
|
});
|
|
32208
32235
|
}
|
|
@@ -32212,9 +32239,8 @@ function TableCell({
|
|
|
32212
32239
|
children,
|
|
32213
32240
|
className
|
|
32214
32241
|
}) {
|
|
32215
|
-
const cellClasses = clsx$1('border-b-[1px] border-border-uiBorder01');
|
|
32216
32242
|
return /*#__PURE__*/jsx("div", {
|
|
32217
|
-
className: clsx$1(
|
|
32243
|
+
className: clsx$1('border-b-[1px] border-border-uiBorder01', className),
|
|
32218
32244
|
children: children
|
|
32219
32245
|
});
|
|
32220
32246
|
}
|
|
@@ -32232,16 +32258,20 @@ function TableRow({
|
|
|
32232
32258
|
|
|
32233
32259
|
function Table({
|
|
32234
32260
|
width,
|
|
32235
|
-
|
|
32236
|
-
|
|
32261
|
+
templateRows,
|
|
32262
|
+
templateColumns,
|
|
32263
|
+
autoColumns,
|
|
32264
|
+
autoRows,
|
|
32237
32265
|
children
|
|
32238
32266
|
}) {
|
|
32239
32267
|
return /*#__PURE__*/jsx("div", {
|
|
32240
32268
|
className: "grid",
|
|
32241
32269
|
style: {
|
|
32242
32270
|
width,
|
|
32243
|
-
gridTemplateRows:
|
|
32244
|
-
gridTemplateColumns:
|
|
32271
|
+
gridTemplateRows: templateRows,
|
|
32272
|
+
gridTemplateColumns: templateColumns,
|
|
32273
|
+
gridAutoColumns: autoColumns,
|
|
32274
|
+
gridAutoRows: autoRows
|
|
32245
32275
|
},
|
|
32246
32276
|
children: children
|
|
32247
32277
|
});
|
|
@@ -32254,7 +32284,7 @@ const DeleteIcon = ({
|
|
|
32254
32284
|
variant,
|
|
32255
32285
|
onClick
|
|
32256
32286
|
}) => {
|
|
32257
|
-
const deleteButtonClasses = clsx$1('h-[14px]
|
|
32287
|
+
const deleteButtonClasses = clsx$1('group ml-2 h-[14px] w-[14px] rounded-full p-0.5 hover:cursor-pointer hover:bg-icon-iconOnColor focus-visible:bg-icon-iconOnColor', focusVisible.normal);
|
|
32258
32288
|
const deletePathClasses = clsx$1({
|
|
32259
32289
|
'fill-interactive-interactive02': color === 'gray' || variant === 'light',
|
|
32260
32290
|
'group-hover:fill-interactive-interactive02 group-focus-visible:fill-interactive-interactive02 fill-icon-iconOnColor': color !== 'gray'
|
|
@@ -32288,10 +32318,10 @@ function Tag({
|
|
|
32288
32318
|
const wrapperClasses = clsx$1('flex', 'items-center', 'justify-center', {
|
|
32289
32319
|
[tagColors[color]]: variant === 'normal',
|
|
32290
32320
|
[tagLightColors[color]]: variant === 'light',
|
|
32291
|
-
|
|
32292
|
-
|
|
32293
|
-
|
|
32294
|
-
|
|
32321
|
+
'h-[14px] typography-label4regular': !isEditable && size === 'x-small',
|
|
32322
|
+
'h-4 typography-label3regular': !isEditable && size === 'small',
|
|
32323
|
+
'h-[18px] typography-label2regular': !isEditable && size === 'medium',
|
|
32324
|
+
'h-[22px] typography-label2regular': isEditable && size === 'medium',
|
|
32295
32325
|
'rounded-full': isEditable,
|
|
32296
32326
|
rounded: !isEditable,
|
|
32297
32327
|
'py-0.5 px-1': !isEditable,
|
|
@@ -32508,19 +32538,16 @@ function Toggle({
|
|
|
32508
32538
|
labelPosition = 'right',
|
|
32509
32539
|
isDisabled
|
|
32510
32540
|
}) {
|
|
32511
|
-
const wrapperClasses = 'flex flex-[0_0_auto] items-center relative';
|
|
32512
32541
|
const baseClasses = clsx$1('relative flex items-center rounded-full', {
|
|
32542
|
+
'bg-disabled-disabledOn': isDisabled && isChecked,
|
|
32543
|
+
'bg-disabled-disabled01': isDisabled && !isChecked,
|
|
32544
|
+
'bg-interactive-interactive01 peer-hover:bg-hover-hover01': !isDisabled && isChecked,
|
|
32545
|
+
'bg-interactive-interactive02 peer-hover:bg-hover-hover02Dark': !isDisabled && !isChecked,
|
|
32513
32546
|
'w-8 h-4 px-[3px]': size === 'small',
|
|
32514
32547
|
'w-12 h-6 px-1': size === 'medium'
|
|
32515
|
-
}, isDisabled ? {
|
|
32516
|
-
'bg-disabled-disabledOn': isChecked,
|
|
32517
|
-
'bg-disabled-disabled01': !isChecked
|
|
32518
|
-
} : {
|
|
32519
|
-
'bg-interactive-interactive01 peer-hover:bg-hover-hover01': isChecked,
|
|
32520
|
-
'bg-interactive-interactive02 peer-hover:bg-hover-hover02Dark': !isChecked
|
|
32521
32548
|
});
|
|
32522
32549
|
const inputClasses = clsx$1('peer absolute inset-0 z-[1] opacity-0', isDisabled ? 'cursor-not-allowed' : 'cursor-pointer');
|
|
32523
|
-
const indicatorClasses = clsx$1('bg-icon-iconOnColor',
|
|
32550
|
+
const indicatorClasses = clsx$1('rounded-full bg-icon-iconOnColor', {
|
|
32524
32551
|
'w-2.5 h-2.5': size === 'small',
|
|
32525
32552
|
'w-4 h-4': size === 'medium',
|
|
32526
32553
|
'ml-auto': isChecked
|
|
@@ -32534,7 +32561,7 @@ function Toggle({
|
|
|
32534
32561
|
'cursor-pointer text-text-text01': !isDisabled
|
|
32535
32562
|
});
|
|
32536
32563
|
return /*#__PURE__*/jsxs("div", {
|
|
32537
|
-
className:
|
|
32564
|
+
className: "relative flex flex-[0_0_auto] items-center",
|
|
32538
32565
|
children: [label && labelPosition === 'left' && /*#__PURE__*/jsx("label", {
|
|
32539
32566
|
htmlFor: id,
|
|
32540
32567
|
className: labelClasses,
|
|
@@ -32561,7 +32588,20 @@ function Toggle({
|
|
|
32561
32588
|
}
|
|
32562
32589
|
|
|
32563
32590
|
const TailIcon = props => {
|
|
32564
|
-
const tailClasses = clsx$1('absolute
|
|
32591
|
+
const tailClasses = clsx$1('absolute fill-background-uiBackgroundTooltip', {
|
|
32592
|
+
'rotate-180': props.verticalPosition === 'bottom',
|
|
32593
|
+
'rotate-0': props.verticalPosition !== 'bottom',
|
|
32594
|
+
'-top-1': props.verticalPosition === 'bottom' && props.size === 'small',
|
|
32595
|
+
'-top-2': props.verticalPosition === 'bottom' && props.size !== 'small',
|
|
32596
|
+
'-bottom-1': props.verticalPosition !== 'bottom' && props.size === 'small',
|
|
32597
|
+
'-bottom-2': props.verticalPosition !== 'bottom' && props.size !== 'small',
|
|
32598
|
+
'right-2': props.horizontalAlign === 'right' && props.size === 'small',
|
|
32599
|
+
'right-4': props.horizontalAlign === 'right' && props.size !== 'small',
|
|
32600
|
+
'left-2': props.horizontalAlign === 'left' && props.size === 'small',
|
|
32601
|
+
'left-4': props.horizontalAlign === 'left' && props.size !== 'small',
|
|
32602
|
+
'left-2/4 -translate-x-1': props.horizontalAlign === 'center' && props.size === 'small',
|
|
32603
|
+
'left-2/4 -translate-x-2': props.horizontalAlign === 'center' && props.size !== 'small'
|
|
32604
|
+
});
|
|
32565
32605
|
if (props.size === 'small') {
|
|
32566
32606
|
return /*#__PURE__*/jsx("svg", {
|
|
32567
32607
|
className: tailClasses,
|
|
@@ -32618,7 +32658,6 @@ function Tooltip({
|
|
|
32618
32658
|
const handleMouseOutWrapper = useCallback(() => {
|
|
32619
32659
|
setIsVisible(false);
|
|
32620
32660
|
}, []);
|
|
32621
|
-
const targetClasses = clsx$1('relative', 'flex', 'items-center', 'justify-center');
|
|
32622
32661
|
const tooltipBodyClasses = clsx$1('absolute z-tooltip inline-block w-max rounded bg-background-uiBackgroundTooltip text-text-textOnColor', {
|
|
32623
32662
|
'typography-body3regular': size === 'small',
|
|
32624
32663
|
'typography-body2regular': size === 'medium',
|
|
@@ -32630,7 +32669,7 @@ function Tooltip({
|
|
|
32630
32669
|
});
|
|
32631
32670
|
return /*#__PURE__*/jsxs("div", {
|
|
32632
32671
|
ref: targetRef,
|
|
32633
|
-
className:
|
|
32672
|
+
className: "relative flex items-center justify-center",
|
|
32634
32673
|
onMouseOver: handleMouseOverWrapper,
|
|
32635
32674
|
onMouseLeave: handleMouseOutWrapper,
|
|
32636
32675
|
children: [children, isVisible && /*#__PURE__*/jsxs("div", {
|