@luxfi/ui 8.2.11 → 8.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. package/dist/3d-carousel.d.ts +2 -1
  2. package/dist/3d-carousel.d.ts.map +1 -1
  3. package/dist/3d-marquee.cjs +635 -607
  4. package/dist/3d-marquee.js +635 -607
  5. package/dist/animated-background.cjs +643 -615
  6. package/dist/animated-background.js +643 -615
  7. package/dist/animated-beam.cjs +634 -606
  8. package/dist/animated-beam.js +634 -606
  9. package/dist/animated-icon.cjs +672 -625
  10. package/dist/animated-icon.js +672 -625
  11. package/dist/animated-list.cjs +794 -663
  12. package/dist/animated-list.js +794 -663
  13. package/dist/animated-number.cjs +644 -616
  14. package/dist/animated-number.js +644 -616
  15. package/dist/animated-testimonials.cjs +668 -621
  16. package/dist/animated-testimonials.js +668 -621
  17. package/dist/animated-text.cjs +675 -628
  18. package/dist/animated-text.js +675 -628
  19. package/dist/animated-tooltip.cjs +668 -621
  20. package/dist/animated-tooltip.js +668 -621
  21. package/dist/apple-cards-carousel.cjs +676 -629
  22. package/dist/apple-cards-carousel.js +676 -629
  23. package/dist/apple-hello-effect.cjs +634 -606
  24. package/dist/apple-hello-effect.js +634 -606
  25. package/dist/calendar.cjs +2 -37
  26. package/dist/calendar.d.ts +11 -1
  27. package/dist/calendar.d.ts.map +1 -1
  28. package/dist/calendar.js +3 -38
  29. package/dist/dock.cjs +645 -617
  30. package/dist/dock.js +645 -617
  31. package/dist/image-zoom.d.ts +3 -2
  32. package/dist/image-zoom.d.ts.map +1 -1
  33. package/dist/input-otp.d.ts +4 -2
  34. package/dist/input-otp.d.ts.map +1 -1
  35. package/dist/pulse-animation.cjs +636 -608
  36. package/dist/pulse-animation.js +636 -608
  37. package/dist/resizable.cjs +4 -24
  38. package/dist/resizable.d.ts +12 -12
  39. package/dist/resizable.d.ts.map +1 -1
  40. package/dist/resizable.js +4 -4
  41. package/dist/reveal-animation.cjs +639 -611
  42. package/dist/reveal-animation.js +639 -611
  43. package/package.json +43 -41
  44. package/src/3d-carousel.tsx +2 -2
  45. package/src/calendar.tsx +12 -43
  46. package/src/image-zoom.tsx +2 -2
  47. package/src/resizable.tsx +7 -7
  48. package/src/table.tsx +9 -9
  49. package/tokens.css +21 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@luxfi/ui",
3
- "version": "8.2.11",
3
+ "version": "8.3.0",
4
4
  "description": "Cross-platform UI components on @hanzo/gui. Native mobile + web.",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -52,8 +52,10 @@
52
52
  "require": "./dist/vite.cjs"
53
53
  },
54
54
  "./provider": {
55
- "import": "./src/provider.tsx",
56
- "types": "./src/provider.tsx"
55
+ "types": "./dist/provider.d.ts",
56
+ "import": "./dist/provider.js",
57
+ "require": "./dist/provider.cjs",
58
+ "default": "./dist/provider.js"
57
59
  },
