@getgreenline/blaze-ui 1.0.34 → 1.0.35

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.
@@ -2,7 +2,7 @@ import { jsx } from 'react/jsx-runtime';
2
2
  import { cn } from '../lib/utils.js';
3
3
 
4
4
  function Input({ className, type, ...props }) {
5
- return (jsx("input", { type: type, "data-slot": "input", className: cn("tw:file:text-foreground tw:placeholder:text-muted-foreground tw:selection:bg-primary tw:selection:text-primary-foreground tw:dark:bg-input/30 tw:border-input tw:h-10 tw:w-full tw:min-w-0 tw:rounded-md tw:border tw:bg-transparent tw:px-3 tw:py-1 tw:text-base tw:shadow-xs tw:transition-[color,box-shadow] tw:outline-none tw:file:inline-flex tw:file:h-7 tw:file:border-0 tw:file:bg-transparent tw:file:text-sm tw:file:font-medium tw:disabled:pointer-events-none tw:disabled:cursor-not-allowed tw:disabled:opacity-50 tw:md:text-sm", "tw:focus-visible:border-ring tw:focus-visible:ring-ring/50 tw:focus-visible:ring-[3px]", "tw:aria-invalid:ring-destructive/20 tw:dark:aria-invalid:ring-destructive/40 tw:aria-invalid:border-destructive", className), ...props }));
5
+ return (jsx("input", { type: type, "data-slot": "input", className: cn("tw:file:text-foreground tw:placeholder:text-muted-foreground tw:selection:bg-primary tw:selection:text-primary-foreground tw:dark:bg-input/30 tw:border-border tw:h-10 tw:w-full tw:min-w-0 tw:rounded-md tw:border tw:bg-transparent tw:px-3 tw:py-1 tw:text-base tw:shadow-xs tw:transition-[color,box-shadow] tw:outline-none tw:file:inline-flex tw:file:h-7 tw:file:border-0 tw:file:bg-transparent tw:file:text-sm tw:file:font-medium tw:disabled:pointer-events-none tw:disabled:cursor-not-allowed tw:disabled:opacity-50 tw:md:text-sm", "tw:focus-visible:border-ring tw:focus-visible:ring-ring/50 tw:focus-visible:ring-[3px]", "tw:aria-invalid:ring-destructive/20 tw:dark:aria-invalid:ring-destructive/40 tw:aria-invalid:border-destructive", className), ...props }));
6
6
  }
7
7
 
8
8
  export { Input };
@@ -13,7 +13,7 @@ function SelectValue({ ...props }) {
13
13
  return jsx(SelectPrimitive.Value, { "data-slot": "select-value", ...props });
14
14
  }
15
15
  function SelectTrigger({ className, size = "default", children, ...props }) {
16
- return (jsxs(SelectPrimitive.Trigger, { "data-slot": "select-trigger", "data-size": size, className: cn("tw:!flex tw:!w-fit tw:!items-center tw:!justify-between tw:!gap-2 tw:!rounded-md tw:!border tw:!border-input tw:!bg-transparent tw:!px-3 tw:!py-2 tw:!text-[14px] tw:!whitespace-nowrap tw:!shadow-xs tw:!transition-[color,box-shadow] tw:!outline-none", "data-[placeholder]:tw:!text-muted-foreground [&_svg:not([class*='text-'])]:tw:!text-muted-foreground", "focus-visible:tw:!border-ring focus-visible:tw:!ring-ring/50 focus-visible:tw:!ring-[3px]", "aria-invalid:tw:!border-destructive aria-invalid:tw:!ring-destructive/20 dark:aria-invalid:tw:!ring-destructive/40", "dark:tw:!bg-input/30 dark:hover:tw:!bg-input/50", "disabled:tw:!cursor-not-allowed disabled:tw:!opacity-50", "data-[size=default]:tw:!h-9 data-[size=sm]:tw:!h-8", "*:data-[slot=select-value]:tw:!line-clamp-1 *:data-[slot=select-value]:tw:!flex *:data-[slot=select-value]:tw:!items-center *:data-[slot=select-value]:tw:!gap-2", "[&_svg]:tw:!pointer-events-none [&_svg]:tw:!shrink-0 [&_svg:not([class*='size-'])]:tw:!size-4", className), ...props, children: [children, jsx(SelectPrimitive.Icon, { asChild: true, children: jsx(ChevronDownIcon, { className: "tw:!size-4 tw:!opacity-50" }) })] }));
16
+ return (jsxs(SelectPrimitive.Trigger, { "data-slot": "select-trigger", "data-size": size, className: cn("tw:!flex tw:!w-fit tw:!items-center tw:!justify-between tw:!gap-2 tw:!rounded-md tw:!border tw:!border-border tw:!bg-transparent tw:!px-3 tw:!py-2 tw:!text-[14px] tw:!whitespace-nowrap tw:!shadow-xs tw:!transition-[color,box-shadow] tw:!outline-none", "data-[placeholder]:tw:!text-muted-foreground [&_svg:not([class*='text-'])]:tw:!text-muted-foreground", "focus-visible:tw:!border-ring focus-visible:tw:!ring-ring/50 focus-visible:tw:!ring-[3px]", "aria-invalid:tw:!border-destructive aria-invalid:tw:!ring-destructive/20 dark:aria-invalid:tw:!ring-destructive/40", "dark:tw:!bg-input/30 dark:hover:tw:!bg-input/50", "disabled:tw:!cursor-not-allowed disabled:tw:!opacity-50", "data-[size=default]:tw:!h-9 data-[size=sm]:tw:!h-8", "*:data-[slot=select-value]:tw:!line-clamp-1 *:data-[slot=select-value]:tw:!flex *:data-[slot=select-value]:tw:!items-center *:data-[slot=select-value]:tw:!gap-2", "[&_svg]:tw:!pointer-events-none [&_svg]:tw:!shrink-0 [&_svg:not([class*='size-'])]:tw:!size-4", className), ...props, children: [children, jsx(SelectPrimitive.Icon, { asChild: true, children: jsx(ChevronDownIcon, { className: "tw:!size-4 tw:!opacity-50" }) })] }));
17
17
  }
