@sikka/hawa 0.12.9-next → 0.12.10-next

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.css CHANGED
@@ -1153,6 +1153,9 @@ input[type="number"]::-webkit-inner-spin-button,
1153
1153
  .hawa-h-\[44px\] {
1154
1154
  height: 44px;
1155
1155
  }
1156
+ .hawa-h-\[calc\(60vh\)\] {
1157
+ height: calc(60vh);
1158
+ }
1156
1159
  .hawa-h-\[var\(--radix-navigation-menu-viewport-height\)\] {
1157
1160
  height: var(--radix-navigation-menu-viewport-height);
1158
1161
  }
@@ -2561,6 +2564,14 @@ input[type="number"]::-webkit-inner-spin-button,
2561
2564
  .hawa-ring-offset-background {
2562
2565
  --tw-ring-offset-color: hsl(var(--background));
2563
2566
  }
2567
+ .hawa-drop-shadow-2xl {
2568
+ --tw-drop-shadow: drop-shadow(0 25px 25px rgb(0 0 0 / 0.15));
2569
+ filter: var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow);
2570
+ }
2571
+ .hawa-drop-shadow-xl {
2572
+ --tw-drop-shadow: drop-shadow(0 20px 13px rgb(0 0 0 / 0.03)) drop-shadow(0 8px 5px rgb(0 0 0 / 0.08));
2573
+ filter: var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow);
2574
+ }
2564
2575
  .hawa-backdrop-blur-sm {
2565
2576
  --tw-backdrop-blur: blur(4px);
2566
2577
  -webkit-backdrop-filter: var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);
