@exem-ui/react 0.3.4-next.20260609002221 → 0.3.4-next.20260609004311

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/index.js CHANGED
@@ -1,12 +1,11 @@
1
1
  'use strict';
2
2
 
3
- var chunk3OTGQNHL_js = require('./chunk-3OTGQNHL.js');
3
+ var chunkKCOTDUDN_js = require('./chunk-KCOTDUDN.js');
4
4
  var chunkTAZFRRWT_js = require('./chunk-TAZFRRWT.js');
5
5
  var utils = require('@exem-ui/core/utils');
6
6
  var React = require('react');
7
7
  var jsxRuntime = require('react/jsx-runtime');
8
8
  var reactSlot = require('@radix-ui/react-slot');
9
- var TabsPrimitive = require('@radix-ui/react-tabs');
10
9
  var CheckboxPrimitive = require('@radix-ui/react-checkbox');
11
10
  var RadioGroupPrimitive = require('@radix-ui/react-radio-group');
12
11
  var SwitchPrimitives = require('@radix-ui/react-switch');
@@ -35,7 +34,6 @@ function _interopNamespace(e) {
35
34
  }
36
35
 
37
36
  var React__namespace = /*#__PURE__*/_interopNamespace(React);
38
- var TabsPrimitive__namespace = /*#__PURE__*/_interopNamespace(TabsPrimitive);
39
37
  var CheckboxPrimitive__namespace = /*#__PURE__*/_interopNamespace(CheckboxPrimitive);
40
38
  var RadioGroupPrimitive__namespace = /*#__PURE__*/_interopNamespace(RadioGroupPrimitive);
41
39
  var SwitchPrimitives__namespace = /*#__PURE__*/_interopNamespace(SwitchPrimitives);
@@ -427,91 +425,6 @@ Breadcrumb.Page.displayName = "Breadcrumb.Page";
427
425
  Breadcrumb.Path.displayName = "Breadcrumb.Path";
428
426
  Breadcrumb.Separator.displayName = "Breadcrumb.Separator";
429
427
  Breadcrumb.Ellipsis.displayName = "Breadcrumb.Ellipsis";