18
18
  function SelectContent({ className, children, position = "popper", ...props }) {
19
19
  return (jsx(SelectPrimitive.Portal, { children: jsxs(SelectPrimitive.Content, { "data-slot": "select-content", className: cn("tw:!relative tw:!z-50 tw:!min-w-[8rem] tw:!max-h-(--radix-select-content-available-height) tw:!origin-(--radix-select-content-transform-origin) tw:!overflow-x-hidden tw:!overflow-y-auto tw:!rounded-md tw:!border tw:!bg-popover tw:!text-popover-foreground tw:!shadow-md", "data-[state=open]:tw:!animate-in data-[state=closed]:tw:!animate-out data-[state=closed]:tw:!fade-out-0 data-[state=open]:tw:!fade-in-0 data-[state=closed]:tw:!zoom-out-95 data-[state=open]:tw:!zoom-in-95", "data-[side=bottom]:tw:!slide-in-from-top-2 data-[side=left]:tw:!slide-in-from-right-2 data-[side=right]:tw:!slide-in-from-left-2 data-[side=top]:tw:!slide-in-from-bottom-2", position === "popper" &&
@@ -1 +1 @@
1
- {"version":3,"file":"separator.d.ts","sourceRoot":"","sources":["../../src/components/separator.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,kBAAkB,MAAM,2BAA2B,CAAA;AAI/D,iBAAS,SAAS,CAAC,EACjB,SAAS,EACT,WAA0B,EAC1B,UAAiB,EACjB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,kBAAkB,CAAC,IAAI,CAAC,2CAatD;AAED,OAAO,EAAE,SAAS,EAAE,CAAA"}
1
+ {"version":3,"file":"separator.d.ts","sourceRoot":"","sources":["../../src/components/separator.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,kBAAkB,MAAM,2BAA2B,CAAA;AAI/D,iBAAS,SAAS,CAAC,EACjB,SAAS,EACT,WAA0B,EAC1B,UAAiB,EACjB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,kBAAkB,CAAC,IAAI,CAAC,2CAgBtD;AAED,OAAO,EAAE,SAAS,EAAE,CAAA"}
@@ -3,7 +3,9 @@ import * as SeparatorPrimitive from '@radix-ui/react-separator';
3
3
  import { cn } from '../lib/utils.js';
4
4
 
5
5
  function Separator({ className, orientation = "horizontal", decorative = true, ...props }) {
6
- return (jsx(SeparatorPrimitive.Root, { "data-slot": "separator", decorative: decorative, orientation: orientation, className: cn("tw:bg-border tw:shrink-0 data-[orientation=horizontal]:tw:h-px data-[orientation=horizontal]:tw:w-full data-[orientation=vertical]:tw:h-full data-[orientation=vertical]:tw:w-px", className), ...props }));
6
+ return (jsx(SeparatorPrimitive.Root, { "data-slot": "separator", decorative: decorative, orientation: orientation, className: cn("tw:bg-border tw:shrink-0", orientation === "horizontal"
7
+ ? "tw:h-px tw:w-full"
8
+ : "tw:h-full tw:w-px", className), ...props }));
7
9
  }
8
10
 
9
11
  export { Separator };
@@ -1,5 +1,5 @@
1
1
  import * as React from "react";
2
2
  import * as SliderPrimitive from "@radix-ui/react-slider";
3
- declare function Slider({ className, defaultValue, value, min, max, ...props }: React.ComponentProps<typeof SliderPrimitive.Root>): import("react/jsx-runtime").JSX.Element;
3
+ declare function Slider({ className, defaultValue, value, min, max, orientation, ...props }: React.ComponentProps<typeof SliderPrimitive.Root>): import("react/jsx-runtime").JSX.Element;
4
4
  export { Slider };
5
5
  //# sourceMappingURL=slider.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"slider.d.ts","sourceRoot":"","sources":["../../src/components/slider.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,eAAe,MAAM,wBAAwB,CAAA;AAIzD,iBAAS,MAAM,CAAC,EACd,SAAS,EACT,YAAY,EACZ,KAAK,EACL,GAAO,EACP,GAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,eAAe,CAAC,IAAI,CAAC,2CA8CnD;AAED,OAAO,EAAE,MAAM,EAAE,CAAA"}
1
+ {"version":3,"file":"slider.d.ts","sourceRoot":"","sources":["../../src/components/slider.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,eAAe,MAAM,wBAAwB,CAAA;AAIzD,iBAAS,MAAM,CAAC,EACd,SAAS,EACT,YAAY,EACZ,KAAK,EACL,GAAO,EACP,GAAS,EACT,WAA0B,EAC1B,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,eAAe,CAAC,IAAI,CAAC,2CAsDnD;AAED,OAAO,EAAE,MAAM,EAAE,CAAA"}
@@ -3,13 +3,17 @@ import * as React from 'react';
3
3
  import * as SliderPrimitive from '@radix-ui/react-slider';
4
4
  import { cn } from '../lib/utils.js';
5
5
 
6
- function Slider({ className, defaultValue, value, min = 0, max = 100, ...props }) {
6
+ function Slider({ className, defaultValue, value, min = 0, max = 100, orientation = "horizontal", ...props }) {
7
7
  const _values = React.useMemo(() => Array.isArray(value)
8
8
  ? value
9
9
  : Array.isArray(defaultValue)
10
10
  ? defaultValue
11
11
  : [min, max], [value, defaultValue, min, max]);
12
- return (jsxs(SliderPrimitive.Root, { "data-slot": "slider", defaultValue: defaultValue, value: value, min: min, max: max, className: cn("tw:relative tw:flex tw:w-full tw:touch-none tw:items-center tw:select-none data-[disabled]:tw:opacity-50 data-[orientation=vertical]:tw:h-full data-[orientation=vertical]:tw:min-h-44 data-[orientation=vertical]:tw:w-auto data-[orientation=vertical]:tw:flex-col", className), ...props, children: [jsx(SliderPrimitive.Track, { "data-slot": "slider-track", className: cn("tw:bg-muted tw:relative tw:grow tw:overflow-hidden tw:rounded-full data-[orientation=horizontal]:tw:h-1.5 data-[orientation=horizontal]:tw:w-full data-[orientation=vertical]:tw:h-full data-[orientation=vertical]:tw:w-1.5"), children: jsx(SliderPrimitive.Range, { "data-slot": "slider-range", className: cn("tw:bg-primary tw:absolute data-[orientation=horizontal]:tw:h-full data-[orientation=vertical]:tw:w-full") }) }), Array.from({ length: _values.length }, (_, index) => (jsx(SliderPrimitive.Thumb, { "data-slot": "slider-thumb", className: "tw:border-primary tw:ring-ring/50 tw:block tw:size-4 tw:shrink-0 tw:rounded-full tw:border tw:bg-white tw:shadow-sm tw:transition-[color,box-shadow] hover:tw:ring-4 focus-visible:tw:ring-4 focus-visible:tw:outline-hidden disabled:tw:pointer-events-none disabled:tw:opacity-50" }, index)))] }));
12
+ return (jsxs(SliderPrimitive.Root, { "data-slot": "slider", defaultValue: defaultValue, value: value, min: min, max: max, orientation: orientation, className: cn("tw:relative tw:flex tw:w-full tw:touch-none tw:select-none data-[disabled]:tw:opacity-50", orientation === "horizontal"
13
+ ? "tw:items-center"
14
+ : "tw:h-full tw:w-auto tw:min-h-44 tw:flex-col", className), ...props, children: [jsx(SliderPrimitive.Track, { "data-slot": "slider-track", className: cn("tw:bg-muted tw:relative tw:grow tw:overflow-hidden tw:rounded-full", orientation === "horizontal"
15
+ ? "tw:h-1.5 tw:w-full"
16
+ : "tw:h-full tw:w-1.5"), children: jsx(SliderPrimitive.Range, { "data-slot": "slider-range", className: cn("tw:bg-primary tw:absolute", orientation === "horizontal" ? "tw:h-full" : "tw:w-full") }) }), Array.from({ length: _values.length }, (_, index) => (jsx(SliderPrimitive.Thumb, { "data-slot": "slider-thumb", className: "tw:border-primary tw:ring-ring/50 tw:block tw:size-4 tw:shrink-0 tw:rounded-full tw:border tw:bg-white tw:shadow-sm tw:transition-[color,box-shadow] hover:tw:ring-4 focus-visible:tw:ring-4 focus-visible:tw:outline-hidden disabled:tw:pointer-events-none disabled:tw:opacity-50" }, index)))] }));
13
17
  }
14
18
 
15
19
  export { Slider };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@getgreenline/blaze-ui",
3
- "version": "1.0.34",
3
+ "version": "1.0.35",
4
4
  "type": "module",
5
5
  "dependencies": {
6
6
  "@base-ui/react": "^1.1.0",