package/dist/index.js CHANGED
@@ -1554,7 +1554,7 @@ var SplitButton = function(_param) /* @__PURE__ */ {
1554
1554
  onClick: function() {
1555
1555
  return console.log("btn clicked");
1556
1556
  },
1557
- className: direction === "rtl" ? "hawa-rounded-l-none" : "hawa-rounded-r-none"
1557
+ className: cn(direction === "rtl" ? "hawa-rounded-r-none" : "hawa-rounded-l-none", props.className)
1558
1558
  }, children), /* @__PURE__ */ React11.createElement(DropdownMenu, {
1559
1559
  size: "sm",
1560
1560
  width: "sm",
@@ -1564,7 +1564,7 @@ var SplitButton = function(_param) /* @__PURE__ */ {
1564
1564
  asChild: true,
1565
1565
  variant: variant,
1566
1566
  size: "icon",
1567
- className: cn("hawa-h-10 hawa-w-fit hawa-px-1", direction === "rtl" ? "hawa-rounded-r-none hawa-border-r-0" : "hawa-border-l-0 hawa-rounded-l-none")
1567
+ className: cn("hawa-h-10 hawa-w-fit hawa-px-1", direction === "rtl" ? "hawa-rounded-l-none hawa-border-rl0" : "hawa-border-r-0 hawa-rounded-r-none", props.className)
1568
1568
  }, /* @__PURE__ */ React11.createElement("svg", {
1569
1569
  xmlns: "http://www.w3.org/2000/svg",
1570
1570
  width: "18",
@@ -2620,7 +2620,7 @@ var Slider = React28.forwardRef(function(_param, ref) /* @__PURE__ */ {
2620
2620
  ref: ref,
2621
2621
  className: cn("hawa-relative hawa-flex hawa-w-full hawa-touch-none hawa-select-none hawa-items-center", className)
2622
2622
  }, props), /* @__PURE__ */ React28.createElement(SliderPrimitive.Track, {
2623
- className: "hawa-relative hawa-h-2 hawa-w-full hawa-grow hawa-overflow-hidden hawa-rounded-full hawa-bg-secondary"
2623
+ className: "hawa-relative hawa-h-2 hawa-w-full hawa-grow hawa-overflow-hidden hawa-rounded-full hawa-bg-background hawa-border"
2624
2624
  }, /* @__PURE__ */ React28.createElement(SliderPrimitive.Range, {
2625
2625
  className: "hawa-absolute hawa-h-full hawa-bg-primary"
2626
2626
  })), /* @__PURE__ */ React28.createElement(SliderPrimitive.Thumb, {
@@ -6635,10 +6635,10 @@ var SidebarItem = function(_param) {
6635
6635
  if (item.subitems) {
6636
6636
  return /* @__PURE__ */ React57.createElement(AccordionItem2, {
6637
6637
  value: item.value,
6638
- className: "hawa-overflow-x-clip ",
6638
+ className: "hawa-overflow-x-clip",
6639
6639
  dir: direction
6640
6640
  }, /* @__PURE__ */ React57.createElement(AccordionTrigger2, {
6641
- className: cn("hawa-overflow-x-clip hawa-w-full", props.selectedItem === item.value ? "hawa-cursor-default hawa-bg-primary hawa-text-primary-foreground" : "hover:hawa-bg-primary/10", item.subitems && item.subitems.some(function(subitem) {
6641
+ className: cn("hawa-overflow-x-clip hawa-w-full", props.selectedItem === item.value ? "hawa-cursor-default hawa-bg-primary hawa-text-primary-foreground" : "hover:hawa-bg-primary/10 hawa-h-10", item.subitems && item.subitems.some(function(subitem) {
6642
6642
  return props.selectedItem === subitem.value;
6643
6643
  }) ? "hawa-bg-primary/90 hawa-text-primary-foreground hover:hawa-bg-primary/90" : ""),
6644
6644
  showArrow: isOpen
@@ -6665,7 +6665,7 @@ var SidebarItem = function(_param) {
6665
6665
  ]);
6666
6666
  }
6667
6667
  },
6668
- className: cn("hawa-flex hawa-h-full hawa-cursor-pointer hawa-flex-row hawa-items-center hawa-gap-2 hawa-rounded hawa-p-2 hawa-transition-all", // bg-foreground/10
6668
+ className: cn("hawa-flex hawa-h-full hawa-cursor-pointer hawa-flex-row hawa-items-center hawa-gap-2 hawa-rounded hawa-p-2 hawa-transition-all hawa-overflow-x-clip hawa-whitespace-nowrap", // bg-foreground/10
6669
6669
  getSelectedStyle(subitem.value))
6670
6670
  }, subitem.icon && subitem.icon, subitem.label);
6671
6671
  }))));
@@ -6702,14 +6702,13 @@ var useBreakpoint = function() {
6702
6702
  setBreakpoint((_window = window) === null || _window === void 0 ? void 0 : _window.innerWidth);
6703
6703
  };
6704
6704
  (0, import_react33.useEffect)(function() {
6705
- if (typeof window !== "undefined") {
6705
+ var _window;
6706
+ if (typeof window == "undefined") return;
6707
+ (_window = window) === null || _window === void 0 ? void 0 : _window.addEventListener("resize", resize);
6708
+ return function() {
6706
6709
  var _window;
6707
- (_window = window) === null || _window === void 0 ? void 0 : _window.addEventListener("resize", resize);
6708
- return function() {
6709
- var _window;
6710
- (_window = window) === null || _window === void 0 ? void 0 : _window.removeEventListener("resize", resize);
6711
- };
6712
- }
6710
+ (_window = window) === null || _window === void 0 ? void 0 : _window.removeEventListener("resize", resize);
6711
+ };
6713
6712
  }, []);
6714
6713
  return breakpoint;
6715
6714
  };
package/dist/index.mjs CHANGED
@@ -899,7 +899,10 @@ var SplitButton = ({
899
899
  {
900
900
  variant,
901
901
  onClick: () => console.log("btn clicked"),
902
- className: direction === "rtl" ? "hawa-rounded-l-none" : "hawa-rounded-r-none"
902
+ className: cn(
903
+ direction === "rtl" ? "hawa-rounded-r-none" : "hawa-rounded-l-none",
904
+ props.className
905
+ )
903
906
  },
904
907
  children
905
908
  ),
@@ -918,7 +921,8 @@ var SplitButton = ({
918
921
  size: "icon",
919
922
  className: cn(
920
923
  "hawa-h-10 hawa-w-fit hawa-px-1",
921
- direction === "rtl" ? "hawa-rounded-r-none hawa-border-r-0" : "hawa-border-l-0 hawa-rounded-l-none"
924
+ direction === "rtl" ? "hawa-rounded-l-none hawa-border-rl0" : "hawa-border-r-0 hawa-rounded-r-none",
925
+ props.className
922
926
  )
923
927
  },
924
928
  /* @__PURE__ */ React11.createElement(
@@ -2166,7 +2170,7 @@ var Slider = React28.forwardRef(({ className, ...props }, ref) => /* @__PURE__ *
2166
2170
  ),
2167
2171
  ...props
2168
2172
  },
2169
- /* @__PURE__ */ React28.createElement(SliderPrimitive.Track, { className: "hawa-relative hawa-h-2 hawa-w-full hawa-grow hawa-overflow-hidden hawa-rounded-full hawa-bg-secondary" }, /* @__PURE__ */ React28.createElement(SliderPrimitive.Range, { className: "hawa-absolute hawa-h-full hawa-bg-primary" })),
2173
+ /* @__PURE__ */ React28.createElement(SliderPrimitive.Track, { className: "hawa-relative hawa-h-2 hawa-w-full hawa-grow hawa-overflow-hidden hawa-rounded-full hawa-bg-background hawa-border" }, /* @__PURE__ */ React28.createElement(SliderPrimitive.Range, { className: "hawa-absolute hawa-h-full hawa-bg-primary" })),
2170
2174
  /* @__PURE__ */ React28.createElement(SliderPrimitive.Thumb, { className: "hawa-block hawa-h-5 hawa-w-5 hawa-rounded-full hawa-border-2 hawa-border-primary hawa-bg-background hawa-ring-offset-background hawa-transition-colors focus-visible:hawa-outline-none focus-visible:hawa-ring-2 focus-visible:hawa-ring-ring focus-visible:hawa-ring-offset-2 disabled:hawa-pointer-events-none disabled:hawa-opacity-50" })
2171
2175
  ));
2172
2176
  Slider.displayName = SliderPrimitive.Root.displayName;
@@ -6417,7 +6421,7 @@ var SidebarItem = ({
6417
6421
  AccordionItem2,
6418
6422
  {
6419
6423
  value: item.value,
6420
- className: "hawa-overflow-x-clip ",
6424
+ className: "hawa-overflow-x-clip",
6421
6425
  dir: direction
6422
6426
  },
6423
6427
  /* @__PURE__ */ React57.createElement(
@@ -6425,7 +6429,7 @@ var SidebarItem = ({
6425
6429
  {
6426
6430
  className: cn(
6427
6431
  "hawa-overflow-x-clip hawa-w-full",
6428
- props.selectedItem === item.value ? "hawa-cursor-default hawa-bg-primary hawa-text-primary-foreground" : "hover:hawa-bg-primary/10",
6432
+ props.selectedItem === item.value ? "hawa-cursor-default hawa-bg-primary hawa-text-primary-foreground" : "hover:hawa-bg-primary/10 hawa-h-10",
6429
6433
  item.subitems && item.subitems.some(
6430
6434
  (subitem) => props.selectedItem === subitem.value
6431
6435
  ) ? "hawa-bg-primary/90 hawa-text-primary-foreground hover:hawa-bg-primary/90" : ""
@@ -6474,7 +6478,7 @@ var SidebarItem = ({
6474
6478
  }
6475
6479
  },
6476
6480
  className: cn(
6477
- "hawa-flex hawa-h-full hawa-cursor-pointer hawa-flex-row hawa-items-center hawa-gap-2 hawa-rounded hawa-p-2 hawa-transition-all",
6481
+ "hawa-flex hawa-h-full hawa-cursor-pointer hawa-flex-row hawa-items-center hawa-gap-2 hawa-rounded hawa-p-2 hawa-transition-all hawa-overflow-x-clip hawa-whitespace-nowrap",
6478
6482
  // bg-foreground/10
6479
6483
  getSelectedStyle(subitem.value)
6480
6484
  )
@@ -6528,12 +6532,12 @@ var useBreakpoint = () => {
6528
6532
  setBreakpoint(window?.innerWidth);
6529
6533
  };
6530
6534
  useEffect14(() => {
6531
- if (typeof window !== "undefined") {
6532
- window?.addEventListener("resize", resize);
6533
- return () => {
6534
- window?.removeEventListener("resize", resize);
6535
- };
6536
- }
6535
+ if (typeof window == "undefined")
6536
+ return;
6537
+ window?.addEventListener("resize", resize);
6538
+ return () => {
6539
+ window?.removeEventListener("resize", resize);
6540
+ };
6537
6541
  }, []);
6538
6542
  return breakpoint;
6539
6543
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sikka/hawa",
3
- "version": "0.12.9-next",
3
+ "version": "0.12.10-next",
4
4
  "main": "./dist/index.js",
5
5
  "types": "./dist/index.d.ts",
6
6
  "exports": {
@@ -22,7 +22,8 @@
22
22
  "build-lib": "tsup components/index.tsx --format cjs,esm --dts",
23
23
  "build-css": "postcss styles/globals.css -o dist/index.css",
24
24
  "prepub": "npm run build-lib && npm run build-css",
25
- "pub": "npm publish --tag next"
25
+ "pub": "npm publish --tag next",
26
+ "chromatic": "npx chromatic --project-token=chpt_9c33d11ef14064f --output-dir ./storybook-static"
26
27
  },
27
28
  "dependencies": {
28
29
  "@hookform/resolvers": "^3.3.2",