430
- var TabsContext = React.createContext({ type: "primary" });
431
- var useTabsContext = () => {
432
- const context = React.useContext(TabsContext);
433
- if (!context) {
434
- throw new Error("useTabsContext must be used within a TabsProvider");
435
- }
436
- return context;
437
- };
438
- var tabsListVariants = utils.cva("inline-flex items-center", {
439
- variants: {
440
- type: {
441
- primary: "h-9 gap-5 border-b border-border-primary",
442
- secondary: "h-8 gap-1"
443
- }
444
- },
445
- defaultVariants: {
446
- type: "primary"
447
- }
448
- });
449
- var tabsTriggerVariants = utils.cva(
450
- "group inline-flex items-center justify-center gap-1.5 whitespace-nowrap font-pretendard font-semibold text-body-2 leading-[140%] transition-all disabled:pointer-events-none disabled:opacity-50",
451
- {
452
- variants: {
453
- type: {
454
- primary: [
455
- "h-9 border-b-2 border-transparent p-0 text-text-tertiary",
456
- "hover:text-text-primary",
457
- "data-[state=active]:border-border-focused data-[state=active]:text-text-primary"
458
- ],
459
- secondary: [
460
- "h-8 rounded-strong px-2 text-text-tertiary",
461
- "hover:text-text-primary",
462
- "data-[state=active]:rounded-medium data-[state=active]:bg-elevation-elevation-2 data-[state=active]:text-text-primary"
463
- ]
464
- }
465
- },
466
- defaultVariants: {
467
- type: "primary"
468
- }
469
- }
470
- );
471
- var Tabs = React.forwardRef(
472
- ({ type = "primary", children, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(TabsContext.Provider, { value: { type }, children: /* @__PURE__ */ jsxRuntime.jsx(TabsPrimitive__namespace.Root, { ref, ...props, children }) })
473
- );
474
- Tabs.List = React.forwardRef(
475
- ({ className, ...props }, ref) => {
476
- const { type } = useTabsContext();
477
- return /* @__PURE__ */ jsxRuntime.jsx(
478
- TabsPrimitive__namespace.List,
479
- {
480
- ref,
481
- className: utils.cn(tabsListVariants({ type }), className),
482
- ...props
483
- }
484
- );
485
- }
486
- );
487
- Tabs.Trigger = React.forwardRef(
488
- ({ className, leftIcon, rightIcon, badge, children, ...props }, ref) => {
489
- const { type } = useTabsContext();
490
- return /* @__PURE__ */ jsxRuntime.jsxs(
491
- TabsPrimitive__namespace.Trigger,
492
- {
493
- ref,
494
- className: utils.cn(tabsTriggerVariants({ type }), className),
495
- ...props,
496
- children: [
497
- leftIcon && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "size-4", children: leftIcon }),
498
- /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "flex items-center gap-1", children: [
499
- children,
500
- badge && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-text-tertiary group-data-[state=active]:text-text-accent", children: badge })
501
- ] }),
502
- rightIcon && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "size-4", children: rightIcon })
503
- ]
504
- }
505
- );
506
- }
507
- );
508
- Tabs.Content = React.forwardRef(
509
- ({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(TabsPrimitive__namespace.Content, { ref, className: utils.cn(className), ...props })
510
- );
511
- Tabs.displayName = "Tabs";
512
- Tabs.List.displayName = "Tabs.List";
513
- Tabs.Trigger.displayName = "Tabs.Trigger";
514
- Tabs.Content.displayName = "Tabs.Content";
515
428
  var colorStyles = {
516
429
  accent: {
517
430
  contained: {
@@ -752,7 +665,7 @@ var IconButton = React.forwardRef(
752
665
  variant,
753
666
  ...props
754
667
  };
755
- return /* @__PURE__ */ jsxRuntime.jsx(chunk3OTGQNHL_js.ConditionalTooltip, { tooltip, children: /* @__PURE__ */ jsxRuntime.jsx(Button, { ref, ...buttonProps }) });
668
+ return /* @__PURE__ */ jsxRuntime.jsx(chunkKCOTDUDN_js.ConditionalTooltip, { tooltip, children: /* @__PURE__ */ jsxRuntime.jsx(Button, { ref, ...buttonProps }) });
756
669
  }
757
670
  );
758
671
  IconButton.displayName = "IconButton";
@@ -796,7 +709,7 @@ var ButtonGroup = React.forwardRef(
796
709
  onClick: item.onClick,
797
710
  size
798
711
  };
799
- return /* @__PURE__ */ jsxRuntime.jsx(chunk3OTGQNHL_js.ConditionalTooltip, { tooltip: item.tooltip, children: variant === "contained" ? /* @__PURE__ */ jsxRuntime.jsx(IconButton, { ...iconBaseProps, color: "assistive", variant: "contained" }) : /* @__PURE__ */ jsxRuntime.jsx(IconButton, { ...iconBaseProps, color: "primary", variant: "outlined" }) }, item.id);
712
+ return /* @__PURE__ */ jsxRuntime.jsx(chunkKCOTDUDN_js.ConditionalTooltip, { tooltip: item.tooltip, children: variant === "contained" ? /* @__PURE__ */ jsxRuntime.jsx(IconButton, { ...iconBaseProps, color: "assistive", variant: "contained" }) : /* @__PURE__ */ jsxRuntime.jsx(IconButton, { ...iconBaseProps, color: "primary", variant: "outlined" }) }, item.id);
800
713
  }
801
714
  const buttonBaseProps = {
802
715
  className: utils.cn(roundedClasses, dividerClasses, mergeClasses, hoverClasses),
@@ -804,7 +717,7 @@ var ButtonGroup = React.forwardRef(
804
717
  onClick: item.onClick,
805
718
  size
806
719
  };
807
- return /* @__PURE__ */ jsxRuntime.jsx(chunk3OTGQNHL_js.ConditionalTooltip, { tooltip: item.tooltip, children: variant === "contained" ? /* @__PURE__ */ jsxRuntime.jsx(Button, { ...buttonBaseProps, color: "assistive", variant: "contained", children: item.label }) : /* @__PURE__ */ jsxRuntime.jsx(Button, { ...buttonBaseProps, color: "primary", variant: "outlined", children: item.label }) }, item.id);
720
+ return /* @__PURE__ */ jsxRuntime.jsx(chunkKCOTDUDN_js.ConditionalTooltip, { tooltip: item.tooltip, children: variant === "contained" ? /* @__PURE__ */ jsxRuntime.jsx(Button, { ...buttonBaseProps, color: "assistive", variant: "contained", children: item.label }) : /* @__PURE__ */ jsxRuntime.jsx(Button, { ...buttonBaseProps, color: "primary", variant: "outlined", children: item.label }) }, item.id);
808
721
  })
809
722
  }
810
723
  );
@@ -1215,12 +1128,12 @@ function DatePicker({ type = "single", showOutsideDays = true, ...rest }) {
1215
1128
  }
