@economic/taco 2.51.1 → 2.51.2-alpha.2
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/components/Menu/components/Content.d.ts +1 -1
- package/dist/components/Menu/components/SubMenu.d.ts +1 -1
- package/dist/esm/packages/taco/src/components/Tooltip/Tooltip.js +5 -8
- package/dist/esm/packages/taco/src/components/Tooltip/Tooltip.js.map +1 -1
- package/dist/taco.cjs.development.js +185 -187
- package/dist/taco.cjs.development.js.map +1 -1
- package/dist/taco.cjs.production.min.js +1 -1
- package/dist/taco.cjs.production.min.js.map +1 -1
- package/package.json +8 -8
|
@@ -6,7 +6,8 @@ function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'defau
|
|
|
6
6
|
|
|
7
7
|
var React = require('react');
|
|
8
8
|
var React__default = _interopDefault(React);
|
|
9
|
-
var cn =
|
|
9
|
+
var cn = require('clsx');
|
|
10
|
+
var cn__default = _interopDefault(cn);
|
|
10
11
|
var AlertDialogPrimitive = require('@radix-ui/react-alert-dialog');
|
|
11
12
|
var AccordionPrimitive = require('@radix-ui/react-accordion');
|
|
12
13
|
var TooltipPrimitive = require('@radix-ui/react-tooltip');
|
|
@@ -3845,7 +3846,7 @@ const Icon = /*#__PURE__*/React__default.forwardRef(function Icon(props, ref) {
|
|
|
3845
3846
|
} = props;
|
|
3846
3847
|
const Component = icons[name];
|
|
3847
3848
|
/* 24x24 _at the base body font_ - must be em so that they scale with font size - tailwind spacing uses rem */
|
|
3848
|
-
const className =
|
|
3849
|
+
const className = cn__default('inline-flex h-[1.715em] w-[1.715em] flex-shrink-0', props.className, {
|
|
3849
3850
|
'p-[3px]': (_props$className = props.className) === null || _props$className === void 0 ? void 0 : _props$className.includes('rounded-full')
|
|
3850
3851
|
});
|
|
3851
3852
|
return Component ? (/*#__PURE__*/React__default.createElement(Component, Object.assign({}, otherProps, {
|
|
@@ -3866,7 +3867,7 @@ const BadgeIcon = /*#__PURE__*/React.forwardRef(function Badge(props, ref) {
|
|
|
3866
3867
|
small,
|
|
3867
3868
|
...otherProps
|
|
3868
3869
|
} = props;
|
|
3869
|
-
const className =
|
|
3870
|
+
const className = cn__default(`rounded-full border overflow-hidden whitespace-nowrap inline-flex items-center justify-center border-transparent [&>*]:max-h-full shrink-0`, {
|
|
3870
3871
|
'w-5 h-5': !small
|
|
3871
3872
|
}, {
|
|
3872
3873
|
'w-4 h-4 text-xs': small
|
|
@@ -3913,7 +3914,7 @@ const Alert = /*#__PURE__*/React__default.forwardRef(function Alert(props, ref)
|
|
|
3913
3914
|
state,
|
|
3914
3915
|
onClose
|
|
3915
3916
|
} = props;
|
|
3916
|
-
const className =
|
|
3917
|
+
const className = cn__default(`flex w-full flex-row items-start gap-2 rounded-md border-transparent p-3 ${getSubtleColorShadeClasses(getColorByState(state))}`, props.className);
|
|
3917
3918
|
return /*#__PURE__*/React__default.createElement("div", Object.assign({}, props, {
|
|
3918
3919
|
ref: ref,
|
|
3919
3920
|
className: className,
|
|
@@ -3989,7 +3990,7 @@ const Action = /*#__PURE__*/React.forwardRef(function AlertDialogAction(props, r
|
|
|
3989
3990
|
});
|
|
3990
3991
|
|
|
3991
3992
|
const Backdrop = /*#__PURE__*/React.forwardRef(function Backdrop(props, ref) {
|
|
3992
|
-
const className =
|
|
3993
|
+
const className = cn__default('fixed inset-0 cursor-default overflow-y-auto bg-blue-900/[0.3] aria-hidden:invisible print:overflow-visible print:absolute', props.className);
|
|
3993
3994
|
return /*#__PURE__*/React.createElement("div", Object.assign({}, props, {
|
|
3994
3995
|
className: className,
|
|
3995
3996
|
"data-taco": "backdrop",
|
|
@@ -4041,14 +4042,14 @@ const Title = /*#__PURE__*/React.forwardRef(function AlertDialogTitle(props, ref
|
|
|
4041
4042
|
} = useCurrentAlertDialog();
|
|
4042
4043
|
const iconProps = iconPropsByVariant(parentProps.variant);
|
|
4043
4044
|
return /*#__PURE__*/React.createElement(AlertDialogPrimitive.Title, Object.assign({}, props, {
|
|
4044
|
-
className:
|
|
4045
|
+
className: cn__default('flex items-center', props.className),
|
|
4045
4046
|
ref: ref
|
|
4046
4047
|
}), iconProps ? /*#__PURE__*/React.createElement(BadgeIcon, Object.assign({}, iconProps, {
|
|
4047
4048
|
className: "mr-2"
|
|
4048
4049
|
})) : undefined, props.children);
|
|
4049
4050
|
});
|
|
4050
4051
|
const Content = /*#__PURE__*/React.forwardRef(function AlertDialogContent(props, ref) {
|
|
4051
|
-
const className =
|
|
4052
|
+
const className = cn__default('p-6', getDialogPositionClassnames(), getDialogStylingClassnames(), getDialogSizeClassnames('dialog'));
|
|
4052
4053
|
return /*#__PURE__*/React.createElement(AlertDialogPrimitive.Portal, null, /*#__PURE__*/React.createElement(AlertDialogPrimitive.Overlay, {
|
|
4053
4054
|
asChild: true
|
|
4054
4055
|
}, /*#__PURE__*/React.createElement(Backdrop, null, /*#__PURE__*/React.createElement(AlertDialogPrimitive.Content, Object.assign({}, props, {
|
|
@@ -4091,7 +4092,7 @@ const AccordionContext = /*#__PURE__*/React__default.createContext({
|
|
|
4091
4092
|
});
|
|
4092
4093
|
const StyledTrigger = /*#__PURE__*/React__default.forwardRef(function AccordionStyledTrigger(props, ref) {
|
|
4093
4094
|
const isExpanded = !!props['aria-expanded'];
|
|
4094
|
-
const className =
|
|
4095
|
+
const className = cn__default('w-full inline-flex justify-between items-center align-middle', 'focus:rounded-sm focus:border-blue-500 focus:yt-focus', props.className);
|
|
4095
4096
|
return /*#__PURE__*/React__default.createElement("button", Object.assign({}, props, {
|
|
4096
4097
|
ref: ref,
|
|
4097
4098
|
className: className
|
|
@@ -4152,7 +4153,7 @@ const Accordion = props => {
|
|
|
4152
4153
|
};
|
|
4153
4154
|
}
|
|
4154
4155
|
const type = typeof valueProps.defaultValue === 'string' || typeof valueProps.value === 'string' ? 'single' : 'multiple';
|
|
4155
|
-
const className =
|
|
4156
|
+
const className = cn__default('divide-y divide-grey-200', props.className);
|
|
4156
4157
|
return /*#__PURE__*/React__default.createElement(AccordionContext.Provider, {
|
|
4157
4158
|
value: context
|
|
4158
4159
|
}, /*#__PURE__*/React__default.createElement(AccordionPrimitive.Root, Object.assign({}, otherProps, valueProps, {
|
|
@@ -4184,7 +4185,7 @@ const Badge = /*#__PURE__*/React.forwardRef(function Badge(props, ref) {
|
|
|
4184
4185
|
...otherProps
|
|
4185
4186
|
} = props;
|
|
4186
4187
|
const isTransparent = color === 'transparent';
|
|
4187
|
-
const className =
|
|
4188
|
+
const className = cn__default('rounded-full border box-border overflow-hidden whitespace-nowrap inline-flex items-center justify-center', {
|
|
4188
4189
|
[`border ${getOutlineColorShadeClasses(color)}`]: outline,
|
|
4189
4190
|
[`border-none font-normal ${getSubtleColorShadeClasses(color)}`]: subtle,
|
|
4190
4191
|
[`border-none ${getColorShadeClasses(color)}`]: !outline && !subtle,
|
|
@@ -4204,7 +4205,7 @@ const Badge = /*#__PURE__*/React.forwardRef(function Badge(props, ref) {
|
|
|
4204
4205
|
}, children) : children;
|
|
4205
4206
|
if (status) {
|
|
4206
4207
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
4207
|
-
className:
|
|
4208
|
+
className: cn__default('mr-1 h-2 w-2 shrink-0 rounded-full', getColorShadeClasses(color))
|
|
4208
4209
|
}), contentToRender);
|
|
4209
4210
|
}
|
|
4210
4211
|
return contentToRender;
|
|
@@ -4471,7 +4472,7 @@ const Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(props, ref) {
|
|
|
4471
4472
|
hide = false,
|
|
4472
4473
|
...otherProps
|
|
4473
4474
|
} = props;
|
|
4474
|
-
const className =
|
|
4475
|
+
const className = cn__default('break-words', otherProps.className);
|
|
4475
4476
|
if (hide) {
|
|
4476
4477
|
return children;
|
|
4477
4478
|
}
|
|
@@ -4481,19 +4482,16 @@ const Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(props, ref) {
|
|
|
4481
4482
|
asChild: true,
|
|
4482
4483
|
ref: ref
|
|
4483
4484
|
}, children), /*#__PURE__*/React.createElement(TooltipPrimitive.Portal, null, /*#__PURE__*/React.createElement(TooltipPrimitive.Content, Object.assign({}, otherProps, {
|
|
4484
|
-
asChild: true,
|
|
4485
|
-
className: className,
|
|
4486
4485
|
side: placement,
|
|
4487
|
-
sideOffset: 3
|
|
4488
|
-
|
|
4489
|
-
className: "xs:max-w-[theme(spacing.56)] max-w-[theme(spacing.32)] animate-[fade-in_150ms] rounded bg-blue-900 px-2 py-1 text-xs text-white print:hidden",
|
|
4486
|
+
sideOffset: 3,
|
|
4487
|
+
className: cn.clsx('xs:max-w-[theme(spacing.56)] max-w-[theme(spacing.32)] animate-[fade-in_150ms] rounded bg-blue-900 px-2 py-1 text-xs text-white print:hidden', className),
|
|
4490
4488
|
"data-taco": "tooltip",
|
|
4491
4489
|
style: {
|
|
4492
4490
|
transformOrigin: 'var(--radix-tooltip-content-transform-origin)'
|
|
4493
4491
|
}
|
|
4494
|
-
}, /*#__PURE__*/React.createElement(TooltipPrimitive.Arrow, {
|
|
4492
|
+
}), title, /*#__PURE__*/React.createElement(TooltipPrimitive.Arrow, {
|
|
4495
4493
|
className: "-mt-px fill-blue-900 stroke-blue-900"
|
|
4496
|
-
})
|
|
4494
|
+
}))));
|
|
4497
4495
|
});
|
|
4498
4496
|
|
|
4499
4497
|
const getButtonClasses = () => {
|
|
@@ -4578,7 +4576,7 @@ const Base = /*#__PURE__*/React.forwardRef(function IconButtonBase(props, ref) {
|
|
|
4578
4576
|
rounded = false,
|
|
4579
4577
|
...otherProps
|
|
4580
4578
|
} = props;
|
|
4581
|
-
const className =
|
|
4579
|
+
const className = cn__default('w-8', getButtonClasses(), getAppearanceClasses(otherProps.appearance, true), {
|
|
4582
4580
|
'rounded-full': rounded,
|
|
4583
4581
|
rounded: !rounded
|
|
4584
4582
|
}, props.className);
|
|
@@ -4953,7 +4951,7 @@ const Banner = /*#__PURE__*/React.forwardRef(function Banner(props, ref) {
|
|
|
4953
4951
|
const {
|
|
4954
4952
|
texts
|
|
4955
4953
|
} = useLocalization();
|
|
4956
|
-
const className =
|
|
4954
|
+
const className = cn__default('bg-white relative flex items-center gap-2 py-2 px-4 leading-6 shadow-md z-10', props.className);
|
|
4957
4955
|
return /*#__PURE__*/React.createElement("div", {
|
|
4958
4956
|
className: className,
|
|
4959
4957
|
"data-taco": "banner",
|
|
@@ -4973,7 +4971,7 @@ const Base$1 = /*#__PURE__*/React.forwardRef(function ButtonBase(props, ref) {
|
|
|
4973
4971
|
fluid,
|
|
4974
4972
|
...otherProps
|
|
4975
4973
|
} = props;
|
|
4976
|
-
const className =
|
|
4974
|
+
const className = cn__default(getButtonClasses(), getAppearanceClasses(appearance), 'rounded px-3', {
|
|
4977
4975
|
'w-full': fluid
|
|
4978
4976
|
}, props.className);
|
|
4979
4977
|
return createButtonWithTooltip({
|
|
@@ -5124,7 +5122,7 @@ const Calendar$1 = props => {
|
|
|
5124
5122
|
}
|
|
5125
5123
|
handleChange(date, event);
|
|
5126
5124
|
};
|
|
5127
|
-
const className =
|
|
5125
|
+
const className = cn__default('flex bg-white text-xs p-2', otherProps.className);
|
|
5128
5126
|
return /*#__PURE__*/React.createElement("div", {
|
|
5129
5127
|
"data-taco": "calendar"
|
|
5130
5128
|
}, /*#__PURE__*/React.createElement(reactDayPicker.DayPicker, {
|
|
@@ -5191,7 +5189,7 @@ const Truncate = ({
|
|
|
5191
5189
|
}, []);
|
|
5192
5190
|
const clonedChildrenWithRef = /*#__PURE__*/React__default.cloneElement(React__default.Children.only(children), {
|
|
5193
5191
|
ref,
|
|
5194
|
-
className:
|
|
5192
|
+
className: cn__default(children.props.className, 'truncate', {
|
|
5195
5193
|
'hover:cursor-pointer': isTruncated
|
|
5196
5194
|
})
|
|
5197
5195
|
});
|
|
@@ -5208,7 +5206,7 @@ const Content$2 = /*#__PURE__*/React.forwardRef(function CardContent(externalPro
|
|
|
5208
5206
|
noPadding,
|
|
5209
5207
|
...props
|
|
5210
5208
|
} = externalProps;
|
|
5211
|
-
const className =
|
|
5209
|
+
const className = cn__default('flex-grow overflow-auto', {
|
|
5212
5210
|
'px-4 pb-4': !noPadding
|
|
5213
5211
|
}, props.className);
|
|
5214
5212
|
return /*#__PURE__*/React.createElement("div", Object.assign({}, props, {
|
|
@@ -5225,7 +5223,7 @@ const Card = /*#__PURE__*/React.forwardRef(function Card(props, ref) {
|
|
|
5225
5223
|
className,
|
|
5226
5224
|
...otherProps
|
|
5227
5225
|
} = props;
|
|
5228
|
-
const cardClassName =
|
|
5226
|
+
const cardClassName = cn__default('bg-white flex flex-col rounded-xl border border-solid border-radius-[12px] border-grey-300 hover:border-grey-500', className);
|
|
5229
5227
|
return /*#__PURE__*/React.createElement("div", Object.assign({}, otherProps, {
|
|
5230
5228
|
className: cardClassName,
|
|
5231
5229
|
"data-taco": "card",
|
|
@@ -5271,7 +5269,7 @@ const Spinner = /*#__PURE__*/React__default.forwardRef(function Spinner(props, r
|
|
|
5271
5269
|
if (!visible) {
|
|
5272
5270
|
return null;
|
|
5273
5271
|
}
|
|
5274
|
-
const className =
|
|
5272
|
+
const className = cn__default('inline-flex flex-col relative items-center', otherProps.className);
|
|
5275
5273
|
return /*#__PURE__*/React__default.createElement("div", Object.assign({}, otherProps, {
|
|
5276
5274
|
className: className,
|
|
5277
5275
|
"data-taco": "spinner",
|
|
@@ -5300,7 +5298,7 @@ const Checkbox = /*#__PURE__*/React.forwardRef(function Checkbox(props, ref) {
|
|
|
5300
5298
|
...otherProps
|
|
5301
5299
|
} = props;
|
|
5302
5300
|
const id = useId(props.id);
|
|
5303
|
-
const className =
|
|
5301
|
+
const className = cn__default('bg-white h-5 w-5 border rounded text-sm flex-shrink-0 focus-visible:yt-focus disabled:cursor-not-allowed text-white', {
|
|
5304
5302
|
'self-start': !!label,
|
|
5305
5303
|
'mt-[0.1rem]': !label
|
|
5306
5304
|
}, invalid ? {
|
|
@@ -5327,7 +5325,7 @@ const Checkbox = /*#__PURE__*/React.forwardRef(function Checkbox(props, ref) {
|
|
|
5327
5325
|
event.currentTarget.click();
|
|
5328
5326
|
}
|
|
5329
5327
|
};
|
|
5330
|
-
const spinnerClassname =
|
|
5328
|
+
const spinnerClassname = cn__default(
|
|
5331
5329
|
//Spinner is slightly bigger then 'line' and 'tick' icons, so making it 2px smaller from each side
|
|
5332
5330
|
"m-0.5 !h-[calc(100%-theme('spacing.1'))] !w-[calc(100%-theme('spacing.1'))]", {
|
|
5333
5331
|
'text-blue-500': !checked && !indeterminate
|
|
@@ -5349,7 +5347,7 @@ const Checkbox = /*#__PURE__*/React.forwardRef(function Checkbox(props, ref) {
|
|
|
5349
5347
|
className: "!h-full !w-full"
|
|
5350
5348
|
}))));
|
|
5351
5349
|
if (label) {
|
|
5352
|
-
const labelContainerClassName =
|
|
5350
|
+
const labelContainerClassName = cn__default('flex items-center cursor-pointer gap-2', {
|
|
5353
5351
|
'cursor-not-allowed text-grey-300': props.disabled
|
|
5354
5352
|
});
|
|
5355
5353
|
return /*#__PURE__*/React.createElement("span", {
|
|
@@ -5368,7 +5366,7 @@ const getInputClasses = props => {
|
|
|
5368
5366
|
const disabled = props.disabled || !!props['aria-disabled'];
|
|
5369
5367
|
const readOnly = props.readOnly || !!props['aria-readonly'];
|
|
5370
5368
|
const invalid = props.invalid || !!props['aria-invalid'];
|
|
5371
|
-
return
|
|
5369
|
+
return cn__default('peer text-black text-sm border font-normal not-italic no-underline rounded flex items-center leading-6 px-2 relative w-full text-ellipsis transition-colors transition-opacity ease-in min-h-[theme(spacing.8)] focus:yt-focus',
|
|
5372
5370
|
// hide the arrow controls on input[type=number]
|
|
5373
5371
|
'[appearance:textfield] [&::-webkit-outer-spin-button]:appearance-none [&::-webkit-inner-spin-button]:appearance-none', {
|
|
5374
5372
|
'bg-white': !props.highlighted && !readOnly,
|
|
@@ -5387,7 +5385,7 @@ const getInputClasses = props => {
|
|
|
5387
5385
|
};
|
|
5388
5386
|
const getButtonStateClasses = (invalid, disabled = false) => {
|
|
5389
5387
|
if (invalid) {
|
|
5390
|
-
return
|
|
5388
|
+
return cn__default('border border-red-500 group-peer-hover:enabled:border-red-700 transition-colors ease-in', {
|
|
5391
5389
|
'border-red-500/30': disabled
|
|
5392
5390
|
});
|
|
5393
5391
|
}
|
|
@@ -5497,7 +5495,7 @@ const InputWithoutDeprecatedFeatures = /*#__PURE__*/React.forwardRef(function In
|
|
|
5497
5495
|
const prefixRect = useBoundingClientRectListener(prefixRef);
|
|
5498
5496
|
const postfixRef = React.useRef(null);
|
|
5499
5497
|
const postfixRect = useBoundingClientRectListener(postfixRef, [postfix]);
|
|
5500
|
-
const className =
|
|
5498
|
+
const className = cn__default(getInputClasses(props), {
|
|
5501
5499
|
'pl-8': !!prefix,
|
|
5502
5500
|
'pr-8': !!postfix
|
|
5503
5501
|
}, attributes.className);
|
|
@@ -5552,7 +5550,7 @@ const Affix = /*#__PURE__*/React.memo(/*#__PURE__*/React.forwardRef(function Aff
|
|
|
5552
5550
|
type
|
|
5553
5551
|
} = props;
|
|
5554
5552
|
return /*#__PURE__*/React.createElement("div", {
|
|
5555
|
-
className:
|
|
5553
|
+
className: cn__default('group absolute top-0 flex h-full items-center justify-center px-2',
|
|
5556
5554
|
// icon
|
|
5557
5555
|
'[&_[data-taco="icon"]]:!h-5 [&_[data-taco="icon"]]:!w-5', {
|
|
5558
5556
|
'text-grey-300': disabled,
|
|
@@ -5574,7 +5572,7 @@ const Input = /*#__PURE__*/React.forwardRef(function LegacyInput(props, ref) {
|
|
|
5574
5572
|
let postfix;
|
|
5575
5573
|
if (button) {
|
|
5576
5574
|
const disabled = button.props.disabled || attributes.disabled;
|
|
5577
|
-
const buttonClassName =
|
|
5575
|
+
const buttonClassName = cn__default('items-center focus:z-10 flex justify-center rounded-l-none rounded-r h-full focus:rounded focus:outline-none', getButtonStateClasses(attributes.invalid, disabled), button.props.className);
|
|
5578
5576
|
postfix = /*#__PURE__*/React.cloneElement(button, {
|
|
5579
5577
|
className: buttonClassName,
|
|
5580
5578
|
disabled
|
|
@@ -5750,7 +5748,7 @@ const ScrollableList = /*#__PURE__*/React.forwardRef(function ScrollableList(pro
|
|
|
5750
5748
|
'aria-selected': multiselect ? getOptionCheckedState(String(option.value), index) : currentIndex === index,
|
|
5751
5749
|
'data-focused': currentIndex === index,
|
|
5752
5750
|
children: option.text,
|
|
5753
|
-
className:
|
|
5751
|
+
className: cn__default('flex items-center px-3 w-full cursor-pointer bg-white flex-[0_0_2rem] focus:wcag-blue-500 focus:border-blue-500', {
|
|
5754
5752
|
'sticky top-0 font-bold': depth === 0 && !!option.hasChildren
|
|
5755
5753
|
}),
|
|
5756
5754
|
disabled: option.disabled,
|
|
@@ -5767,7 +5765,7 @@ const ScrollableList = /*#__PURE__*/React.forwardRef(function ScrollableList(pro
|
|
|
5767
5765
|
});
|
|
5768
5766
|
const list = {
|
|
5769
5767
|
...otherProps,
|
|
5770
|
-
className:
|
|
5768
|
+
className: cn__default('inline-flex flex-col list-none !p-0 m-0 overflow-y-auto h-auto', getInputClasses(props), {
|
|
5771
5769
|
'yt-list--multiselect': multiselect,
|
|
5772
5770
|
'pointer-events-none': disabled,
|
|
5773
5771
|
'cursor-not-allowed': disabled || readOnly
|
|
@@ -6248,7 +6246,7 @@ const Combobox = /*#__PURE__*/React.forwardRef(function Combobox(props, ref) {
|
|
|
6248
6246
|
texts
|
|
6249
6247
|
} = useLocalization();
|
|
6250
6248
|
const selectDimensions = useBoundingClientRectListener(internalRef);
|
|
6251
|
-
const className =
|
|
6249
|
+
const className = cn__default('inline-flex relative', {
|
|
6252
6250
|
'yt-combobox--inline': props.inline
|
|
6253
6251
|
}, externalClassName);
|
|
6254
6252
|
return /*#__PURE__*/React.createElement("span", {
|
|
@@ -6299,7 +6297,7 @@ const Combobox = /*#__PURE__*/React.forwardRef(function Combobox(props, ref) {
|
|
|
6299
6297
|
},
|
|
6300
6298
|
sideOffset: 4
|
|
6301
6299
|
}, /*#__PURE__*/React.createElement(ScrollableList, Object.assign({}, list, {
|
|
6302
|
-
className:
|
|
6300
|
+
className: cn__default('max-h-[calc(12rem+2px)] w-auto max-w-[theme(spacing.96)] !border-blue-500'),
|
|
6303
6301
|
style: {
|
|
6304
6302
|
minWidth: selectDimensions === null || selectDimensions === void 0 ? void 0 : selectDimensions.width
|
|
6305
6303
|
},
|
|
@@ -6530,7 +6528,7 @@ const Content$3 = /*#__PURE__*/React.forwardRef(function PopoverContent(props, r
|
|
|
6530
6528
|
placement: side,
|
|
6531
6529
|
...popoverContentProps
|
|
6532
6530
|
} = props;
|
|
6533
|
-
const className =
|
|
6531
|
+
const className = cn__default(getPopoverStyleClassnames(), props.className);
|
|
6534
6532
|
let output;
|
|
6535
6533
|
if (typeof props.children === 'function') {
|
|
6536
6534
|
output = /*#__PURE__*/React.createElement(PopoverPrimitive.Close, {
|
|
@@ -6599,7 +6597,7 @@ const Datepicker = /*#__PURE__*/React.forwardRef(function Datepicker(props, ref)
|
|
|
6599
6597
|
const {
|
|
6600
6598
|
texts
|
|
6601
6599
|
} = useLocalization();
|
|
6602
|
-
const className =
|
|
6600
|
+
const className = cn__default('inline-flex w-full text-black font-normal', externalClassName);
|
|
6603
6601
|
const popoverContentRef = React.useRef(null);
|
|
6604
6602
|
const handleOpenAutofocus = React.useCallback(e => {
|
|
6605
6603
|
var _popoverContentRef$cu, _popoverContentRef$cu2;
|
|
@@ -6761,14 +6759,14 @@ const useDraggable = ref => {
|
|
|
6761
6759
|
};
|
|
6762
6760
|
|
|
6763
6761
|
const Title$1 = /*#__PURE__*/React.forwardRef(function DialogTitle(props, ref) {
|
|
6764
|
-
const className =
|
|
6762
|
+
const className = cn__default('text-center', props.className);
|
|
6765
6763
|
return /*#__PURE__*/React.createElement(DialogPrimitive.Title, Object.assign({}, props, {
|
|
6766
6764
|
className: className,
|
|
6767
6765
|
ref: ref
|
|
6768
6766
|
}));
|
|
6769
6767
|
});
|
|
6770
6768
|
const Footer$1 = /*#__PURE__*/React.forwardRef(function DialogFooter(props, ref) {
|
|
6771
|
-
const className =
|
|
6769
|
+
const className = cn__default('mt-8 flex justify-end', props.className);
|
|
6772
6770
|
return /*#__PURE__*/React.createElement("div", Object.assign({}, props, {
|
|
6773
6771
|
className: className,
|
|
6774
6772
|
ref: ref
|
|
@@ -6808,8 +6806,8 @@ const Content$4 = /*#__PURE__*/React.forwardRef(function DialogContent(props, re
|
|
|
6808
6806
|
const {
|
|
6809
6807
|
texts
|
|
6810
6808
|
} = useLocalization();
|
|
6811
|
-
const className =
|
|
6812
|
-
const containerClassName =
|
|
6809
|
+
const className = cn__default('relative bg-white animate-[fade-in_150ms] rounded print:!static', getDialogPositionClassnames(), getDialogSizeClassnames(dialog.size), 'print:w-full print:h-max print:m-0 print:overflow-visible');
|
|
6810
|
+
const containerClassName = cn__default('bg-white p-6 rounded relative z-10 shadow print:p-0',
|
|
6813
6811
|
// The `!fixed` property is crucial to ensure that when a draggable dialog is moved, the printed document still displays its content across the full page.
|
|
6814
6812
|
'print:overflow-visible print:h-max print:!transform-none print:!inset-0 print:!m-0', {
|
|
6815
6813
|
'rounded-b-none': !!dialog.elements.extra
|
|
@@ -6868,7 +6866,7 @@ const Content$4 = /*#__PURE__*/React.forwardRef(function DialogContent(props, re
|
|
|
6868
6866
|
const DialogDrawer = /*#__PURE__*/React.forwardRef(function DialogDrawer(props, ref) {
|
|
6869
6867
|
var _dialog$drawer, _dialog$drawer2;
|
|
6870
6868
|
const dialog = useCurrentDialog();
|
|
6871
|
-
const className =
|
|
6869
|
+
const className = cn__default('absolute top-0 -ml-[4px] hidden h-full w-full overflow-y-auto rounded-r bg-white p-6 text-left', props.className);
|
|
6872
6870
|
return /*#__PURE__*/React.createElement(framerMotion.motion.div, Object.assign({}, props, {
|
|
6873
6871
|
className: className,
|
|
6874
6872
|
"data-taco": "dialog-drawer",
|
|
@@ -6900,7 +6898,7 @@ const DialogDrawer = /*#__PURE__*/React.forwardRef(function DialogDrawer(props,
|
|
|
6900
6898
|
DialogDrawer.displayName = 'DialogDrawer';
|
|
6901
6899
|
|
|
6902
6900
|
const Extra = /*#__PURE__*/React.forwardRef(function DialogExtra(props, ref) {
|
|
6903
|
-
const className =
|
|
6901
|
+
const className = cn__default('wcag-grey-100 absolute top-full left-0 -mt-px w-full rounded-t-none rounded-b p-6 text-left', props.className);
|
|
6904
6902
|
return /*#__PURE__*/React.createElement("div", Object.assign({}, props, {
|
|
6905
6903
|
className: className,
|
|
6906
6904
|
"data-taco": "dialog-extra",
|
|
@@ -6982,7 +6980,7 @@ const Group = /*#__PURE__*/React.forwardRef(function Group(props, ref) {
|
|
|
6982
6980
|
orientation = 'horizontal',
|
|
6983
6981
|
...otherProps
|
|
6984
6982
|
} = props;
|
|
6985
|
-
const className =
|
|
6983
|
+
const className = cn__default('flex gap-2 [&:has([data-taco="tag"])]:!gap-1', {
|
|
6986
6984
|
'flex-col ': orientation === 'vertical'
|
|
6987
6985
|
}, props.className);
|
|
6988
6986
|
return /*#__PURE__*/React.createElement(Tag, Object.assign({}, otherProps, {
|
|
@@ -7023,7 +7021,7 @@ const getDrawerSizeClassnames = size => {
|
|
|
7023
7021
|
}
|
|
7024
7022
|
};
|
|
7025
7023
|
const getDrawerContentClassNames = (size, variant, open) => {
|
|
7026
|
-
return
|
|
7024
|
+
return cn__default('bg-white h-full bottom-0 top-0 right-0 transition-none', {
|
|
7027
7025
|
block: open,
|
|
7028
7026
|
hidden: !open,
|
|
7029
7027
|
fixed: variant === 'overlay',
|
|
@@ -7031,23 +7029,23 @@ const getDrawerContentClassNames = (size, variant, open) => {
|
|
|
7031
7029
|
}, getDrawerSizeClassnames(size));
|
|
7032
7030
|
};
|
|
7033
7031
|
const getDrawerContainerClassNames = variant => {
|
|
7034
|
-
return
|
|
7032
|
+
return cn__default('bg-white mx-auto absolute h-full w-full flex flex-col ', {
|
|
7035
7033
|
'shadow-[0_6px_9px_0_rgba(89,85,98,0.3),0_0_1px_0_rgba(89,85,98,0.2)]': variant === 'overlay',
|
|
7036
7034
|
'border-l border-grey-300 h-full': variant === 'embedded'
|
|
7037
7035
|
});
|
|
7038
7036
|
};
|
|
7039
7037
|
const getDrawerDragHandlerClassNames = () => {
|
|
7040
|
-
return
|
|
7038
|
+
return cn__default('border-[2px] absolute border-transparent top-0 w-2 h-full cursor-ew-resize left-0 hover:border-l-blue-500');
|
|
7041
7039
|
};
|
|
7042
7040
|
const getBackdropClassNames = open => {
|
|
7043
|
-
return
|
|
7041
|
+
return cn__default({
|
|
7044
7042
|
block: open,
|
|
7045
7043
|
hidden: !open
|
|
7046
7044
|
});
|
|
7047
7045
|
};
|
|
7048
7046
|
|
|
7049
7047
|
const Bar = props => {
|
|
7050
|
-
const className =
|
|
7048
|
+
const className = cn__default(`flex select-none touch-none transition-colors hover:bg-grey`, {
|
|
7051
7049
|
'w-[7px] hover:w-[14px] mr-[2px] hover:px-[2px] hover:mr-0': props.orientation === 'vertical',
|
|
7052
7050
|
'flex-col h-[7px] hover:h-[14px] mb-[2px] hover:py-[2px] hover:mb-0': props.orientation === 'horizontal'
|
|
7053
7051
|
});
|
|
@@ -7067,7 +7065,7 @@ const ScrollArea = props => {
|
|
|
7067
7065
|
...otherProps
|
|
7068
7066
|
} = props;
|
|
7069
7067
|
return /*#__PURE__*/React__default.createElement(ScrollAreaPrimitive.Root, Object.assign({}, otherProps, {
|
|
7070
|
-
className:
|
|
7068
|
+
className: cn__default('overflow-hidden', props.className),
|
|
7071
7069
|
"data-taco": "scrollarea"
|
|
7072
7070
|
}), /*#__PURE__*/React__default.createElement(ScrollAreaPrimitive.Viewport, {
|
|
7073
7071
|
className: "h-full w-full"
|
|
@@ -7118,7 +7116,7 @@ const Title$2 = /*#__PURE__*/React__default.forwardRef(function DrawerTitle(prop
|
|
|
7118
7116
|
* where we might want to hide the grey separator. For this reason separator was rendered with using of classNames,
|
|
7119
7117
|
* so it can be easily overriden in exceptional scenarios.
|
|
7120
7118
|
* */
|
|
7121
|
-
const cName =
|
|
7119
|
+
const cName = cn__default('grow-0 py-4 px-4 justify-self-start mb-0 border-b-[1px] border-grey-300 flex items-start', className);
|
|
7122
7120
|
React__default.useEffect(() => {
|
|
7123
7121
|
var _ref$current, _drawer$querySelector, _closeButton$offsetWi, _drawer$querySelector2, _actionsWrapper$offse;
|
|
7124
7122
|
const drawer = ref === null || ref === void 0 ? void 0 : (_ref$current = ref.current) === null || _ref$current === void 0 ? void 0 : _ref$current.closest('[data-taco="drawer"]');
|
|
@@ -7158,7 +7156,7 @@ const Footer$2 = /*#__PURE__*/React__default.forwardRef(function DrawerFooter(pr
|
|
|
7158
7156
|
/**
|
|
7159
7157
|
* The same scenario as Title, grey separator rendered using classNames to have posibility to override it.
|
|
7160
7158
|
*/
|
|
7161
|
-
const cName =
|
|
7159
|
+
const cName = cn__default('mt-auto flex justify-end grow-0 p-4 border-t-[1px] border-grey-300', props.className);
|
|
7162
7160
|
return /*#__PURE__*/React__default.createElement("div", Object.assign({}, otherProps, {
|
|
7163
7161
|
className: cName,
|
|
7164
7162
|
ref: ref
|
|
@@ -7169,7 +7167,7 @@ const Actions = /*#__PURE__*/React__default.forwardRef(function Actions(props, r
|
|
|
7169
7167
|
className,
|
|
7170
7168
|
...otherProps
|
|
7171
7169
|
} = props;
|
|
7172
|
-
const cName =
|
|
7170
|
+
const cName = cn__default('absolute top-0 right-10 mr-[8px] mt-4', className);
|
|
7173
7171
|
// Id is added to identify the actions wrapper inside a useEffect in Dialog.Title
|
|
7174
7172
|
return /*#__PURE__*/React__default.createElement(Group, Object.assign({}, otherProps, {
|
|
7175
7173
|
className: cName,
|
|
@@ -7194,7 +7192,7 @@ const InnerContent = /*#__PURE__*/React__default.forwardRef(function InnerConten
|
|
|
7194
7192
|
children,
|
|
7195
7193
|
...otherProps
|
|
7196
7194
|
} = props;
|
|
7197
|
-
const cName =
|
|
7195
|
+
const cName = cn__default('grow flex flex-col', {
|
|
7198
7196
|
'overflow-y-hidden': isScrollable,
|
|
7199
7197
|
'p-4': !isScrollable
|
|
7200
7198
|
}, className);
|
|
@@ -7274,7 +7272,7 @@ const DrawerContent = /*#__PURE__*/React__default.forwardRef(function Content(pr
|
|
|
7274
7272
|
menu.close();
|
|
7275
7273
|
};
|
|
7276
7274
|
}
|
|
7277
|
-
const containerClassName = React__default.useMemo(() =>
|
|
7275
|
+
const containerClassName = React__default.useMemo(() => cn__default(getDrawerContainerClassNames(variant), className), [className]);
|
|
7278
7276
|
const {
|
|
7279
7277
|
contentClassName,
|
|
7280
7278
|
dragHandlerClassName
|
|
@@ -7395,7 +7393,7 @@ const Trigger$4 = /*#__PURE__*/React.forwardRef(function DrawerTrigger(props, re
|
|
|
7395
7393
|
const DEFAULT_OUTLET_NAME = 'default';
|
|
7396
7394
|
const Outlet = /*#__PURE__*/React.forwardRef(function Outlet(props, ref) {
|
|
7397
7395
|
var _props$name;
|
|
7398
|
-
const className =
|
|
7396
|
+
const className = cn__default('h-full ml-auto overflow-hidden flex-shrink-0', props.className);
|
|
7399
7397
|
return /*#__PURE__*/React.createElement("div", Object.assign({}, props, {
|
|
7400
7398
|
className: className,
|
|
7401
7399
|
"data-taco": "drawer-outlet",
|
|
@@ -7501,10 +7499,10 @@ const Field = /*#__PURE__*/React.forwardRef(function Field(props, ref) {
|
|
|
7501
7499
|
message,
|
|
7502
7500
|
...otherProps
|
|
7503
7501
|
} = props;
|
|
7504
|
-
const className =
|
|
7502
|
+
const className = cn__default('flex flex-col font-bold text-xs leading-loose pb-4 min-h-[theme(spacing.18)]', {
|
|
7505
7503
|
'text-grey-300': disabled
|
|
7506
7504
|
}, props.className);
|
|
7507
|
-
const messageClassName =
|
|
7505
|
+
const messageClassName = cn__default('h-4 text-xs text-left leading-normal font-normal truncate -mb-4', {
|
|
7508
7506
|
'text-grey-700': !invalid && !warning,
|
|
7509
7507
|
'text-red-500': invalid,
|
|
7510
7508
|
'text-yellow-700': warning && !invalid,
|
|
@@ -7529,7 +7527,7 @@ const Form = /*#__PURE__*/React.forwardRef(function Form(props, ref) {
|
|
|
7529
7527
|
horizontal = false,
|
|
7530
7528
|
...otherProps
|
|
7531
7529
|
} = props;
|
|
7532
|
-
const className =
|
|
7530
|
+
const className = cn__default('yt-form', {
|
|
7533
7531
|
'yt-form--horizontal flex flex-wrap': horizontal
|
|
7534
7532
|
}, props.className);
|
|
7535
7533
|
return /*#__PURE__*/React.createElement("form", Object.assign({}, otherProps, {
|
|
@@ -7562,7 +7560,7 @@ const Anchor$1 = /*#__PURE__*/React.forwardRef(function HangerAnchor(props, exte
|
|
|
7562
7560
|
}), children);
|
|
7563
7561
|
});
|
|
7564
7562
|
const Title$3 = /*#__PURE__*/React.forwardRef(function DialogTitle(props, ref) {
|
|
7565
|
-
const className =
|
|
7563
|
+
const className = cn__default('mb-1 text-base font-bold flex w-full', props.className);
|
|
7566
7564
|
return /*#__PURE__*/React.createElement("span", Object.assign({}, props, {
|
|
7567
7565
|
className: className,
|
|
7568
7566
|
ref: ref
|
|
@@ -7577,7 +7575,7 @@ const Content$6 = /*#__PURE__*/React.forwardRef(function HangerContent(props, re
|
|
|
7577
7575
|
const {
|
|
7578
7576
|
texts
|
|
7579
7577
|
} = useLocalization();
|
|
7580
|
-
const className =
|
|
7578
|
+
const className = cn__default('wcag-blue-500 border border-transparent rounded p-3 pr-12 yt-shadow focus:border-transparent max-w-sm', props.className);
|
|
7581
7579
|
const handleInteractOutside = event => {
|
|
7582
7580
|
event.preventDefault();
|
|
7583
7581
|
};
|
|
@@ -7664,7 +7662,7 @@ const Content$7 = /*#__PURE__*/React.forwardRef(function HoverCardContent(props,
|
|
|
7664
7662
|
const {
|
|
7665
7663
|
placement: side
|
|
7666
7664
|
} = props;
|
|
7667
|
-
const className =
|
|
7665
|
+
const className = cn__default(getPopoverStyleClassnames(), 'min-w-[theme(spacing.40)] max-w-[theme(spacing.96)]', props.className);
|
|
7668
7666
|
return /*#__PURE__*/React.createElement(HoverCardPrimitive.Portal, null, /*#__PURE__*/React.createElement(HoverCardPrimitive.Content, {
|
|
7669
7667
|
className: className,
|
|
7670
7668
|
"data-taco": "hover-card",
|
|
@@ -7702,7 +7700,7 @@ const Item$1 = /*#__PURE__*/React__default.forwardRef(function Item(props, ref)
|
|
|
7702
7700
|
title,
|
|
7703
7701
|
...attributes
|
|
7704
7702
|
} = props;
|
|
7705
|
-
const iconClassName =
|
|
7703
|
+
const iconClassName = cn__default('flex shrink-0 h-10 w-10 items-center justify-center rounded-md border border-black/10', getSubtleColorShadeClasses(color !== null && color !== void 0 ? color : 'transparent'));
|
|
7706
7704
|
return /*#__PURE__*/React__default.createElement(Tag, Object.assign({}, attributes, {
|
|
7707
7705
|
"aria-disabled": disabled ? true : undefined,
|
|
7708
7706
|
"data-taco": "list-item",
|
|
@@ -7774,7 +7772,7 @@ const Switch = /*#__PURE__*/React.forwardRef(function Switch(props, ref) {
|
|
|
7774
7772
|
...otherProps
|
|
7775
7773
|
} = props;
|
|
7776
7774
|
const id = useId(props.id);
|
|
7777
|
-
const className =
|
|
7775
|
+
const className = cn__default('group h-5 w-9 flex flex-shrink-0 rounded-full inline-flex focus-visible:yt-focus', {
|
|
7778
7776
|
'mr-2': !!label,
|
|
7779
7777
|
'bg-grey-500 hover:bg-grey-700 aria-checked:bg-blue-500 aria-checked:hover:bg-blue-700': !props.disabled,
|
|
7780
7778
|
'bg-grey-500/50 aria-checked:bg-blue-500/50 cursor-not-allowed': props.disabled
|
|
@@ -7795,7 +7793,7 @@ const Switch = /*#__PURE__*/React.forwardRef(function Switch(props, ref) {
|
|
|
7795
7793
|
className: "pointer-events-none mt-0.5 h-4 w-4 translate-x-[0.15rem] rounded-full bg-white transition-transform will-change-transform group-disabled:opacity-50 group-aria-checked:translate-x-[1.1rem]"
|
|
7796
7794
|
}));
|
|
7797
7795
|
if (label) {
|
|
7798
|
-
const labelContainerClassName =
|
|
7796
|
+
const labelContainerClassName = cn__default('flex self-start cursor-pointer', {
|
|
7799
7797
|
'cursor-not-allowed text-grey-300': props.disabled
|
|
7800
7798
|
});
|
|
7801
7799
|
return /*#__PURE__*/React.createElement("span", {
|
|
@@ -7844,7 +7842,7 @@ const ToggleItem = /*#__PURE__*/React__default.forwardRef(function Toggle(props,
|
|
|
7844
7842
|
return;
|
|
7845
7843
|
}
|
|
7846
7844
|
}
|
|
7847
|
-
const className =
|
|
7845
|
+
const className = cn__default('group/toggle', props.className);
|
|
7848
7846
|
return /*#__PURE__*/React__default.createElement(Item$1, Object.assign({}, attributes, {
|
|
7849
7847
|
className: className,
|
|
7850
7848
|
onClick: handleClick,
|
|
@@ -8290,7 +8288,7 @@ const Listbox = /*#__PURE__*/React.forwardRef(function Listbox(props, ref) {
|
|
|
8290
8288
|
list,
|
|
8291
8289
|
input
|
|
8292
8290
|
} = useListbox(otherProps, ref);
|
|
8293
|
-
const className =
|
|
8291
|
+
const className = cn__default('bg-white inline-flex relative w-full', externalClassName);
|
|
8294
8292
|
return /*#__PURE__*/React.createElement("span", {
|
|
8295
8293
|
"data-taco": "listbox",
|
|
8296
8294
|
className: className
|
|
@@ -8313,7 +8311,7 @@ const MultiListbox = /*#__PURE__*/React.forwardRef(function Listbox(props, ref)
|
|
|
8313
8311
|
list,
|
|
8314
8312
|
input
|
|
8315
8313
|
} = useMultiListbox(otherProps, ref);
|
|
8316
|
-
const className =
|
|
8314
|
+
const className = cn__default('bg-white inline-flex relative w-full', externalClassName);
|
|
8317
8315
|
return /*#__PURE__*/React.createElement("span", {
|
|
8318
8316
|
"data-taco": "listbox",
|
|
8319
8317
|
className: className
|
|
@@ -8337,7 +8335,7 @@ const Content$8 = /*#__PURE__*/React.forwardRef(function MenuContent(props, ref)
|
|
|
8337
8335
|
placement: side,
|
|
8338
8336
|
...otherProps
|
|
8339
8337
|
} = props;
|
|
8340
|
-
const className =
|
|
8338
|
+
const className = cn__default('border border-transparent rounded block outline-none p-1 yt-shadow wcag-white', props.className);
|
|
8341
8339
|
// attach refs to each child
|
|
8342
8340
|
const childrenRefs = React.useRef([]);
|
|
8343
8341
|
const childrenWithRefs = React.Children.toArray(props.children).filter(child => !!child) // remove falsey children
|
|
@@ -8427,7 +8425,7 @@ const Shortcut = ({
|
|
|
8427
8425
|
keys,
|
|
8428
8426
|
...props
|
|
8429
8427
|
}) => {
|
|
8430
|
-
const className =
|
|
8428
|
+
const className = cn__default('inline-flex gap-0.5', props.className);
|
|
8431
8429
|
const texts = getShortcutText(keys);
|
|
8432
8430
|
return /*#__PURE__*/React__default.createElement("span", Object.assign({}, props, {
|
|
8433
8431
|
className: className
|
|
@@ -8456,7 +8454,7 @@ const useItemStyling = ({
|
|
|
8456
8454
|
menu === null || menu === void 0 ? void 0 : menu.registerIndentation();
|
|
8457
8455
|
}
|
|
8458
8456
|
}, [indented]);
|
|
8459
|
-
return
|
|
8457
|
+
return cn__default('flex items-center justify-start h-8 pr-1.5 relative rounded w-full focus:outline-none group', {
|
|
8460
8458
|
'pl-7': menu === null || menu === void 0 ? void 0 : menu.indented,
|
|
8461
8459
|
'pl-1.5': !(menu !== null && menu !== void 0 && menu.indented),
|
|
8462
8460
|
'cursor-pointer text-black hover:wcag-grey-200 data-[highlighted]:wcag-grey-200': !disabled,
|
|
@@ -8615,7 +8613,7 @@ const Checkbox$2 = /*#__PURE__*/React.forwardRef(function MenuCheckboxItem(props
|
|
|
8615
8613
|
});
|
|
8616
8614
|
|
|
8617
8615
|
const getRadioClassnames = (disabled = false, invalid = false) => {
|
|
8618
|
-
return
|
|
8616
|
+
return cn__default('flex flex-shrink-0 items-center justify-center h-4 w-4 mt-[0.2rem] rounded-full bg-white border-2 focus-visible:yt-focus disabled:cursor-not-allowed hover:border-4', invalid ? {
|
|
8619
8617
|
'border-red-500 hover:border-red-700 aria-checked:bg-red-500 aria-checked:border-red-500 hover:aria-checked:border-red-700': !disabled,
|
|
8620
8618
|
'border-red-500/50 aria-checked:bg-red-500/50 aria-checked:border-red-500/50': disabled
|
|
8621
8619
|
} : {
|
|
@@ -8638,8 +8636,8 @@ const RadioGroupItem = /*#__PURE__*/React.forwardRef(function RadioGroupItem(pro
|
|
|
8638
8636
|
...otherProps
|
|
8639
8637
|
} = props;
|
|
8640
8638
|
const isDisabled = context.disabled || props.disabled;
|
|
8641
|
-
const className =
|
|
8642
|
-
const labelClassName =
|
|
8639
|
+
const className = cn__default('self-start', getRadioClassnames(isDisabled, context.invalid));
|
|
8640
|
+
const labelClassName = cn__default('flex items-center gap-2', {
|
|
8643
8641
|
'cursor-pointer': !isDisabled,
|
|
8644
8642
|
'cursor-not-allowed text-grey-300': isDisabled
|
|
8645
8643
|
}, props.className);
|
|
@@ -8706,7 +8704,7 @@ const RadioGroup = /*#__PURE__*/React.forwardRef(function RadioGroup(props, ref)
|
|
|
8706
8704
|
context,
|
|
8707
8705
|
props: otherProps
|
|
8708
8706
|
} = useRadioGroup(props);
|
|
8709
|
-
const className =
|
|
8707
|
+
const className = cn__default('flex items-start gap-y-2', {
|
|
8710
8708
|
'flex-wrap gap-x-4 ': otherProps.orientation === 'horizontal',
|
|
8711
8709
|
'flex-col': otherProps.orientation === 'vertical'
|
|
8712
8710
|
}, otherProps.className);
|
|
@@ -8751,7 +8749,7 @@ const RadioGroup$1 = /*#__PURE__*/React.forwardRef(function MenuRadioItem(props,
|
|
|
8751
8749
|
context,
|
|
8752
8750
|
props: otherProps
|
|
8753
8751
|
} = useRadioGroup(props);
|
|
8754
|
-
const className =
|
|
8752
|
+
const className = cn__default('flex flex-col', props.className);
|
|
8755
8753
|
return /*#__PURE__*/React.createElement(MenuRadioGroupContext.Provider, {
|
|
8756
8754
|
value: context
|
|
8757
8755
|
}, /*#__PURE__*/React.createElement(DropdownMenuPrimitive.RadioGroup, Object.assign({}, otherProps, {
|
|
@@ -8771,7 +8769,7 @@ const Separator = /*#__PURE__*/React.forwardRef(function Separator(props, ref) {
|
|
|
8771
8769
|
|
|
8772
8770
|
const Header = /*#__PURE__*/React.forwardRef(function MenuHeader(props, ref) {
|
|
8773
8771
|
const menu = useCurrentMenu();
|
|
8774
|
-
const className =
|
|
8772
|
+
const className = cn__default('flex items-center justify-start h-7 pr-1.5 text-xs text-grey-700', {
|
|
8775
8773
|
'pl-7': menu === null || menu === void 0 ? void 0 : menu.indented,
|
|
8776
8774
|
'pl-1.5': !(menu !== null && menu !== void 0 && menu.indented)
|
|
8777
8775
|
}, props.className);
|
|
@@ -8787,7 +8785,7 @@ const SubMenu = /*#__PURE__*/React.forwardRef(function MenuSubMenu(props, ref) {
|
|
|
8787
8785
|
children,
|
|
8788
8786
|
...otherProps
|
|
8789
8787
|
} = props;
|
|
8790
|
-
const className =
|
|
8788
|
+
const className = cn__default('border border-transparent rounded block outline-none p-1 yt-shadow wcag-white', props.className);
|
|
8791
8789
|
return /*#__PURE__*/React.createElement(DropdownMenuPrimitive.Portal, null, /*#__PURE__*/React.createElement(DropdownMenuPrimitive.SubContent, Object.assign({}, otherProps, {
|
|
8792
8790
|
className: className,
|
|
8793
8791
|
"data-taco": "menu-submenu",
|
|
@@ -8847,7 +8845,7 @@ const ModeSwitch = /*#__PURE__*/React.forwardRef(function ModeSwitch(props, ref)
|
|
|
8847
8845
|
onChange,
|
|
8848
8846
|
...otherProps
|
|
8849
8847
|
} = props;
|
|
8850
|
-
const className =
|
|
8848
|
+
const className = cn__default('group w-14 h-8 flex flex-shrink-0 rounded-full inline-flex focus-visible:yt-focus p-1', {
|
|
8851
8849
|
'bg-grey-500 hover:bg-grey-700 aria-checked:bg-blue-500 aria-checked:hover:bg-blue-700': !props.disabled,
|
|
8852
8850
|
'bg-grey-500 aria-checked:bg-blue-500 cursor-not-allowed opacity-50': props.disabled
|
|
8853
8851
|
}, props.className);
|
|
@@ -8886,7 +8884,7 @@ const TreeviewGroup = /*#__PURE__*/React__default.forwardRef(function TreeviewGr
|
|
|
8886
8884
|
setExpanded(fixed || initialExpanded);
|
|
8887
8885
|
}
|
|
8888
8886
|
}, [fixed, initialExpanded]);
|
|
8889
|
-
const listClassName =
|
|
8887
|
+
const listClassName = cn__default('flex-col mb-0', {
|
|
8890
8888
|
flex: expanded,
|
|
8891
8889
|
hidden: !expanded
|
|
8892
8890
|
});
|
|
@@ -8975,7 +8973,7 @@ const Item$3 = /*#__PURE__*/React__default.forwardRef(function Item(props, ref)
|
|
|
8975
8973
|
const proxyRef = useMergedRef(ref);
|
|
8976
8974
|
const [isDraggedOver, dropTargetProps] = useDropTarget(onDrop);
|
|
8977
8975
|
const isTreeitem = role === 'treeitem';
|
|
8978
|
-
const className =
|
|
8976
|
+
const className = cn__default('yt-navigation__item cursor-pointer', {
|
|
8979
8977
|
'w-full mb-px py-1 px-3 flex items-center hover:bg-grey-300': isTreeitem,
|
|
8980
8978
|
'bg-white w-full h-10 px-3 flex-shrink-0 flex items-center justify-between cursor-pointer': !isTreeitem,
|
|
8981
8979
|
'yt-navigation__item--active': active && !isDraggedOver,
|
|
@@ -9005,16 +9003,16 @@ const Item$3 = /*#__PURE__*/React__default.forwardRef(function Item(props, ref)
|
|
|
9005
9003
|
});
|
|
9006
9004
|
const Panel = /*#__PURE__*/React__default.forwardRef(function Panel(props, ref) {
|
|
9007
9005
|
return /*#__PURE__*/React__default.createElement("div", Object.assign({}, props, {
|
|
9008
|
-
className:
|
|
9006
|
+
className: cn__default('w-full bg-white p-3', props.className),
|
|
9009
9007
|
ref: ref
|
|
9010
9008
|
}));
|
|
9011
9009
|
});
|
|
9012
9010
|
const MenuGroup = /*#__PURE__*/React__default.forwardRef(function MenuGroup(props, ref) {
|
|
9013
|
-
const className =
|
|
9011
|
+
const className = cn__default('flex-shrink-0 space-y-1 outline-none', {
|
|
9014
9012
|
'bg-white pb-2': props.fixed
|
|
9015
9013
|
}, typeof props.className === 'function' ? props.className(false) : props.className);
|
|
9016
9014
|
const title = expanded => {
|
|
9017
|
-
const className =
|
|
9015
|
+
const className = cn__default('bg-white h-10 pl-3 pr-1 flex items-center justify-between w-full', {
|
|
9018
9016
|
'mb-1': expanded,
|
|
9019
9017
|
'cursor-pointer hover:text-blue-500': !props.fixed
|
|
9020
9018
|
});
|
|
@@ -9049,7 +9047,7 @@ const Menu$2 = /*#__PURE__*/React__default.forwardRef(function Menu(props, ref)
|
|
|
9049
9047
|
return scrollableAreas;
|
|
9050
9048
|
}, [props.children]);
|
|
9051
9049
|
return /*#__PURE__*/React__default.createElement(Treeview, Object.assign({}, props, {
|
|
9052
|
-
className:
|
|
9050
|
+
className: cn__default('divide-grey-100 flex flex-grow flex-col divide-y-2 overflow-y-auto', props.className),
|
|
9053
9051
|
ref: ref
|
|
9054
9052
|
}), scrollableAreas.map((area, i) => Array.isArray(area) ? (/*#__PURE__*/React__default.createElement("div", {
|
|
9055
9053
|
className: "divide-grey-100 flex h-0 flex-auto flex-shrink-0 flex-grow flex-col divide-y-2 overflow-y-auto",
|
|
@@ -9062,7 +9060,7 @@ const Navigation = /*#__PURE__*/React__default.forwardRef(function Navigation(pr
|
|
|
9062
9060
|
children,
|
|
9063
9061
|
...otherProps
|
|
9064
9062
|
} = props;
|
|
9065
|
-
const className =
|
|
9063
|
+
const className = cn__default('h-full flex flex-col bg-grey-100 divide-y-2 divide-grey-100', props.className);
|
|
9066
9064
|
return /*#__PURE__*/React__default.createElement("div", Object.assign({}, otherProps, {
|
|
9067
9065
|
className: className,
|
|
9068
9066
|
"data-taco": "navigation",
|
|
@@ -9172,18 +9170,18 @@ const OverflowGroup = /*#__PURE__*/React__default.forwardRef(function OverflowGr
|
|
|
9172
9170
|
const MoreButton = (_moreButton = moreButton === null || moreButton === void 0 ? void 0 : moreButton(moreButtonText)) !== null && _moreButton !== void 0 ? _moreButton : /*#__PURE__*/React__default.createElement(IconButton, {
|
|
9173
9171
|
icon: "more"
|
|
9174
9172
|
});
|
|
9175
|
-
const className =
|
|
9173
|
+
const className = cn__default('flex overflow-hidden', props.className);
|
|
9176
9174
|
return /*#__PURE__*/React__default.createElement("div", Object.assign({}, attributes, {
|
|
9177
9175
|
className: className,
|
|
9178
9176
|
"data-taco": "overflow-group",
|
|
9179
9177
|
ref: internalRef
|
|
9180
9178
|
}), children.map((child, index) => /*#__PURE__*/React__default.cloneElement(child, {
|
|
9181
|
-
className:
|
|
9179
|
+
className: cn__default(child.props.className, {
|
|
9182
9180
|
visible: intersectedChildIndex === undefined || index < intersectedChildIndex,
|
|
9183
9181
|
'invisible order-[100] pointer-events-none': intersectedChildIndex !== undefined && index >= intersectedChildIndex
|
|
9184
9182
|
})
|
|
9185
9183
|
})), hiddenChildren.length ? /*#__PURE__*/React__default.cloneElement(MoreButton, {
|
|
9186
|
-
className:
|
|
9184
|
+
className: cn__default('sticky right-0 order-[99]', MoreButton.props.className),
|
|
9187
9185
|
'data-observer-ignore': true,
|
|
9188
9186
|
menu: menuProps => (/*#__PURE__*/React__default.createElement(Menu$1, Object.assign({}, menuProps), /*#__PURE__*/React__default.createElement(Menu$1.Content, null, hiddenChildren.map((child, index) => wrapChild ? (/*#__PURE__*/React__default.createElement(Menu$1.Item, {
|
|
9189
9187
|
key: index
|
|
@@ -9339,7 +9337,7 @@ const useSelect = ({
|
|
|
9339
9337
|
const item = findByValue(flattenedData, value);
|
|
9340
9338
|
if (item) {
|
|
9341
9339
|
text = item.icon ? (/*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.cloneElement(item.icon, {
|
|
9342
|
-
className:
|
|
9340
|
+
className: cn__default(item.icon.props.className, 'mr-1 -mt-px')
|
|
9343
9341
|
}), item.text)) : item.text;
|
|
9344
9342
|
}
|
|
9345
9343
|
}
|
|
@@ -9449,10 +9447,10 @@ const BaseSelect = /*#__PURE__*/React.forwardRef(function BaseSelect(props, ref)
|
|
|
9449
9447
|
} = useSelect(otherProps, ref);
|
|
9450
9448
|
const internalRef = React.useRef(null);
|
|
9451
9449
|
const selectDimensions = useBoundingClientRectListener(internalRef);
|
|
9452
|
-
const className =
|
|
9450
|
+
const className = cn__default('inline-flex relative w-full', {
|
|
9453
9451
|
'yt-select--readonly': props.readOnly
|
|
9454
9452
|
}, externalClassName);
|
|
9455
|
-
const inputClassname =
|
|
9453
|
+
const inputClassname = cn__default(getInputClasses(props), 'h-8 text-left !pr-0', {
|
|
9456
9454
|
'border-blue-500': popover.open,
|
|
9457
9455
|
'select-text': otherProps.readOnly
|
|
9458
9456
|
});
|
|
@@ -9600,7 +9598,7 @@ const Pagination = /*#__PURE__*/React.forwardRef(function Pagination(props, ref)
|
|
|
9600
9598
|
const pageCount = Math.ceil(length / pageSize);
|
|
9601
9599
|
const canPreviousPage = pageIndex > 0;
|
|
9602
9600
|
const canNextPage = pageIndex < pageCount - 1;
|
|
9603
|
-
const className =
|
|
9601
|
+
const className = cn__default('inline-flex relative justify-between items-center', props.className);
|
|
9604
9602
|
return /*#__PURE__*/React.createElement("div", Object.assign({}, otherProps, {
|
|
9605
9603
|
className: className,
|
|
9606
9604
|
"data-taco": "pagination",
|
|
@@ -9667,8 +9665,8 @@ const Progress = ({
|
|
|
9667
9665
|
animationDuration: `${duration}ms`
|
|
9668
9666
|
};
|
|
9669
9667
|
}
|
|
9670
|
-
const className =
|
|
9671
|
-
const progressClassName =
|
|
9668
|
+
const className = cn__default('bg-grey-100 rounded block h-1 overflow-hidden w-full', props.className);
|
|
9669
|
+
const progressClassName = cn__default('yt-progress__bar block h-1', {
|
|
9672
9670
|
"w-full before:h-1 before:bg-grey-300 before:block before:animate-[progress-indeterminate_2s_cubic-bezier(0.4,0,0.2,1)_infinite] before:content-[' ']": !duration,
|
|
9673
9671
|
[`w-0 bg-grey-300 animate-[progress_linear]`]: duration
|
|
9674
9672
|
});
|
|
@@ -9733,7 +9731,7 @@ const Toast = ({
|
|
|
9733
9731
|
autoClose,
|
|
9734
9732
|
type = 'default'
|
|
9735
9733
|
} = options;
|
|
9736
|
-
const className =
|
|
9734
|
+
const className = cn__default('bg-white relative flex items-center py-1 px-2 mt-3 w-full rounded yt-shadow print:hidden', {
|
|
9737
9735
|
'border border-grey-200': type === 'default' || type === 'loading' || !type,
|
|
9738
9736
|
'border border-grey-500': type === 'success',
|
|
9739
9737
|
'border border-blue-500': type === 'information',
|
|
@@ -12647,7 +12645,7 @@ function Actions$1(props) {
|
|
|
12647
12645
|
const visibleActions = actions.map(action => action(data, rowId, tableMeta.rowActions.handlers['cleanup'], table)).filter(action => !!action);
|
|
12648
12646
|
const actionsOnRow = visibleActions.length === actionsLength ? visibleActions : visibleActions.slice(0, actionsLength - 1);
|
|
12649
12647
|
const actionsInMenu = visibleActions.slice(visibleActions.length === actionsLength ? actionsLength : actionsLength - 1);
|
|
12650
|
-
const className =
|
|
12648
|
+
const className = cn__default('flex justify-end text-right bg-[inherit] shadow-[-6px_0px_6px_var(--table-row-actions-shadow)] print:hidden');
|
|
12651
12649
|
return /*#__PURE__*/React__default.createElement("span", {
|
|
12652
12650
|
className: className
|
|
12653
12651
|
}, actionsOnRow.map((button, index) => {
|
|
@@ -12711,7 +12709,7 @@ const renderer = {
|
|
|
12711
12709
|
renderer: Cell,
|
|
12712
12710
|
meta: {
|
|
12713
12711
|
align: 'right',
|
|
12714
|
-
className: /*#__PURE__*/
|
|
12712
|
+
className: /*#__PURE__*/cn__default('print:opacity-0 !px-0 !pr-1 overflow-hidden [table_&]:group-[[data-row-active="true"]]/row:sticky right-0', 'group-[[data-row-active="true"][data-selected="false"]]/row:text-grey-200', 'group-[[data-row-selected="true"]]/row:text-blue-100', 'group-[[data-row-selected="false"]:hover]/row:text-grey-100'),
|
|
12715
12713
|
// TODO: remove when table3 is migrated, this satisfies the legacy table3 type
|
|
12716
12714
|
enableSearch: false,
|
|
12717
12715
|
header: ''
|
|
@@ -12734,7 +12732,7 @@ function Cell$1() {
|
|
|
12734
12732
|
return /*#__PURE__*/React__default.createElement(Icon, {
|
|
12735
12733
|
"aria-label": texts.table.columns.drag.tooltip,
|
|
12736
12734
|
name: "drag",
|
|
12737
|
-
className:
|
|
12735
|
+
className: cn__default("text-grey-darkest invisible -mt-1 ml-[2px] cursor-grab active:cursor-grabbing group-hover/row:visible group-[[aria-grabbed='true']]/row:text-white", '[[data-table-editing-mode]_&]:!invisible')
|
|
12738
12736
|
});
|
|
12739
12737
|
}
|
|
12740
12738
|
const renderer$1 = {
|
|
@@ -13274,7 +13272,7 @@ const DisplayRow = /*#__PURE__*/React__default.memo(function DisplayRow(props) {
|
|
|
13274
13272
|
const expansionRef = React__default.useRef(null);
|
|
13275
13273
|
const isExpanded = !!attributes['data-row-expanded'];
|
|
13276
13274
|
useSetVirtualisedRowHeight(measureRow, ref.current, expansionRef.current, isExpanded);
|
|
13277
|
-
const className =
|
|
13275
|
+
const className = cn__default('group/row', otherAttributes.className, {
|
|
13278
13276
|
'hover:cursor-grab': tableMeta.rowDrag.isEnabled && typeof attributes.onClick !== 'function',
|
|
13279
13277
|
'hover:cursor-pointer': typeof attributes.onClick === 'function'
|
|
13280
13278
|
});
|
|
@@ -13429,14 +13427,14 @@ function Resizer(props) {
|
|
|
13429
13427
|
}
|
|
13430
13428
|
};
|
|
13431
13429
|
const handle = /*#__PURE__*/React__default.createElement("div", {
|
|
13432
|
-
className:
|
|
13430
|
+
className: cn__default('invisible absolute right-0 top-0 z-10 -mr-2 flex h-full w-4 cursor-col-resize touch-none select-none justify-center rounded py-0.5', 'group-hover/header:visible', '[th:last-child>&]:!mr-0 [th:last-child>&]:w-2', {
|
|
13433
13431
|
'!visible': isResizing
|
|
13434
13432
|
}),
|
|
13435
13433
|
onClick: handleClick,
|
|
13436
13434
|
onMouseDown: handleResize,
|
|
13437
13435
|
onTouchStart: handleResize
|
|
13438
13436
|
}, /*#__PURE__*/React__default.createElement("div", {
|
|
13439
|
-
className:
|
|
13437
|
+
className: cn__default('h-full w-1 rounded', {
|
|
13440
13438
|
'!bg-blue-500': isResizing,
|
|
13441
13439
|
'bg-grey-500 hover:bg-grey-700': !isResizing
|
|
13442
13440
|
})
|
|
@@ -13654,7 +13652,7 @@ function HeaderMenu(props) {
|
|
|
13654
13652
|
}));
|
|
13655
13653
|
}, [canFilter, canGoto, canHide, canPin, canSort, customMenu, handleGoto, handleSortToggle, index, isFiltered, sortDirection]);
|
|
13656
13654
|
// can't use display: none because the button needs to be focusable
|
|
13657
|
-
const className =
|
|
13655
|
+
const className = cn__default(
|
|
13658
13656
|
// positioning
|
|
13659
13657
|
'justify-end overflow-hidden',
|
|
13660
13658
|
// sizing
|
|
@@ -13746,7 +13744,7 @@ function Header$5(props) {
|
|
|
13746
13744
|
canPin,
|
|
13747
13745
|
canResize,
|
|
13748
13746
|
canSort,
|
|
13749
|
-
className:
|
|
13747
|
+
className: cn__default('group/header', columnMeta.headerClassName),
|
|
13750
13748
|
children: reactTable.flexRender(header.column.columnDef.header, header.getContext()),
|
|
13751
13749
|
colSpan: header.colSpan,
|
|
13752
13750
|
customMenu: columnMeta.menu,
|
|
@@ -13767,7 +13765,7 @@ function Header$5(props) {
|
|
|
13767
13765
|
};
|
|
13768
13766
|
if (header.isPlaceholder) {
|
|
13769
13767
|
const nextHeader = header.headerGroup.headers[header.index + 1];
|
|
13770
|
-
memoedProps.className =
|
|
13768
|
+
memoedProps.className = cn__default('!bg-white before:!content-none', memoedProps.className, {
|
|
13771
13769
|
'after:!content-none': nextHeader === null || nextHeader === void 0 ? void 0 : nextHeader.isPlaceholder
|
|
13772
13770
|
});
|
|
13773
13771
|
}
|
|
@@ -13891,7 +13889,7 @@ const MemoedHeader = /*#__PURE__*/React__default.memo(function MemoedHeader(prop
|
|
|
13891
13889
|
canHide: canHide,
|
|
13892
13890
|
canPin: canPin,
|
|
13893
13891
|
canSort: canSort,
|
|
13894
|
-
className:
|
|
13892
|
+
className: cn__default({
|
|
13895
13893
|
'ml-auto': align !== 'right',
|
|
13896
13894
|
'ml-0': align === 'right'
|
|
13897
13895
|
}),
|
|
@@ -14282,7 +14280,7 @@ const SearchInput2 = /*#__PURE__*/React__default.forwardRef(function SearchInput
|
|
|
14282
14280
|
}
|
|
14283
14281
|
});
|
|
14284
14282
|
}
|
|
14285
|
-
const className =
|
|
14283
|
+
const className = cn__default('!pl-7 group-focus-within:!w-72 group-focus-within:yt-focus', hasFind ? {
|
|
14286
14284
|
'!w-48': !value,
|
|
14287
14285
|
'!w-72': value
|
|
14288
14286
|
} : '!w-48', {
|
|
@@ -14312,9 +14310,9 @@ const SearchInput2 = /*#__PURE__*/React__default.forwardRef(function SearchInput
|
|
|
14312
14310
|
value: value !== null && value !== void 0 ? value : ''
|
|
14313
14311
|
}));
|
|
14314
14312
|
if (settingsContent) {
|
|
14315
|
-
const settingsClassname =
|
|
14313
|
+
const settingsClassname = cn__default('border-grey-300 absolute left-0 right-0 -mt-0.5 hidden top-full group-focus-within:flex focus-within:flex flex-col gap-y-4 rounded-b border border-t-0 bg-white p-3 shadow !pt-[calc(theme(spacing.3)_+_theme(spacing[0.5]))]');
|
|
14316
14314
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
14317
|
-
className:
|
|
14315
|
+
className: cn__default('group relative', {
|
|
14318
14316
|
'z-10 [&_[data-taco=input-container]]:z-10': focused
|
|
14319
14317
|
}),
|
|
14320
14318
|
ref: containerRef,
|
|
@@ -14596,7 +14594,7 @@ const Column = /*#__PURE__*/React__default.forwardRef(function Column(props, ref
|
|
|
14596
14594
|
...dragAttributes
|
|
14597
14595
|
} = props;
|
|
14598
14596
|
const canHide = column.getCanHide();
|
|
14599
|
-
const className =
|
|
14597
|
+
const className = cn__default('group/column flex items-center gap-x-2 rounded py-1 px-2', {
|
|
14600
14598
|
'hover:bg-grey-200': canHide || draggable,
|
|
14601
14599
|
'hover:cursor-pointer': canHide,
|
|
14602
14600
|
'active:cursor-move active:bg-grey-300': draggable
|
|
@@ -15130,7 +15128,7 @@ const Tag$1 = /*#__PURE__*/React__default.forwardRef((props, ref) => {
|
|
|
15130
15128
|
...otherProps
|
|
15131
15129
|
} = props;
|
|
15132
15130
|
const textRef = React__default.useRef(null);
|
|
15133
|
-
const className =
|
|
15131
|
+
const className = cn__default('inline-flex items-center rounded h-6 cursor-default', {
|
|
15134
15132
|
'opacity-50': disabled,
|
|
15135
15133
|
'hover:bg-opacity-75': !disabled,
|
|
15136
15134
|
'cursor-pointer': !!otherProps.onClick,
|
|
@@ -15147,7 +15145,7 @@ const Tag$1 = /*#__PURE__*/React__default.forwardRef((props, ref) => {
|
|
|
15147
15145
|
name: icon,
|
|
15148
15146
|
className: "-ml-1 mr-1 !h-5 !w-5"
|
|
15149
15147
|
})) : (/*#__PURE__*/React__default.cloneElement(icon, {
|
|
15150
|
-
className:
|
|
15148
|
+
className: cn__default(icon.props.className, 'mr-1 -ml-1')
|
|
15151
15149
|
})) : null, /*#__PURE__*/React__default.createElement("span", {
|
|
15152
15150
|
className: "truncate"
|
|
15153
15151
|
}, children)), onDelete ? (/*#__PURE__*/React__default.createElement(Icon, {
|
|
@@ -15157,7 +15155,7 @@ const Tag$1 = /*#__PURE__*/React__default.forwardRef((props, ref) => {
|
|
|
15157
15155
|
})) : null);
|
|
15158
15156
|
});
|
|
15159
15157
|
|
|
15160
|
-
const createOptionClassName = (shouldPauseHoverState = false) =>
|
|
15158
|
+
const createOptionClassName = (shouldPauseHoverState = false) => cn__default('group mb-px flex w-full text-sm flex-shrink-0 font-normal cursor-pointer items-center rounded bg-white px-2 leading-8 text-black aria-hidden:hidden gap-1.5 bg-white aria-current:wcag-grey-200 aria-disabled:text-black/25 aria-disabled:pointer-events-none !justify-normal', {
|
|
15161
15159
|
'hover:wcag-grey-200': !shouldPauseHoverState
|
|
15162
15160
|
});
|
|
15163
15161
|
const createCollectionClassName = () => 'flex flex-col gap-px';
|
|
@@ -15307,7 +15305,7 @@ const EditPopover = props => {
|
|
|
15307
15305
|
}) => (/*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement("div", {
|
|
15308
15306
|
className: "flex w-32 flex-col space-y-2"
|
|
15309
15307
|
}, onEdit ? (/*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(Field, {
|
|
15310
|
-
className:
|
|
15308
|
+
className: cn__default('!min-h-fit', {
|
|
15311
15309
|
'!pb-0': !validationError
|
|
15312
15310
|
}),
|
|
15313
15311
|
invalid: !!validationError,
|
|
@@ -15355,7 +15353,7 @@ const Colours = props => {
|
|
|
15355
15353
|
value: color
|
|
15356
15354
|
}, AVAILABLE_COLORS.map(availableColor => (/*#__PURE__*/React__default.createElement(RadioGroupPrimitive.Item, {
|
|
15357
15355
|
"aria-label": color,
|
|
15358
|
-
className:
|
|
15356
|
+
className: cn__default('flex h-6 w-6 cursor-pointer items-center justify-center rounded', getSubtleColorShadeClasses(availableColor)),
|
|
15359
15357
|
key: availableColor,
|
|
15360
15358
|
onFocus: () => onChangeColor(availableColor),
|
|
15361
15359
|
value: availableColor
|
|
@@ -15393,7 +15391,7 @@ const Option$1 = /*#__PURE__*/React__default.forwardRef(function Select2Option(p
|
|
|
15393
15391
|
tags,
|
|
15394
15392
|
value
|
|
15395
15393
|
} = useSelect2Context();
|
|
15396
|
-
const className =
|
|
15394
|
+
const className = cn__default(createOptionClassName(shouldPauseHoverState), getFontSize(fontSize), cName);
|
|
15397
15395
|
const hasValue = Array.isArray(value) ? !!value.length : value !== undefined;
|
|
15398
15396
|
const isTag = tags && !!color;
|
|
15399
15397
|
const handleClick = () => {
|
|
@@ -15450,7 +15448,7 @@ const Option$1 = /*#__PURE__*/React__default.forwardRef(function Select2Option(p
|
|
|
15450
15448
|
})) : postfix : null)))), popover ? (/*#__PURE__*/React__default.createElement(IconButton, {
|
|
15451
15449
|
icon: "ellipsis-vertical",
|
|
15452
15450
|
appearance: "discrete",
|
|
15453
|
-
className:
|
|
15451
|
+
className: cn__default('group-aria-current:visible invisible -mr-1 ml-auto !h-5 min-h-[theme(spacing.6)] !w-5 min-w-[theme(spacing.6)] hover:!bg-black/[.08] focus:!shadow-none group-hover:visible', {
|
|
15454
15452
|
'!visible': isMobileDevice((_window = window) === null || _window === void 0 ? void 0 : _window.navigator)
|
|
15455
15453
|
}),
|
|
15456
15454
|
onClick: event => {
|
|
@@ -15470,7 +15468,7 @@ const Group$3 = /*#__PURE__*/React__default.forwardRef(function Select2Group(pro
|
|
|
15470
15468
|
hasSeparator,
|
|
15471
15469
|
...attributes
|
|
15472
15470
|
} = props;
|
|
15473
|
-
const className =
|
|
15471
|
+
const className = cn__default(createCollectionClassName(), {
|
|
15474
15472
|
"last:after:content-none after:content-[''] after:bg-grey-300 after:mx-2 after:my-1 after:h-px": hasSeparator && children.length
|
|
15475
15473
|
}, props.className);
|
|
15476
15474
|
return /*#__PURE__*/React__default.createElement(Group$2, Object.assign({}, attributes, {
|
|
@@ -15482,7 +15480,7 @@ const Group$3 = /*#__PURE__*/React__default.forwardRef(function Select2Group(pro
|
|
|
15482
15480
|
});
|
|
15483
15481
|
|
|
15484
15482
|
const Title$5 = /*#__PURE__*/React__default.forwardRef(function Select2Title(props, ref) {
|
|
15485
|
-
const className =
|
|
15483
|
+
const className = cn__default('flex items-center text-xs pl-2 h-8', props.className);
|
|
15486
15484
|
return /*#__PURE__*/React__default.createElement(Title$4, Object.assign({}, props, {
|
|
15487
15485
|
className: className,
|
|
15488
15486
|
ref: ref
|
|
@@ -15498,7 +15496,7 @@ const Placeholder = ({
|
|
|
15498
15496
|
return null;
|
|
15499
15497
|
}
|
|
15500
15498
|
return /*#__PURE__*/React__default.createElement("div", Object.assign({}, props, {
|
|
15501
|
-
className:
|
|
15499
|
+
className: cn__default({
|
|
15502
15500
|
'text-grey-700': disabled,
|
|
15503
15501
|
'text-grey-500': !disabled
|
|
15504
15502
|
})
|
|
@@ -15539,7 +15537,7 @@ const Button$3 = /*#__PURE__*/React__default.forwardRef(function Select2TriggerB
|
|
|
15539
15537
|
open,
|
|
15540
15538
|
readOnly
|
|
15541
15539
|
} = useSelect2Context();
|
|
15542
|
-
const className =
|
|
15540
|
+
const className = cn__default('px-1.5 h-fit', getInputClasses({
|
|
15543
15541
|
...props,
|
|
15544
15542
|
disabled,
|
|
15545
15543
|
highlighted,
|
|
@@ -15613,7 +15611,7 @@ const Single = /*#__PURE__*/React__default.forwardRef(function Select2TriggerSin
|
|
|
15613
15611
|
readOnly,
|
|
15614
15612
|
tags
|
|
15615
15613
|
} = useSelect2Context();
|
|
15616
|
-
const contentClassName =
|
|
15614
|
+
const contentClassName = cn__default('truncate flex items-center gap-1');
|
|
15617
15615
|
const currentValue = children.find(matchesValue(value));
|
|
15618
15616
|
let output;
|
|
15619
15617
|
if (placeholder && currentValue === undefined) {
|
|
@@ -15671,7 +15669,7 @@ const Multiple = /*#__PURE__*/React__default.forwardRef(function Select2TriggerM
|
|
|
15671
15669
|
className
|
|
15672
15670
|
} = buttonProps;
|
|
15673
15671
|
if (open) {
|
|
15674
|
-
className =
|
|
15672
|
+
className = cn__default('!absolute z-20 !h-fit', buttonProps.className);
|
|
15675
15673
|
content = /*#__PURE__*/React__default.createElement(ScrollArea, {
|
|
15676
15674
|
className: "my-1 flex max-h-[5.5rem] flex-col",
|
|
15677
15675
|
onClick: forwardClick
|
|
@@ -15771,14 +15769,14 @@ const MultipleValue = ({
|
|
|
15771
15769
|
if (typeof child.props.children === 'string') {
|
|
15772
15770
|
output = /*#__PURE__*/React__default.createElement(Tag$1, {
|
|
15773
15771
|
key: String(child.props.value),
|
|
15774
|
-
className:
|
|
15772
|
+
className: cn__default('cursor-pointer', classNames),
|
|
15775
15773
|
color: tags ? child.props.color : undefined,
|
|
15776
15774
|
disabled: disabled,
|
|
15777
15775
|
icon: child.props.prefix,
|
|
15778
15776
|
readOnly: readOnly
|
|
15779
15777
|
}, child.props.children);
|
|
15780
15778
|
} else output = /*#__PURE__*/React__default.cloneElement(child.props.children, {
|
|
15781
|
-
className:
|
|
15779
|
+
className: cn__default('cursor-pointer', {
|
|
15782
15780
|
'shrink-0': index !== boundaryIndex
|
|
15783
15781
|
}, classNames),
|
|
15784
15782
|
key: String(child.props.value)
|
|
@@ -15916,7 +15914,7 @@ const Search$2 = /*#__PURE__*/React__default.forwardRef(function ListboxSearch(p
|
|
|
15916
15914
|
}
|
|
15917
15915
|
};
|
|
15918
15916
|
return /*#__PURE__*/React__default.createElement(Field, {
|
|
15919
|
-
className:
|
|
15917
|
+
className: cn__default('mx-1.5 mb-1.5 !min-h-fit', {
|
|
15920
15918
|
'!pb-0': !validationError
|
|
15921
15919
|
}),
|
|
15922
15920
|
invalid: !!validationError,
|
|
@@ -16053,7 +16051,7 @@ const Create = props => {
|
|
|
16053
16051
|
event.currentTarget.click();
|
|
16054
16052
|
}
|
|
16055
16053
|
};
|
|
16056
|
-
const className =
|
|
16054
|
+
const className = cn__default(createOptionClassName(), {
|
|
16057
16055
|
'!w-[calc(100%_-_theme(spacing.3))] ml-1.5': !createDialog,
|
|
16058
16056
|
'leading-normal border-grey-300 h-9 border-t py-2.5 px-4 !-mb-1.5': !!createDialog
|
|
16059
16057
|
});
|
|
@@ -16290,7 +16288,7 @@ const Select2 = /*#__PURE__*/React__default.forwardRef(function Select2(props, r
|
|
|
16290
16288
|
setValue(nextValue);
|
|
16291
16289
|
}
|
|
16292
16290
|
};
|
|
16293
|
-
const className =
|
|
16291
|
+
const className = cn__default('border-grey-300 rounded border bg-white py-1.5 shadow-md ', {
|
|
16294
16292
|
'focus-within:yt-focus': !hasSearch,
|
|
16295
16293
|
'outline-none': hasSearch
|
|
16296
16294
|
}, createCollectionClassName());
|
|
@@ -16330,10 +16328,10 @@ const Select2 = /*#__PURE__*/React__default.forwardRef(function Select2(props, r
|
|
|
16330
16328
|
}, selectAllText), /*#__PURE__*/React__default.createElement("div", {
|
|
16331
16329
|
className: "border-grey-300 mx-3 rounded border-t"
|
|
16332
16330
|
}))))) : null, loading ? (/*#__PURE__*/React__default.createElement("span", {
|
|
16333
|
-
className:
|
|
16331
|
+
className: cn__default('text-grey-700 flex items-center italic', fontSize && getFontSize(fontSize))
|
|
16334
16332
|
}, /*#__PURE__*/React__default.createElement("span", null, /*#__PURE__*/React__default.createElement(Spinner, {
|
|
16335
16333
|
delay: 0,
|
|
16336
|
-
className:
|
|
16334
|
+
className: cn__default('ml-3 mr-2 mt-1.5 h-5 w-5', {
|
|
16337
16335
|
'!mt-1 !h-3.5 !w-3.5': fontSize === exports.FontSizes.small,
|
|
16338
16336
|
'!h-4 !w-4': fontSize === exports.FontSizes.medium,
|
|
16339
16337
|
'!h-5 !w-5': fontSize === exports.FontSizes.large
|
|
@@ -18267,7 +18265,7 @@ const useTable$1 = (props, ref) => {
|
|
|
18267
18265
|
const renderCell = (cell, row) => {
|
|
18268
18266
|
const props = {
|
|
18269
18267
|
...cell.getCellProps(),
|
|
18270
|
-
className:
|
|
18268
|
+
className: cn__default('yt-table__cell flex-1 truncate p-2 align-middle', cell.column.className, {
|
|
18271
18269
|
'justify-start text-left': cell.column.align === 'left',
|
|
18272
18270
|
'justify-end text-right': cell.column.align === 'right',
|
|
18273
18271
|
'text-center': !cell.column.align
|
|
@@ -18307,7 +18305,7 @@ const Row$1 = /*#__PURE__*/React__default.forwardRef(function TableRow({
|
|
|
18307
18305
|
minHeight: rowHeight ? `${rowHeight}px` : undefined,
|
|
18308
18306
|
paddingLeft: row.depth ? `${row.depth * 2}rem` : undefined
|
|
18309
18307
|
},
|
|
18310
|
-
className:
|
|
18308
|
+
className: cn__default('yt-table__row border-grey-300 flex border-b min-h-[2.5rem] hover:bg-grey-100', {
|
|
18311
18309
|
'yt-table__row--active bg-grey-200 hover:bg-grey-200': activeIndex === index,
|
|
18312
18310
|
'yt-table__row--clickable': !!onRowClick,
|
|
18313
18311
|
'yt-table__row--dragging': !!row.isDragging,
|
|
@@ -18365,7 +18363,7 @@ const Column$2 = ({
|
|
|
18365
18363
|
...(cell.getSortByToggleProps && cell.getSortByToggleProps({
|
|
18366
18364
|
title: undefined
|
|
18367
18365
|
})),
|
|
18368
|
-
className:
|
|
18366
|
+
className: cn__default('yt-table__cell flex flex-1 truncate p-2 align-middle text-grey-700 hover:text-black', cell.className, {
|
|
18369
18367
|
'yt-table__cell__group': !!cell.columns,
|
|
18370
18368
|
'cursor-pointer': !cell.disableSorting,
|
|
18371
18369
|
'justify-start text-left': cell.align === 'left',
|
|
@@ -18408,7 +18406,7 @@ const BaseTable = /*#__PURE__*/React__default.forwardRef(function BaseTable(prop
|
|
|
18408
18406
|
tableRef.current.focus();
|
|
18409
18407
|
}
|
|
18410
18408
|
}, []);
|
|
18411
|
-
const className =
|
|
18409
|
+
const className = cn__default('yt-table flex flex-col focus:yt-focus focus:rounded-sm', props.className);
|
|
18412
18410
|
return /*#__PURE__*/React__default.createElement("div", Object.assign({}, otherProps, {
|
|
18413
18411
|
role: "table",
|
|
18414
18412
|
className: className,
|
|
@@ -18592,7 +18590,7 @@ const WindowedTable = /*#__PURE__*/React__default.forwardRef(function WindowedTa
|
|
|
18592
18590
|
}, [rows.length]);
|
|
18593
18591
|
const contentHeight = estimatedRowHeight * props.data.length || 0;
|
|
18594
18592
|
const isScrollbarVisible = height !== null ? contentHeight > height : false;
|
|
18595
|
-
const className =
|
|
18593
|
+
const className = cn__default(tableProps.className, 'yt-table--windowed', {
|
|
18596
18594
|
'table-with-scrollbar': isScrollbarVisible
|
|
18597
18595
|
});
|
|
18598
18596
|
let list;
|
|
@@ -19637,7 +19635,7 @@ const Textarea = /*#__PURE__*/React.forwardRef(function Textarea(props, ref) {
|
|
|
19637
19635
|
onKeyDown,
|
|
19638
19636
|
...otherProps
|
|
19639
19637
|
} = props;
|
|
19640
|
-
const classNames =
|
|
19638
|
+
const classNames = cn__default(getInputClasses(props), 'pt-[5px] pb-[7px] min-h-[75px] disabled:resize-none !leading-5', props.className);
|
|
19641
19639
|
// home and end keys only navigate to the start/end of textarea value if the textarea container does not scroll
|
|
19642
19640
|
// if it has scroll height then the browser reverts to native scrolling behaviour only
|
|
19643
19641
|
// so we manually override it to ensure _our_ desired behaviour remains intact
|
|
@@ -20140,7 +20138,7 @@ function SaveStatus(props) {
|
|
|
20140
20138
|
} = useLocalization();
|
|
20141
20139
|
const tableMeta = table.options.meta;
|
|
20142
20140
|
const status = tableMeta.editing.getRowStatus(rowId);
|
|
20143
|
-
const className =
|
|
20141
|
+
const className = cn__default('col-span-full sticky ml-auto right-0 top-0 -mb-[100%] z-10 h-8 bg-[inherit] flex items-center px-1.5 shadow-[-6px_0px_6px_var(--table-row-actions-shadow)]', {
|
|
20144
20142
|
'mt-0.5': tableMeta.rowHeight.height === 'short',
|
|
20145
20143
|
'mt-1': tableMeta.rowHeight.height === 'medium',
|
|
20146
20144
|
'mt-1.5': tableMeta.rowHeight.height === 'tall',
|
|
@@ -20493,7 +20491,7 @@ function CreateNewRow(props) {
|
|
|
20493
20491
|
keys: shortcut
|
|
20494
20492
|
});
|
|
20495
20493
|
}
|
|
20496
|
-
const className =
|
|
20494
|
+
const className = cn__default('group/row border-grey-300 !sticky z-[21]', {
|
|
20497
20495
|
'bottom-10': tableMeta.footer.isEnabled,
|
|
20498
20496
|
'bottom-0': !tableMeta.footer.isEnabled,
|
|
20499
20497
|
'border-b': !isScrolled
|
|
@@ -20583,7 +20581,7 @@ function TemporaryRow(props) {
|
|
|
20583
20581
|
}
|
|
20584
20582
|
}
|
|
20585
20583
|
};
|
|
20586
|
-
const className =
|
|
20584
|
+
const className = cn__default('group/row border-grey-300 !sticky z-[22] print:hidden', {
|
|
20587
20585
|
'bottom-[calc(5rem_+_2px)] data-[row-editing-move]:bottom-[calc(5rem_+_2px)]': tableMeta.footer.isEnabled,
|
|
20588
20586
|
'bottom-[calc(2.5rem_+_2px)] data-[row-editing-move]:bottom-[calc(2.5rem_+_2px)]': !tableMeta.footer.isEnabled,
|
|
20589
20587
|
'border-t-2 shadow-[0px_-5px_20px_0px_rgba(0,0,0,0.1)] [&>td]:!border-b-0': isScrolled
|
|
@@ -20683,7 +20681,7 @@ const Tabs = /*#__PURE__*/React.forwardRef(function Tabs(props, ref) {
|
|
|
20683
20681
|
orientation = 'horizontal',
|
|
20684
20682
|
...otherProps
|
|
20685
20683
|
} = props;
|
|
20686
|
-
const className =
|
|
20684
|
+
const className = cn__default({
|
|
20687
20685
|
'flex w-full': orientation === 'vertical'
|
|
20688
20686
|
}, props.className);
|
|
20689
20687
|
return /*#__PURE__*/React.createElement(TabsPrimitive.Root, Object.assign({}, otherProps, {
|
|
@@ -20701,7 +20699,7 @@ const TabList = /*#__PURE__*/React.forwardRef(function Tab(props, ref) {
|
|
|
20701
20699
|
const {
|
|
20702
20700
|
children
|
|
20703
20701
|
} = props;
|
|
20704
|
-
const className =
|
|
20702
|
+
const className = cn__default('border-grey-300 flex flex-row m-0 mb-4 print:hidden', 'aria-orientation-horizontal:border-b', 'aria-orientation-vertical:border-r aria-orientation-vertical:m-0 aria-orientation-vertical:mr-4 aria-orientation-vertical:flex-col', props.className);
|
|
20705
20703
|
return /*#__PURE__*/React.createElement(TabsPrimitive.List, Object.assign({}, props, {
|
|
20706
20704
|
className: className,
|
|
20707
20705
|
ref: ref
|
|
@@ -20724,13 +20722,13 @@ const TabTrigger = /*#__PURE__*/React.forwardRef(function Tab(props, ref) {
|
|
|
20724
20722
|
tooltip,
|
|
20725
20723
|
...otherProps
|
|
20726
20724
|
} = props;
|
|
20727
|
-
const triggerClassName =
|
|
20725
|
+
const triggerClassName = cn__default(props.className, 'group relative p-0.5 outline-none disabled:cursor-not-allowed disabled:text-black/50',
|
|
20728
20726
|
// horizontal
|
|
20729
20727
|
'[[aria-orientation="horizontal"]_&]:pb-1',
|
|
20730
20728
|
// horizontal
|
|
20731
20729
|
'[[aria-orientation="vertical"]_&]:pr-1');
|
|
20732
|
-
const buttonClassName =
|
|
20733
|
-
const activeClassName =
|
|
20730
|
+
const buttonClassName = cn__default(getButtonClasses(), 'group-focus-visible:yt-focus-inset group-enabled:group-hover:wcag-grey-200 pointer-events-none rounded px-3');
|
|
20731
|
+
const activeClassName = cn__default('pointer-events-none absolute hidden bg-blue-500 group-aria-selected:flex',
|
|
20734
20732
|
// horizontal
|
|
20735
20733
|
'[[aria-orientation="horizontal"]_&]:rounded-t-sm [[aria-orientation="horizontal"]_&]:bottom-0 [[aria-orientation="horizontal"]_&]:left-0 [[aria-orientation="horizontal"]_&]:right-0 [[aria-orientation="horizontal"]_&]:-mb-px [[aria-orientation="horizontal"]_&]:h-0.5',
|
|
20736
20734
|
// vertical
|
|
@@ -20757,7 +20755,7 @@ const TabContent = /*#__PURE__*/React.forwardRef(function Tab(props, ref) {
|
|
|
20757
20755
|
id,
|
|
20758
20756
|
...otherProps
|
|
20759
20757
|
} = props;
|
|
20760
|
-
const className =
|
|
20758
|
+
const className = cn__default('[&[data-orientation="vertical"]]:grow outline-none', props.className);
|
|
20761
20759
|
return /*#__PURE__*/React.createElement(TabsPrimitive.Content, Object.assign({}, otherProps, {
|
|
20762
20760
|
className: className,
|
|
20763
20761
|
ref: ref,
|
|
@@ -21061,7 +21059,7 @@ function Legend(props) {
|
|
|
21061
21059
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
21062
21060
|
className: "mx-auto w-auto max-w-full overflow-hidden"
|
|
21063
21061
|
}, /*#__PURE__*/React__default.createElement("div", {
|
|
21064
|
-
className:
|
|
21062
|
+
className: cn__default('mb-0 ml-0 flex justify-center', {
|
|
21065
21063
|
'flex-col': layout === 'vertical'
|
|
21066
21064
|
})
|
|
21067
21065
|
}, /*#__PURE__*/React__default.createElement(OverflowGroup, {
|
|
@@ -21069,7 +21067,7 @@ function Legend(props) {
|
|
|
21069
21067
|
moreButton: moreButton
|
|
21070
21068
|
}, payload.map((entry, index) => (/*#__PURE__*/React__default.createElement("span", {
|
|
21071
21069
|
key: `${entry.dataKey}-${index}`,
|
|
21072
|
-
className:
|
|
21070
|
+
className: cn__default(' hover:bg-grey-100 cursor-pointer px-[8px] py-[2px] hover:rounded-[4px]', {
|
|
21073
21071
|
'bg-grey-100 rounded': activeIndex === index
|
|
21074
21072
|
}),
|
|
21075
21073
|
onMouseEnter: () => handleMouseEnter(entry, index),
|
|
@@ -21078,7 +21076,7 @@ function Legend(props) {
|
|
|
21078
21076
|
}, /*#__PURE__*/React__default.createElement("span", {
|
|
21079
21077
|
className: "text-grey-700 flex items-center gap-[4px]"
|
|
21080
21078
|
}, /*#__PURE__*/React__default.createElement("span", {
|
|
21081
|
-
className:
|
|
21079
|
+
className: cn__default('-mt-px ml-1 flex h-3 w-3 rounded-sm', {
|
|
21082
21080
|
'border-grey-300 border !bg-white': !activeItems[entry.dataKey]
|
|
21083
21081
|
}),
|
|
21084
21082
|
style: {
|
|
@@ -21361,7 +21359,7 @@ const Legend$1 = ({
|
|
|
21361
21359
|
const isHovered = isTotal ? isTotalLegendHovered : hoveredItem.includes(itemData.id);
|
|
21362
21360
|
return /*#__PURE__*/React__default.createElement("li", {
|
|
21363
21361
|
key: isTotal ? 'total' : `${itemData.label}-${index}`,
|
|
21364
|
-
className:
|
|
21362
|
+
className: cn__default('mr-2 flex cursor-pointer gap-2 rounded pl-0 pr-1', {
|
|
21365
21363
|
'bg-grey-100': isHovered && (!isTotal || legendPosition === 'right'),
|
|
21366
21364
|
'bg-grey-200': isSelected && (!isTotal || legendPosition === 'right')
|
|
21367
21365
|
}),
|
|
@@ -21371,7 +21369,7 @@ const Legend$1 = ({
|
|
|
21371
21369
|
}, legendPosition === 'bottom' ? (/*#__PURE__*/React__default.createElement("div", {
|
|
21372
21370
|
className: "flex items-center gap-1"
|
|
21373
21371
|
}, /*#__PURE__*/React__default.createElement("span", {
|
|
21374
|
-
className:
|
|
21372
|
+
className: cn__default('ml-1 h-3 w-3 rounded-sm', {
|
|
21375
21373
|
'border-grey-300 border !bg-white': !visibleItems[itemData.id]
|
|
21376
21374
|
}),
|
|
21377
21375
|
style: {
|
|
@@ -21393,13 +21391,13 @@ const Legend$1 = ({
|
|
|
21393
21391
|
appearance: "transparent",
|
|
21394
21392
|
className: "text-grey-700"
|
|
21395
21393
|
}, moreButtonText));
|
|
21396
|
-
const className =
|
|
21394
|
+
const className = cn__default('flex-grow pl-4', {
|
|
21397
21395
|
'w-full': legendPosition === 'bottom'
|
|
21398
21396
|
});
|
|
21399
21397
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
21400
21398
|
className: className
|
|
21401
21399
|
}, /*#__PURE__*/React__default.createElement("ul", {
|
|
21402
|
-
className:
|
|
21400
|
+
className: cn__default('mb-0 ml-0 mt-4 flex justify-center space-y-1', legendPosition === 'right' ? 'flex-col gap-1' : 'flex-row')
|
|
21403
21401
|
}, legendPosition === 'right' ? (/*#__PURE__*/React__default.createElement(React__default.Fragment, null, renderLegendItem(null), data.map(renderLegendItem))) : (/*#__PURE__*/React__default.createElement(OverflowGroup, {
|
|
21404
21402
|
className: "w-full items-center py-1",
|
|
21405
21403
|
moreButton: moreButton
|
|
@@ -21447,7 +21445,7 @@ const ActiveShape = props => {
|
|
|
21447
21445
|
} = props;
|
|
21448
21446
|
return /*#__PURE__*/React__default.createElement("g", {
|
|
21449
21447
|
onClick: () => onClick(id),
|
|
21450
|
-
className:
|
|
21448
|
+
className: cn__default({
|
|
21451
21449
|
'cursor-pointer': !!onClick
|
|
21452
21450
|
})
|
|
21453
21451
|
}, /*#__PURE__*/React__default.createElement(Recharts.Sector, {
|
|
@@ -21573,7 +21571,7 @@ const DonutChart = function DonutChart({
|
|
|
21573
21571
|
}));
|
|
21574
21572
|
};
|
|
21575
21573
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
21576
|
-
className:
|
|
21574
|
+
className: cn__default('relative h-full w-full', {
|
|
21577
21575
|
[`flex `]: showLegend,
|
|
21578
21576
|
'flex-col items-center': legendPosition === 'bottom'
|
|
21579
21577
|
}),
|
|
@@ -21689,7 +21687,7 @@ const Button$4 = /*#__PURE__*/React__default.forwardRef(function Button(props, r
|
|
|
21689
21687
|
const {
|
|
21690
21688
|
...attributes
|
|
21691
21689
|
} = props;
|
|
21692
|
-
const className =
|
|
21690
|
+
const className = cn__default(getButtonClasses$1(), props.className);
|
|
21693
21691
|
return /*#__PURE__*/React__default.createElement(IconButton, Object.assign({}, attributes, {
|
|
21694
21692
|
appearance: "discrete",
|
|
21695
21693
|
className: className,
|
|
@@ -21697,7 +21695,7 @@ const Button$4 = /*#__PURE__*/React__default.forwardRef(function Button(props, r
|
|
|
21697
21695
|
ref: ref
|
|
21698
21696
|
}));
|
|
21699
21697
|
});
|
|
21700
|
-
const getButtonClasses$1 = (rounded = true) =>
|
|
21698
|
+
const getButtonClasses$1 = (rounded = true) => cn__default('!h-9 !w-9 flex-shrink-0 flex-grow-0 cursor-pointer relative', 'focus:!outline-none focus:!shadow-none focus-visible:!yt-focus-dark ', 'bg-transparent enabled:hover:bg-white/[.08] focus:bg-white/[.08] aria-current-page:bg-white/[.08]', 'text-white', {
|
|
21701
21699
|
'!rounded-full': rounded
|
|
21702
21700
|
});
|
|
21703
21701
|
|
|
@@ -21712,7 +21710,7 @@ const Link$2 = /*#__PURE__*/React__default.forwardRef(function Link(props, ref)
|
|
|
21712
21710
|
const {
|
|
21713
21711
|
texts
|
|
21714
21712
|
} = useLocalization();
|
|
21715
|
-
const className =
|
|
21713
|
+
const className = cn__default(getLinkClasses(icon), 'relative', props.className);
|
|
21716
21714
|
const link = /*#__PURE__*/React__default.createElement("a", Object.assign({}, otherProps, {
|
|
21717
21715
|
className: className,
|
|
21718
21716
|
"data-taco": "header-link",
|
|
@@ -21732,13 +21730,13 @@ const Link$2 = /*#__PURE__*/React__default.forwardRef(function Link(props, ref)
|
|
|
21732
21730
|
}
|
|
21733
21731
|
return link;
|
|
21734
21732
|
});
|
|
21735
|
-
const getLinkClasses = (icon = undefined) =>
|
|
21733
|
+
const getLinkClasses = (icon = undefined) => cn__default('flex h-8 flex-shrink-0 flex-grow-0 cursor-pointer items-center justify-center ', 'focus:!shadow-none focus:!outline-none focus-visible:!yt-focus-dark', 'bg-transparent hover:bg-white/[.08] focus:bg-white/[.08] aria-current-page:bg-white/[.08]', 'text-white hover:text-white focus:text-white', {
|
|
21736
21734
|
'!rounded-full !h-9 !w-9': icon,
|
|
21737
21735
|
'whitespace-nowrap px-3 rounded text-sm hidden lg:flex': !icon
|
|
21738
21736
|
});
|
|
21739
21737
|
|
|
21740
21738
|
const Logo = /*#__PURE__*/React__default.forwardRef(function Logo(props, ref) {
|
|
21741
|
-
const className =
|
|
21739
|
+
const className = cn__default('h-7 w-7 m-1 self-center justify-self-center flex-shrink-0 flex-grow-0', props.className);
|
|
21742
21740
|
return /*#__PURE__*/React__default.createElement("svg", Object.assign({}, props, {
|
|
21743
21741
|
className: className,
|
|
21744
21742
|
ref: ref,
|
|
@@ -21755,7 +21753,7 @@ const Logo = /*#__PURE__*/React__default.forwardRef(function Logo(props, ref) {
|
|
|
21755
21753
|
})));
|
|
21756
21754
|
});
|
|
21757
21755
|
const LogoLegacy = /*#__PURE__*/React__default.forwardRef(function Logo(props, ref) {
|
|
21758
|
-
const className =
|
|
21756
|
+
const className = cn__default('-mr-[156px] xs:-mr-14 md:!mr-0 h-9 shrink-0 w-[180px] px-1', props.className);
|
|
21759
21757
|
return /*#__PURE__*/React__default.createElement("svg", Object.assign({}, props, {
|
|
21760
21758
|
className: className,
|
|
21761
21759
|
ref: ref,
|
|
@@ -21827,9 +21825,9 @@ const PrimaryNavigation = /*#__PURE__*/React__default.forwardRef(function Primar
|
|
|
21827
21825
|
texts
|
|
21828
21826
|
} = useLocalization();
|
|
21829
21827
|
const internalRef = useMergedRef(ref);
|
|
21830
|
-
const className =
|
|
21828
|
+
const className = cn__default('flex h-full w-full flex-grow items-center overflow-hidden active:outline-none relative', props.className);
|
|
21831
21829
|
const moreButton = () => (/*#__PURE__*/React__default.createElement(Button$1, {
|
|
21832
|
-
className:
|
|
21830
|
+
className: cn__default(getLinkClasses(), '!bg-transparent aria-expanded:!bg-white/[.08]')
|
|
21833
21831
|
}, texts.header.more));
|
|
21834
21832
|
return /*#__PURE__*/React__default.createElement("nav", Object.assign({}, props, {
|
|
21835
21833
|
className: className,
|
|
@@ -21841,7 +21839,7 @@ const PrimaryNavigation = /*#__PURE__*/React__default.forwardRef(function Primar
|
|
|
21841
21839
|
});
|
|
21842
21840
|
|
|
21843
21841
|
const SecondaryNavigation = /*#__PURE__*/React__default.forwardRef(function SecondaryNavigation(props, ref) {
|
|
21844
|
-
const className =
|
|
21842
|
+
const className = cn__default('flex h-full items-center gap-2 mb-0 flex-shrink-0 mr-2', props.className);
|
|
21845
21843
|
return /*#__PURE__*/React__default.createElement("div", Object.assign({}, props, {
|
|
21846
21844
|
className: className,
|
|
21847
21845
|
ref: ref
|
|
@@ -21849,7 +21847,7 @@ const SecondaryNavigation = /*#__PURE__*/React__default.forwardRef(function Seco
|
|
|
21849
21847
|
});
|
|
21850
21848
|
|
|
21851
21849
|
const MenuButton = /*#__PURE__*/React__default.forwardRef(function MenuButton(props, ref) {
|
|
21852
|
-
const className =
|
|
21850
|
+
const className = cn__default(getButtonClasses$1(false), 'mr-1 !bg-transparent hover:!bg-white/[.08] focus:!bg-white/[.08]] lg:hidden z-[2] !text-white');
|
|
21853
21851
|
return /*#__PURE__*/React__default.createElement(IconButton, Object.assign({}, props, {
|
|
21854
21852
|
className: className,
|
|
21855
21853
|
"data-taco": "header-toggle-sidebar",
|
|
@@ -21869,7 +21867,7 @@ const AgreementAvatar = /*#__PURE__*/React__default.forwardRef(function Agreemen
|
|
|
21869
21867
|
const handleError = event => {
|
|
21870
21868
|
event.target.src = fallbackSrc;
|
|
21871
21869
|
};
|
|
21872
|
-
const className =
|
|
21870
|
+
const className = cn__default('h-9 w-9 rounded-full shrink-0 group-focus:yt-focus-dark xl:group-focus:shadow-none', {
|
|
21873
21871
|
visible: loaded
|
|
21874
21872
|
}, props.className);
|
|
21875
21873
|
return /*#__PURE__*/React__default.createElement("img", Object.assign({}, otherProps, {
|
|
@@ -21906,7 +21904,7 @@ const AgreementItem = props => {
|
|
|
21906
21904
|
fallbackImageSrc,
|
|
21907
21905
|
...agreement
|
|
21908
21906
|
} = props;
|
|
21909
|
-
const className =
|
|
21907
|
+
const className = cn__default('w-full rounded flex px-2 gap-2 overflow-hidden text-left items-center', customClassName);
|
|
21910
21908
|
return /*#__PURE__*/React__default.createElement("span", {
|
|
21911
21909
|
className: className
|
|
21912
21910
|
}, /*#__PURE__*/React__default.createElement(AgreementAvatar, {
|
|
@@ -21938,7 +21936,7 @@ const AgreementDisplay = props => {
|
|
|
21938
21936
|
} = props;
|
|
21939
21937
|
const isXlScreen = useMatchMedia('(min-width: 1280px)', window.innerWidth > 1280);
|
|
21940
21938
|
if (isXlScreen) {
|
|
21941
|
-
const className =
|
|
21939
|
+
const className = cn__default('h-12 flex-grow xl:[button>&]:hover:bg-white/[0.16]', props.className);
|
|
21942
21940
|
return /*#__PURE__*/React__default.createElement(AgreementItem, Object.assign({}, currentAgreement, {
|
|
21943
21941
|
children: children,
|
|
21944
21942
|
className: className,
|
|
@@ -22087,7 +22085,7 @@ function AgreementDisplay$1(props) {
|
|
|
22087
22085
|
}
|
|
22088
22086
|
|
|
22089
22087
|
const Header$6 = /*#__PURE__*/React__default.forwardRef(function Header(props, ref) {
|
|
22090
|
-
const className =
|
|
22088
|
+
const className = cn__default('bg-blue-900 flex h-16 w-full shrink-0 items-center gap-2 pl-4', '[&>*:focus-visible]:yt-focus-dark [&>*]:rounded',
|
|
22091
22089
|
// styles for logo wrapped inside an anchor
|
|
22092
22090
|
props.className);
|
|
22093
22091
|
return /*#__PURE__*/React__default.createElement("header", Object.assign({}, props, {
|
|
@@ -22111,7 +22109,7 @@ const LayoutContext = /*#__PURE__*/React__default.createContext({
|
|
|
22111
22109
|
});
|
|
22112
22110
|
|
|
22113
22111
|
const Content$9 = /*#__PURE__*/React__default.forwardRef(function LayoutContent(props, ref) {
|
|
22114
|
-
const className =
|
|
22112
|
+
const className = cn__default('flex-grow overflow-y-auto print:overflow-visible print:h-full print:!p-0 bg-white flex flex-shrink flex-col relative', props.className);
|
|
22115
22113
|
return /*#__PURE__*/React__default.createElement("main", Object.assign({}, props, {
|
|
22116
22114
|
className: className,
|
|
22117
22115
|
ref: ref
|
|
@@ -22153,7 +22151,7 @@ const Sidebar = /*#__PURE__*/React__default.forwardRef(function LayoutSidebar(pr
|
|
|
22153
22151
|
}, [isSmallScreen, sidebarOpen]);
|
|
22154
22152
|
const showBackdrop = isSmallScreen && sidebarOpen === true;
|
|
22155
22153
|
const [ready, setReady] = React__default.useState(isSmallScreen);
|
|
22156
|
-
const className =
|
|
22154
|
+
const className = cn__default('bg-grey-50 h-full w-64 flex-shrink-0 flex-grow-0 print:hidden', {
|
|
22157
22155
|
'absolute z-10 aria-hidden:-translate-x-64 ': isSmallScreen,
|
|
22158
22156
|
// prevent animation when crossing the boundary from large to small screen,
|
|
22159
22157
|
// this prevents awkward animation in the edge case (resizing the browser, instead of starting at a given size)
|
|
@@ -22207,7 +22205,7 @@ const Top = props => {
|
|
|
22207
22205
|
};
|
|
22208
22206
|
|
|
22209
22207
|
const Page = /*#__PURE__*/React__default.forwardRef(function LayoutPage(props, ref) {
|
|
22210
|
-
const className =
|
|
22208
|
+
const className = cn__default('flex flex-grow overflow-hidden print:overflow-visible print:h-full relative', props.className);
|
|
22211
22209
|
return /*#__PURE__*/React__default.createElement("div", Object.assign({}, props, {
|
|
22212
22210
|
className: className,
|
|
22213
22211
|
ref: ref
|
|
@@ -22216,7 +22214,7 @@ const Page = /*#__PURE__*/React__default.forwardRef(function LayoutPage(props, r
|
|
|
22216
22214
|
|
|
22217
22215
|
const Layout$1 = /*#__PURE__*/React__default.forwardRef(function Layout(props, ref) {
|
|
22218
22216
|
const [sidebarOpen, setSidebarOpen] = React__default.useState(false);
|
|
22219
|
-
const className =
|
|
22217
|
+
const className = cn__default('flex h-screen w-screen flex-col overflow-hidden print:overflow-visible print:h-full relative', props.className);
|
|
22220
22218
|
return /*#__PURE__*/React__default.createElement(LayoutContext.Provider, {
|
|
22221
22219
|
value: {
|
|
22222
22220
|
sidebarOpen,
|
|
@@ -22241,7 +22239,7 @@ const Group$6 = /*#__PURE__*/React__default.forwardRef(function Group(props, ref
|
|
|
22241
22239
|
...attributes
|
|
22242
22240
|
} = props;
|
|
22243
22241
|
const [expanded, setExpanded] = React__default.useState(defaultExpanded);
|
|
22244
|
-
const className =
|
|
22242
|
+
const className = cn__default('flex w-full cursor-pointer items-center rounded px-3 font-bold text-left leading-8 hover:bg-black/[.06] focus-visible:yt-focus-dark', attributes.className);
|
|
22245
22243
|
const handleClick = event => {
|
|
22246
22244
|
setExpanded(!expanded);
|
|
22247
22245
|
if (onClick) {
|
|
@@ -22265,14 +22263,14 @@ const Group$6 = /*#__PURE__*/React__default.forwardRef(function Group(props, ref
|
|
|
22265
22263
|
}), /*#__PURE__*/React__default.createElement("span", {
|
|
22266
22264
|
className: "flex-grow truncate"
|
|
22267
22265
|
}, heading)), /*#__PURE__*/React__default.createElement("ul", {
|
|
22268
|
-
className:
|
|
22266
|
+
className: cn__default('mb-0 flex flex-col gap-y-px pt-px', {
|
|
22269
22267
|
hidden: !expanded
|
|
22270
22268
|
}),
|
|
22271
22269
|
role: "menu"
|
|
22272
22270
|
}, children));
|
|
22273
22271
|
});
|
|
22274
22272
|
|
|
22275
|
-
const getAdjacentClasses = () =>
|
|
22273
|
+
const getAdjacentClasses = () => cn__default(
|
|
22276
22274
|
// styling if the element is proceeded by a link item
|
|
22277
22275
|
'[[role=menubar]>[data-taco=navigation2-link-item]+&]:mt-2', "[[role=menubar]>[data-taco='navigation2-link-item']+&]:border-t-2", "[[role=menubar]>[data-taco='navigation2-link-item']+&]:pt-2 ",
|
|
22278
22276
|
// styling if the element is proceeded by content
|
|
@@ -22280,7 +22278,7 @@ const getAdjacentClasses = () => cn(
|
|
|
22280
22278
|
// styling if the element is proceeded by a section
|
|
22281
22279
|
"[[role=menubar]>[data-taco='navigation2-section']+&]:border-t-2", "[[role=menubar]>[data-taco='navigation2-section']+&]:pt-2");
|
|
22282
22280
|
|
|
22283
|
-
const getNavigationLinkClasses = (isDraggedOver = false) =>
|
|
22281
|
+
const getNavigationLinkClasses = (isDraggedOver = false) => cn__default('group relative flex w-full items-center rounded leading-8 !text-black px-2 focus-visible:yt-focus-dark',
|
|
22284
22282
|
// override styles for links that are children of collapsible menus
|
|
22285
22283
|
'font-bold [[role=menu]>li>&]:font-normal [[role=menu]>li>&]:pl-5',
|
|
22286
22284
|
// override styles to adjust icons included in menu links
|
|
@@ -22301,8 +22299,8 @@ const Link$3 = /*#__PURE__*/React__default.forwardRef(function Link(props, ref)
|
|
|
22301
22299
|
...attributes
|
|
22302
22300
|
} = props;
|
|
22303
22301
|
const [isDraggedOver, dropTargetProps] = useDropTarget(onDrop);
|
|
22304
|
-
const className =
|
|
22305
|
-
const listClassName =
|
|
22302
|
+
const className = cn__default(getNavigationLinkClasses(isDraggedOver), attributes.className);
|
|
22303
|
+
const listClassName = cn__default('[[role=menubar]>&]:px-3 border-grey-200', getAdjacentClasses(), {
|
|
22306
22304
|
'[&>*]:pointer-events-none': isDraggedOver
|
|
22307
22305
|
});
|
|
22308
22306
|
return /*#__PURE__*/React__default.createElement("li", Object.assign({}, dropTargetProps, {
|
|
@@ -22326,7 +22324,7 @@ const Link$3 = /*#__PURE__*/React__default.forwardRef(function Link(props, ref)
|
|
|
22326
22324
|
icon: "more",
|
|
22327
22325
|
"aria-label": "More",
|
|
22328
22326
|
rounded: true,
|
|
22329
|
-
className:
|
|
22327
|
+
className: cn__default('-mr-1.5 hidden flex-shrink-0 flex-grow-0 transition-none group-hover:flex aria-expanded:flex', {
|
|
22330
22328
|
'absolute right-0 !mr-0.5': total !== undefined
|
|
22331
22329
|
}),
|
|
22332
22330
|
menu: menu,
|
|
@@ -22335,7 +22333,7 @@ const Link$3 = /*#__PURE__*/React__default.forwardRef(function Link(props, ref)
|
|
|
22335
22333
|
event.stopPropagation();
|
|
22336
22334
|
}
|
|
22337
22335
|
})) : null, total !== undefined ? (/*#__PURE__*/React__default.createElement(Badge, {
|
|
22338
|
-
className:
|
|
22336
|
+
className: cn__default('flex-shrink-0 flex-grow-0 !font-normal', {
|
|
22339
22337
|
'group-hover:hidden [[aria-expanded="true"]+&]:hidden ': menu
|
|
22340
22338
|
}),
|
|
22341
22339
|
color: "transparent"
|
|
@@ -22348,7 +22346,7 @@ const Section = /*#__PURE__*/React__default.forwardRef(function Navigation2(prop
|
|
|
22348
22346
|
heading,
|
|
22349
22347
|
...attributes
|
|
22350
22348
|
} = props;
|
|
22351
|
-
const className =
|
|
22349
|
+
const className = cn__default('w-full overflow-auto px-3 py-2 flex-grow border-grey-200 bg-grey-50 [[role=menubar]>&:first-child]:pt-0', getAdjacentClasses(), props.className);
|
|
22352
22350
|
return /*#__PURE__*/React__default.createElement("li", Object.assign({}, attributes, {
|
|
22353
22351
|
className: className,
|
|
22354
22352
|
"data-taco": "navigation2-section",
|
|
@@ -22366,7 +22364,7 @@ const Content$a = /*#__PURE__*/React__default.forwardRef(function Navigation2(pr
|
|
|
22366
22364
|
children,
|
|
22367
22365
|
...attributes
|
|
22368
22366
|
} = props;
|
|
22369
|
-
const className =
|
|
22367
|
+
const className = cn__default('w-full overflow-auto p-3 mt-auto border-grey-200 flex-shrink-0 z-10 bg-grey-50 [[role=menubar]>&:last-child]:pb-0', getAdjacentClasses(), props.className);
|
|
22370
22368
|
return /*#__PURE__*/React__default.createElement("li", Object.assign({}, attributes, {
|
|
22371
22369
|
className: className,
|
|
22372
22370
|
"data-taco": "navigation2-content",
|
|
@@ -22380,7 +22378,7 @@ const Navigation2 = /*#__PURE__*/React__default.forwardRef(function Navigation2(
|
|
|
22380
22378
|
children,
|
|
22381
22379
|
...attributes
|
|
22382
22380
|
} = props;
|
|
22383
|
-
const className =
|
|
22381
|
+
const className = cn__default('m-0 py-2 flex flex-col gap-y-px overflow-auto h-full w-full bg-grey-50', props.className);
|
|
22384
22382
|
return /*#__PURE__*/React__default.createElement("ul", Object.assign({}, attributes, {
|
|
22385
22383
|
className: className,
|
|
22386
22384
|
"data-taco": "navigation2",
|