58
60
  "./utils": {
59
61
  "types": "./dist/utils.d.ts",
@@ -1025,52 +1027,52 @@
1025
1027
  "dependencies": {
1026
1028
  "@dnd-kit/core": "^6.3.1",
1027
1029
  "@dnd-kit/sortable": "^10.0.0",
1028
- "@hanzo/commerce": "7.7.5",
1029
- "@hanzo/ui": "8.25.2",
1030
- "@hanzogui/config": "^8.1.1",
1031
- "@hookform/resolvers": "5.2.2",
1030
+ "@hanzo/commerce": "7.8.0",
1031
+ "@hanzo/ui": "8.26.0",
1032
+ "@hanzogui/config": "8.3.1",
1033
+ "@hookform/resolvers": "^5.9.1",
1032
1034
  "@luxfi/logo": "1.0.10",
1033
1035
  "@luxfi/menu-icons": "1.0.2",
1034
1036
  "@monaco-editor/react": "^4.7.0",
1035
- "@next/third-parties": "^16.2.1",
1037
+ "@next/third-parties": "^16.3.3",
1036
1038
  "@uidotdev/usehooks": "^2.4.1",
1037
- "date-fns": "^4.1.0",
1038
- "embla-carousel-autoplay": "8.6.0",
1039
- "es-toolkit": "^1.31.0",
1040
- "input-otp": "^1.4.2",
1041
- "lucide-react": "^1.27.0",
1039
+ "date-fns": "^4.4.0",
1040
+ "embla-carousel-autoplay": "^8.6.0",
1041
+ "es-toolkit": "^1.52.0",
1042
+ "input-otp": "^1.5.0",
1043
+ "lucide-react": "^1.37.0",
1042
1044
  "markdown-to-jsx": "^9.10.2",
1043
1045
  "mobx": "^7.0.3",
1044
1046
  "mobx-react-lite": "^5.0.3",
1045
1047
  "next": "16.3.3",
1046
- "next-themes": "0.4.6",
1048
+ "next-themes": "^0.4.6",
1047
1049
  "qrcode.react": "^4.2.0",
1048
- "react-colorful": "^5.6.1",
1049
- "react-day-picker": "^9.14.0",
1050
+ "react-colorful": "^5.8.0",
1051
+ "react-day-picker": "^10.0.1",
1050
1052
  "react-device-detect": "^2.2.3",
1051
- "react-dropzone": "^15.0.0",
1052
- "react-hook-form": "^7.72.0",
1053
+ "react-dropzone": "^20.1.1",
1054
+ "react-hook-form": "^7.86.0",
1053
1055
  "react-social-icons": "^6.26.0",
1054
1056
  "react-tooltip": "^6.0.8",
1055
1057
  "recharts": "^3.10.1",
1056
- "shiki": "^4.0.2",
1057
- "sonner": "^2.0.7",
1058
+ "shiki": "^4.4.3",
1059
+ "sonner": "^2.0.8",
1058
1060
  "usehooks-ts": "^3.1.1",
1059
1061
  "validator": "^13.15.35",
1060
- "zod": "^4.5.1",
1062
+ "zod": "^4.5.2",
1061
1063
  "@hanzo/iam": "0.21.17"
1062
1064
  },
1063
1065
  "peerDependencies": {
1064
1066
  "@hanzo/appearance": ">=0.2.2",
1065
1067
  "@hanzo/design": ">=0.5.24",
1066
- "@hanzo/gui": ">=8.3.0",
1067
- "@hanzo/ui": ">=8.25.2",
1068
- "@hanzogui/colors": "^8.1.1",
1069
- "@hanzogui/core": "^8.1.1",
1070
- "@hanzogui/lucide-icons-2": "^8.1.1",
1071
- "@hanzogui/themes": "^8.1.1",
1072
- "@hanzogui/web": "^8.1.1",
1073
- "@tanstack/react-query": "^5.76.0",
1068
+ "@hanzo/gui": "8.3.1",
1069
+ "@hanzo/ui": ">=8.26.0",
1070
+ "@hanzogui/colors": "8.3.1",
1071
+ "@hanzogui/core": "8.3.1",
1072
+ "@hanzogui/lucide-icons-2": "8.3.1",
1073
+ "@hanzogui/themes": "8.3.1",
1074
+ "@hanzogui/web": "8.3.1",
1075
+ "@tanstack/react-query": ">=5",
1074
1076
  "react": ">=19.2.8",
1075
1077
  "react-dom": ">=19.2.8"
1076
1078
  },
@@ -1097,25 +1099,25 @@
1097
1099
  "devDependencies": {
1098
1100
  "@hanzo/appearance": "0.2.2",
1099
1101
  "@hanzo/design": "0.5.24",
1100
- "@hanzo/gui": "8.3.0",
1102
+ "@hanzo/gui": "8.3.1",
1101
1103
  "@hanzo/iam": "0.21.17",
1102
- "@hanzo/ui": "8.25.2",
1103
- "@hanzogui/colors": "8.1.1",
1104
- "@hanzogui/config": "8.1.1",
1105
- "@hanzogui/core": "8.1.1",
1106
- "@hanzogui/themes": "8.1.1",
1107
- "@hanzogui/web": "8.1.1",
1108
- "@playwright/test": "^1.58",
1104
+ "@hanzo/ui": "8.26.0",
1105
+ "@hanzogui/colors": "8.3.1",
1106
+ "@hanzogui/config": "8.3.1",
1107
+ "@hanzogui/core": "8.3.1",
1108
+ "@hanzogui/themes": "8.3.1",
1109
+ "@hanzogui/web": "8.3.1",
1110
+ "@playwright/test": "^1.62.1",
1109
1111
  "@types/node": "26.4.0",
1110
1112
  "@types/react": "19.2.18",
1111
1113
  "@types/react-dom": "19.2.5",
1112
- "@vitejs/plugin-react": "^6",
1114
+ "@vitejs/plugin-react": "^6.1.1",
1113
1115
  "react": "19.2.8",
1114
1116
  "react-dom": "19.2.8",
1115
- "react-native-web": "^0.21.0",
1116
- "tsup": "^8.5.0",
1117
+ "react-native-web": "^0.21.2",
1118
+ "tsup": "^8.5.1",
1117
1119
  "typescript": "7.0.2",
1118
- "vite": "^8"
1120
+ "vite": "^8.2.2"
1119
1121
  },
1120
1122
  "scripts": {
1121
1123
  "build": "tsup --no-dts && tsc -p tsconfig.json --noEmit false --emitDeclarationOnly --declaration --outDir dist",
@@ -1,7 +1,7 @@
1
1
  "use client"
2
2
 
3
3
  import * as React from "react"
4
- import { Box, css } from '@hanzo/ui'
4
+ import { Box, css, type BoxProps } from '@hanzo/ui'
5
5
  import { ChevronLeft, ChevronRight } from "lucide-react"
6
6
 
7
7
  import { cn } from "./utils"
@@ -375,7 +375,7 @@ Carousel3DCard.displayName = "Carousel3DCard"
375
375
 
376
376
  const Carousel3DCardImage = React.forwardRef<
377
377
  HTMLImageElement,
378
- React.ImgHTMLAttributes<HTMLImageElement>
378
+ BoxProps<'img'>
379
379
  >(({ className, alt, ...props }, ref) => (
380
380
  <Box tag="img"
381
381
  ref={ref}
package/src/calendar.tsx CHANGED
@@ -1,58 +1,27 @@
1
1
  "use client"
2
2
 
3
3
  import * as React from "react"
4
- import { ChevronLeft, ChevronRight } from "lucide-react"
5
4
  import { DayPicker } from "react-day-picker"
6
5
 
7
6
  import { cn } from "./utils"
8
- import { buttonVariants } from "@hanzo/ui"
9
7
 
10
8
  export type CalendarProps = React.ComponentProps<typeof DayPicker>
11
9
 
12
- function Calendar({
13
- className,
14
- classNames,
15
- showOutsideDays = true,
16
- ...props
17
- }: CalendarProps) {
10
+ /**
11
+ * The month grid, styled by `.lux-calendar` in tokens.css.
12
+ *
13
+ * react-day-picker names every part it renders — `rdp-day`, `rdp-selected`,
14
+ * `rdp-outside` — so the rules go on those, and the component stays the one
15
+ * line it should be. Restating them here as a `classNames` table means keeping
16
+ * a copy of somebody else's element names, which is how this drifted: the table
17
+ * still spelled the v8 names after v9 renamed them, so the styling was gone and
18
+ * only the type error said so.
19
+ */
20
+ function Calendar({ className, showOutsideDays = true, ...props }: CalendarProps) {
18
21
  return (
19
22
  <DayPicker
20
23
  showOutsideDays={showOutsideDays}
21
- className={cn("p-3", className)}
22
- classNames={{
23
- months: "flex flex-col sm:flex-row space-y-4 sm:space-x-4 sm:space-y-0",
24
- month: "space-y-4",
25
- caption: "flex justify-center pt-1 relative items-center",
26
- caption_label: "text-sm font-medium",
27
- nav: "space-x-1 flex items-center",
28
- nav_button: cn(
29
- buttonVariants({ variant: "outline" }),
30
- "h-7 w-7 bg-transparent p-0 opacity-50 hover:opacity-100"
31
- ),
32
- nav_button_previous: "absolute left-1",
33
- nav_button_next: "absolute right-1",
34
- table: "w-full border-collapse space-y-1",
35
- head_row: "flex",
36
- head_cell:
37
- "text-muted-foreground rounded-md w-9 font-normal text-[0.8rem]",
38
- row: "flex w-full mt-2",
39
- cell: "h-9 w-9 text-center text-sm p-0 relative [&:has([aria-selected].day-range-end)]:rounded-r-md [&:has([aria-selected].day-outside)]:bg-accent/50 [&:has([aria-selected])]:bg-accent first:[&:has([aria-selected])]:rounded-l-md last:[&:has([aria-selected])]:rounded-r-md focus-within:relative focus-within:z-20",
40
- day: cn(
41
- buttonVariants({ variant: "ghost" }),
42
- "h-9 w-9 p-0 font-normal aria-selected:opacity-100"
43
- ),
44
- day_range_end: "day-range-end",
45
- day_selected:
46
- "bg-primary text-primary-foreground hover:bg-primary hover:text-primary-foreground focus:bg-primary focus:text-primary-foreground",
47
- day_today: "bg-accent text-accent-foreground",
48
- day_outside:
49
- "day-outside text-muted-foreground opacity-50 aria-selected:bg-accent/50 aria-selected:text-muted-foreground aria-selected:opacity-30",
50
- day_disabled: "text-muted-foreground opacity-50",
51
- day_range_middle:
52
- "aria-selected:bg-accent aria-selected:text-accent-foreground",
53
- day_hidden: "invisible",
54
- ...classNames,
55
- }}
24
+ className={cn('lux-calendar', className)}
56
25
  {...props}
57
26
  />
58
27
  )
@@ -1,13 +1,13 @@
1
1
  "use client"
2
2
 
3
3
  import * as React from "react"
4
- import { Box, css } from '@hanzo/ui'
4
+ import { Box, css, type BoxProps } from '@hanzo/ui'
5
5
  import { ZoomIn } from "lucide-react"
6
6
 
7
7
  import { cn } from "./utils"
8
8
 
9
9
  export interface ImageZoomProps
10
- extends React.ImgHTMLAttributes<HTMLImageElement> {
10
+ extends BoxProps<'img'> {
11
11
  zoomScale?: number
12
12
  }
13
13
 
package/src/resizable.tsx CHANGED
@@ -2,15 +2,15 @@
2
2
 
3
3
  import { GripVertical } from "lucide-react"
4
4
  import { Box, css } from '@hanzo/ui'
5
- import * as ResizablePrimitive from "react-resizable-panels"
5
+ import { Panel, PanelGroup, PanelResizeHandle } from "react-resizable-panels"
6
6
 
7
7
  import { cn } from "./utils"
8
8
 
9
9
  const ResizablePanelGroup = ({
10
10
  className,
11
11
  ...props
12
- }: React.ComponentProps<typeof ResizablePrimitive.PanelGroup>) => (
13
- <ResizablePrimitive.PanelGroup
12
+ }: React.ComponentProps<typeof PanelGroup>) => (
13
+ <PanelGroup
14
14
  className={cn(
15
15
  "flex h-full w-full data-[panel-group-direction=vertical]:flex-col",
16
16
  className
@@ -19,16 +19,16 @@ const ResizablePanelGroup = ({
19
19
  />
20
20
  )
21
21
 
22
- const ResizablePanel = ResizablePrimitive.Panel
22
+ const ResizablePanel = Panel
23
23
 
24
24
  const ResizableHandle = ({
25
25
  withHandle,
26
26
  className,
27
27
  ...props
28
- }: React.ComponentProps<typeof ResizablePrimitive.PanelResizeHandle> & {
28
+ }: React.ComponentProps<typeof PanelResizeHandle> & {
29
29
  withHandle?: boolean
30
30
  }) => (
31
- <ResizablePrimitive.PanelResizeHandle
31
+ <PanelResizeHandle
32
32
  className={cn(
33
33
  "relative flex w-px items-center justify-center bg-border after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring focus-visible:ring-offset-1 data-[panel-group-direction=vertical]:h-px data-[panel-group-direction=vertical]:w-full data-[panel-group-direction=vertical]:after:left-0 data-[panel-group-direction=vertical]:after:h-1 data-[panel-group-direction=vertical]:after:w-full data-[panel-group-direction=vertical]:after:-translate-y-1/2 data-[panel-group-direction=vertical]:after:translate-x-0 [&[data-panel-group-direction=vertical]>div]:rotate-90",
34
34
  className
@@ -40,7 +40,7 @@ const ResizableHandle = ({
40
40
  <GripVertical style={css('h-2.5 w-2.5')} />
41
41
  </Box>
42
42
  )}
43
- </ResizablePrimitive.PanelResizeHandle>
43
+ </PanelResizeHandle>
44
44
  )
45
45
 
46
46
  export { ResizablePanelGroup, ResizablePanel, ResizableHandle }
package/src/table.tsx CHANGED
@@ -1,6 +1,6 @@
1
1
  'use client'
2
2
  import { throttle } from 'es-toolkit';
3
- import { Box, css, sx } from '@hanzo/ui'
3
+ import { Box, css, sx, type BoxProps } from '@hanzo/ui'
4
4
  import * as React from 'react';
5
5
 
6
6
  import { cn } from './utils';
@@ -295,7 +295,7 @@ export const TableRoot = React.forwardRef<HTMLTableElement, TableRootProps>(
295
295
  ref={ ref }
296
296
  className={ cn('w-full border-collapse text-sm', className) }
297
297
  style={ merged }
298
- { ...(rest as React.HTMLAttributes<HTMLTableElement>) }
298
+ { ...(rest as BoxProps<'table'>) }
299
299
  >
300
300
  { children }
301
301
  </Box>
@@ -322,7 +322,7 @@ export const TableHeader = React.forwardRef<HTMLTableSectionElement, TableHeader
322
322
  ref={ ref }
323
323
  className={ cn('', className) }
324
324
  style={ merged }
325
- { ...(rest as React.HTMLAttributes<HTMLTableSectionElement>) }
325
+ { ...(rest as BoxProps<'thead'>) }
326
326
  >
327
327
  { children }
328
328
  </Box>
@@ -349,7 +349,7 @@ export const TableBody = React.forwardRef<HTMLTableSectionElement, TableBodyProp
349
349
  ref={ ref }
350
350
  className={ cn('', className) }
351
351
  style={ merged }
352
- { ...(rest as React.HTMLAttributes<HTMLTableSectionElement>) }
352
+ { ...(rest as BoxProps<'tbody'>) }
353
353
  >
354
354
  { children }
355
355
  </Box>
@@ -376,7 +376,7 @@ export const TableRow = React.forwardRef<HTMLTableRowElement, TableRowProps>(
376
376
  ref={ ref }
377
377
  className={ cn('', className) }
378
378
  style={ merged }
379
- { ...(rest as React.HTMLAttributes<HTMLTableRowElement>) }
379
+ { ...(rest as BoxProps<'tr'>) }
380
380
  >
381
381
  { children }
382
382
  </Box>
@@ -410,7 +410,7 @@ export const TableCell = React.forwardRef<HTMLTableCellElement, TableCellProps>(
410
410
  ref={ ref }
411
411
  className={ cn('px-3 py-2.5 align-top text-sm', className) }
412
412
  style={ merged }
413
- { ...(rest as React.TdHTMLAttributes<HTMLTableCellElement>) }
413
+ { ...(rest as BoxProps<'td'>) }
414
414
  >
415
415
  { children }
416
416
  </Box>
@@ -446,7 +446,7 @@ export const TableColumnHeader = React.forwardRef<HTMLTableCellElement, TableCol
446
446
  className,
447
447
  ) }
448
448
  style={ merged }
449
- { ...(rest as React.ThHTMLAttributes<HTMLTableCellElement>) }
449
+ { ...(rest as BoxProps<'th'>) }
450
450
  >
451
451
  { children }
452
452
  </Box>
@@ -563,7 +563,7 @@ export const TableCaption = React.forwardRef<HTMLTableCaptionElement, TableCapti
563
563
  ref={ ref }
564
564
  className={ cn('px-3 py-2 text-sm text-[var(--color-table-header-fg)]', className) }
565
565
  style={ merged }
566
- { ...(rest as React.HTMLAttributes<HTMLTableCaptionElement>) }
566
+ { ...(rest as BoxProps<'caption'>) }
567
567
  >
568
568
  { children }
569
569
  </Box>
@@ -590,7 +590,7 @@ export const TableFooter = React.forwardRef<HTMLTableSectionElement, TableFooter
590
590
  ref={ ref }
591
591
  className={ cn('', className) }
592
592
  style={ merged }
593
- { ...(rest as React.HTMLAttributes<HTMLTableSectionElement>) }
593
+ { ...(rest as BoxProps<'tfoot'>) }
594
594
  >
595
595
  { children }
596
596
  </Box>
package/tokens.css CHANGED
@@ -1048,3 +1048,24 @@
1048
1048
  motion; the bar itself stays, so "work in flight" is still visible. */
1049
1049
  .lux-loading::after { animation: none; width: 100%; opacity: 0.5 }
1050
1050
  }
1051
+
1052
+ /* The month grid. react-day-picker names its own parts; these style them. */
1053
+ .lux-calendar {
1054
+ padding: .75rem;
1055
+ --rdp-cell-size: 2.25rem;
1056
+ --rdp-accent-color: var(--primary);
1057
+ --rdp-accent-background-color: var(--accent);
1058
+ }
1059
+ .lux-calendar .rdp-month_caption { font-size: .875rem; font-weight: 500 }
1060
+ .lux-calendar .rdp-weekday { color: var(--muted-foreground); font-weight: 400; font-size: .8rem }
1061
+ .lux-calendar .rdp-day_button {
1062
+ width: var(--rdp-cell-size);
1063
+ height: var(--rdp-cell-size);
1064
+ border-radius: var(--radius, .5rem);
1065
+ }
1066
+ .lux-calendar .rdp-day_button:hover { background: var(--accent); color: var(--accent-foreground) }
1067
+ .lux-calendar .rdp-selected .rdp-day_button { background: var(--primary); color: var(--primary-foreground) }
1068
+ .lux-calendar .rdp-today:not(.rdp-selected) .rdp-day_button { background: var(--accent); color: var(--accent-foreground) }
1069
+ .lux-calendar .rdp-outside { color: var(--muted-foreground); opacity: .5 }
1070
+ .lux-calendar .rdp-disabled { color: var(--muted-foreground); opacity: .5 }
1071
+ .lux-calendar .rdp-hidden { visibility: hidden }