1216
1129
  var dropdownVariants = {
1217
1130
  content: utils.cn(
1218
- chunk3OTGQNHL_js.overlayListVariants.content,
1131
+ chunkKCOTDUDN_js.overlayListVariants.content,
1219
1132
  "data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2"
1220
1133
  ),
1221
- viewport: chunk3OTGQNHL_js.overlayListVariants.viewport,
1222
- item: (props) => utils.cn(chunk3OTGQNHL_js.overlayListVariants.item(props), "focus:bg-elevation-elevation-2"),
1223
- slotSize: chunk3OTGQNHL_js.overlayListVariants.slotSize,
1134
+ viewport: chunkKCOTDUDN_js.overlayListVariants.viewport,
1135
+ item: (props) => utils.cn(chunkKCOTDUDN_js.overlayListVariants.item(props), "focus:bg-elevation-elevation-2"),
1136
+ slotSize: chunkKCOTDUDN_js.overlayListVariants.slotSize,
1224
1137
  separator: utils.cn("my-0.5 h-px bg-border-primary"),
1225
1138
  label: utils.cva("px-2 font-medium text-text-secondary", {
1226
1139
  defaultVariants: { size: "medium" },
@@ -1271,9 +1184,9 @@ Dropdown.Item = React.forwardRef(({ className, children, leftSlot, rightSlot, si
1271
1184
  className: utils.cn(dropdownVariants.item({ size }), className),
1272
1185
  ...props,
1273
1186
  children: [
1274
- leftSlot && /* @__PURE__ */ jsxRuntime.jsx("div", { className: chunk3OTGQNHL_js.overlayListVariants.slotSize({ size }), children: leftSlot }),
1275
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: utils.cn(chunk3OTGQNHL_js.overlayListVariants.itemText({ size }), "min-w-0 flex-1 truncate"), children }),
1276
- rightSlot && /* @__PURE__ */ jsxRuntime.jsx("div", { className: chunk3OTGQNHL_js.overlayListVariants.slotSize({ size }), children: rightSlot })
1187
+ leftSlot && /* @__PURE__ */ jsxRuntime.jsx("div", { className: chunkKCOTDUDN_js.overlayListVariants.slotSize({ size }), children: leftSlot }),
1188
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: utils.cn(chunkKCOTDUDN_js.overlayListVariants.itemText({ size }), "min-w-0 flex-1 truncate"), children }),
1189
+ rightSlot && /* @__PURE__ */ jsxRuntime.jsx("div", { className: chunkKCOTDUDN_js.overlayListVariants.slotSize({ size }), children: rightSlot })
1277
1190
  ]
1278
1191
  }
1279
1192
  );
@@ -1318,8 +1231,8 @@ var useTextAreaContext = () => {
1318
1231
  return context;
1319
1232
  };
1320
1233
  var textAreaVariants = {
1321
- container: chunk3OTGQNHL_js.commonInputVariants.container,
1322
- label: chunk3OTGQNHL_js.commonInputVariants.label,
1234
+ container: chunkKCOTDUDN_js.commonInputVariants.container,
1235
+ label: chunkKCOTDUDN_js.commonInputVariants.label,
1323
1236
  field: utils.cva(
1324
1237
  "scrollbar-overlay block w-full resize-none rounded-medium border transition-colors focus:outline-none",
1325
1238
  {
@@ -1367,7 +1280,7 @@ var textAreaVariants = {
1367
1280
  },
1368
1281
  defaultVariants: { size: "medium" }
1369
1282
  }),
1370
- description: chunk3OTGQNHL_js.commonInputVariants.description,
1283
+ description: chunkKCOTDUDN_js.commonInputVariants.description,
1371
1284
  counter: utils.cva("text-nowrap font-regular", {
1372
1285
  variants: {
1373
1286
  disabled: {
@@ -1487,8 +1400,8 @@ var useTextFieldContext = () => {
1487
1400
  return context;
1488
1401
  };
1489
1402
  var textFieldVariants = {
1490
- container: chunk3OTGQNHL_js.commonInputVariants.container,
1491
- label: chunk3OTGQNHL_js.commonInputVariants.label,
1403
+ container: chunkKCOTDUDN_js.commonInputVariants.container,
1404
+ label: chunkKCOTDUDN_js.commonInputVariants.label,
1492
1405
  wrapper: utils.cva(
1493
1406
  "flex w-full flex-row items-center rounded-medium border transition-colors focus-within:border-border-focused focus-within:outline-none",
1494
1407
  {
@@ -2553,15 +2466,19 @@ var buttonize = (fn) => {
2553
2466
 
2554
2467
  Object.defineProperty(exports, "Segment", {
2555
2468
  enumerable: true,
2556
- get: function () { return chunk3OTGQNHL_js.Segment; }
2469
+ get: function () { return chunkKCOTDUDN_js.Segment; }
2557
2470
  });
2558
2471
  Object.defineProperty(exports, "Select", {
2559
2472
  enumerable: true,
2560
- get: function () { return chunk3OTGQNHL_js.Select; }
2473
+ get: function () { return chunkKCOTDUDN_js.Select; }
2474
+ });
2475
+ Object.defineProperty(exports, "Tabs", {
2476
+ enumerable: true,
2477
+ get: function () { return chunkKCOTDUDN_js.Tabs; }
2561
2478
  });
2562
2479
  Object.defineProperty(exports, "Tooltip", {
2563
2480
  enumerable: true,
2564
- get: function () { return chunk3OTGQNHL_js.Tooltip; }
2481
+ get: function () { return chunkKCOTDUDN_js.Tooltip; }
2565
2482
  });
2566
2483
  exports.Avatar = Avatar;
2567
2484
  exports.Badge = Badge;
@@ -2582,7 +2499,6 @@ exports.ScrollArea = ScrollArea;
2582
2499
  exports.ScrollBar = ScrollBar;
2583
2500
  exports.Star = Star;
2584
2501
  exports.Switch = Switch;
2585
- exports.Tabs = Tabs;
2586
2502
  exports.Tag = Tag;
2587
2503
  exports.TextArea = TextArea;
2588
2504
  exports.TextField = TextField;