@rise-x/apps-sdk 0.6.0 → 0.8.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 (93) hide show
  1. package/README.md +192 -10
  2. package/build/connectors/agents.js +1 -1
  3. package/build/connectors/assets.d.ts +9 -3
  4. package/build/connectors/assets.js +32 -1
  5. package/build/connectors/index.d.ts +3 -2
  6. package/build/connectors/index.js +4 -1
  7. package/build/connectors/search.d.ts +34 -0
  8. package/build/connectors/search.js +63 -0
  9. package/build/connectors/types.d.ts +51 -0
  10. package/build/connectors/types.js +71 -0
  11. package/build/connectors/work.d.ts +7 -1
  12. package/build/connectors/work.js +13 -0
  13. package/build/index.d.ts +1 -1
  14. package/build/mockShell.d.ts +11 -0
  15. package/build/mockShell.js +159 -2
  16. package/build/query/assets.d.ts +19 -6
  17. package/build/query/assets.js +35 -3
  18. package/build/query/context.d.ts +14 -0
  19. package/build/query/context.js +16 -0
  20. package/build/query/index.d.ts +4 -3
  21. package/build/query/index.js +14 -2
  22. package/build/query/keys.d.ts +4 -0
  23. package/build/query/keys.js +7 -0
  24. package/build/query/layer.d.ts +25 -3
  25. package/build/query/work.d.ts +14 -1
  26. package/build/query/work.js +32 -1
  27. package/build/shellBridge.d.ts +1 -1
  28. package/build/ui/components/accordion.d.ts +7 -0
  29. package/build/ui/components/aspect-ratio.d.ts +4 -0
  30. package/build/ui/components/button-group.d.ts +7 -0
  31. package/build/ui/components/carousel.d.ts +18 -0
  32. package/build/ui/components/chart.d.ts +45 -94
  33. package/build/ui/components/collapsible.d.ts +6 -0
  34. package/build/ui/components/combobox.d.ts +19 -0
  35. package/build/ui/components/command.d.ts +18 -0
  36. package/build/ui/components/context-menu.d.ts +29 -0
  37. package/build/ui/components/data-table.d.ts +13 -2
  38. package/build/ui/components/date-picker.d.ts +16 -0
  39. package/build/ui/components/direction.d.ts +6 -0
  40. package/build/ui/components/field.d.ts +25 -0
  41. package/build/ui/components/hover-card.d.ts +6 -0
  42. package/build/ui/components/input-group.d.ts +13 -0
  43. package/build/ui/components/input-otp.d.ts +34 -0
  44. package/build/ui/components/input.d.ts +1 -3
  45. package/build/ui/components/item.d.ts +23 -0
  46. package/build/ui/components/kbd.d.ts +4 -0
  47. package/build/ui/components/menubar.d.ts +26 -0
  48. package/build/ui/components/message-scroller.d.ts +15 -0
  49. package/build/ui/components/navigation-menu.d.ts +13 -0
  50. package/build/ui/components/page-header.d.ts +7 -1
  51. package/build/ui/components/table.d.ts +7 -1
  52. package/build/ui/index.d.ts +19 -0
  53. package/build/ui/reference/components/accordion.tsx +85 -0
  54. package/build/ui/reference/components/alert-dialog.tsx +7 -2
  55. package/build/ui/reference/components/aspect-ratio.tsx +28 -0
  56. package/build/ui/reference/components/button-group.tsx +77 -0
  57. package/build/ui/reference/components/button.tsx +8 -1
  58. package/build/ui/reference/components/carousel.tsx +248 -0
  59. package/build/ui/reference/components/chart.tsx +441 -1131
  60. package/build/ui/reference/components/collapsible.tsx +43 -0
  61. package/build/ui/reference/components/combobox.tsx +141 -0
  62. package/build/ui/reference/components/command.tsx +181 -0
  63. package/build/ui/reference/components/context-menu.tsx +243 -0
  64. package/build/ui/reference/components/data-table.tsx +199 -29
  65. package/build/ui/reference/components/date-picker.tsx +218 -0
  66. package/build/ui/reference/components/dialog.tsx +2 -2
  67. package/build/ui/reference/components/direction.tsx +22 -0
  68. package/build/ui/reference/components/dropdown-menu.tsx +2 -2
  69. package/build/ui/reference/components/field.tsx +252 -0
  70. package/build/ui/reference/components/hover-card.tsx +64 -0
  71. package/build/ui/reference/components/input-group.tsx +157 -0
  72. package/build/ui/reference/components/input-otp.tsx +106 -0
  73. package/build/ui/reference/components/input.tsx +4 -32
  74. package/build/ui/reference/components/item.tsx +188 -0
  75. package/build/ui/reference/components/kbd.tsx +43 -0
  76. package/build/ui/reference/components/label.tsx +1 -1
  77. package/build/ui/reference/components/menubar.tsx +275 -0
  78. package/build/ui/reference/components/message-scroller.tsx +141 -0
  79. package/build/ui/reference/components/nav.tsx +9 -0
  80. package/build/ui/reference/components/navigation-menu.tsx +191 -0
  81. package/build/ui/reference/components/page-header.tsx +32 -0
  82. package/build/ui/reference/components/popover.tsx +2 -2
  83. package/build/ui/reference/components/select.tsx +11 -8
  84. package/build/ui/reference/components/sheet.tsx +14 -3
  85. package/build/ui/reference/components/table.tsx +15 -2
  86. package/build/ui/reference/components/timeline.tsx +7 -0
  87. package/build/ui/reference/components/toggle.tsx +1 -1
  88. package/build/ui/reference/index.ts +19 -0
  89. package/build/ui/standalone.js +167 -28
  90. package/build/ui/styles.css +1 -1
  91. package/package.json +15 -9
  92. package/template/README.md +6 -0
  93. package/template/src/App.tsx +10 -1
@@ -0,0 +1,191 @@
1
+ 'use client';
2
+
3
+ import * as React from 'react';
4
+ import { NavigationMenu as NavigationMenuPrimitive } from 'radix-ui';
5
+ import { ChevronDownIcon } from 'lucide-react';
6
+
7
+ import { cn } from '@rise-x/ui/lib/utils';
8
+
9
+ /*
10
+ * A horizontal navigation menu with drop-down panels — the marketing-site and
11
+ * portal-landing shape.
12
+ *
13
+ * READ THIS BEFORE REACHING FOR IT. This is NOT how a Rise-X app navigates.
14
+ * App navigation is a LEFT RAIL built from `Nav`, and a federated app must never
15
+ * render a top bar at any width, because the host already renders one above every
16
+ * app. Two nav bars stacked is the exact thing that rule exists to prevent.
17
+ *
18
+ * So this component is for the surfaces that are not apps: a public site, a
19
+ * sign-in shell, a documentation portal. If you are inside an app and you want
20
+ * this, you want `Nav` plus `PageHeaderTabs`.
21
+ *
22
+ * The trigger keeps the ghost-button grammar and the panel is Popover's surface,
23
+ * so it belongs to the same system even though its use is narrow.
24
+ */
25
+ function NavigationMenu({
26
+ className,
27
+ children,
28
+ viewport = true,
29
+ ...props
30
+ }: React.ComponentProps<typeof NavigationMenuPrimitive.Root> & { viewport?: boolean }) {
31
+ return (
32
+ <NavigationMenuPrimitive.Root
33
+ data-slot="navigation-menu"
34
+ data-viewport={viewport}
35
+ className={cn(
36
+ 'group/navigation-menu relative flex max-w-max flex-1 items-center justify-center',
37
+ className,
38
+ )}
39
+ {...props}
40
+ >
41
+ {children}
42
+ {viewport && <NavigationMenuViewport />}
43
+ </NavigationMenuPrimitive.Root>
44
+ );
45
+ }
46
+
47
+ function NavigationMenuList({
48
+ className,
49
+ ...props
50
+ }: React.ComponentProps<typeof NavigationMenuPrimitive.List>) {
51
+ return (
52
+ <NavigationMenuPrimitive.List
53
+ data-slot="navigation-menu-list"
54
+ className={cn(
55
+ 'group flex flex-1 list-none items-center justify-center gap-0.5 p-0',
56
+ className,
57
+ )}
58
+ {...props}
59
+ />
60
+ );
61
+ }
62
+
63
+ function NavigationMenuItem({
64
+ className,
65
+ ...props
66
+ }: React.ComponentProps<typeof NavigationMenuPrimitive.Item>) {
67
+ return (
68
+ <NavigationMenuPrimitive.Item
69
+ data-slot="navigation-menu-item"
70
+ className={cn('relative', className)}
71
+ {...props}
72
+ />
73
+ );
74
+ }
75
+
76
+ function NavigationMenuTrigger({
77
+ className,
78
+ children,
79
+ ...props
80
+ }: React.ComponentProps<typeof NavigationMenuPrimitive.Trigger>) {
81
+ return (
82
+ <NavigationMenuPrimitive.Trigger
83
+ data-slot="navigation-menu-trigger"
84
+ className={cn(
85
+ 'group inline-flex h-control cursor-pointer items-center justify-center gap-1.5 rounded-lg border-0 bg-transparent px-3 text-ui font-medium text-muted-foreground transition-colors duration-150 ease-decelerate outline-none select-none',
86
+ 'hover:bg-muted hover:text-foreground focus-visible:ring-3 focus-visible:ring-ring-control/35',
87
+ 'data-open:bg-muted data-open:text-foreground',
88
+ className,
89
+ )}
90
+ {...props}
91
+ >
92
+ {children}
93
+ <ChevronDownIcon
94
+ aria-hidden
95
+ className="size-3 shrink-0 transition-transform duration-200 ease-decelerate group-data-open:rotate-180"
96
+ />
97
+ </NavigationMenuPrimitive.Trigger>
98
+ );
99
+ }
100
+
101
+ function NavigationMenuContent({
102
+ className,
103
+ ...props
104
+ }: React.ComponentProps<typeof NavigationMenuPrimitive.Content>) {
105
+ return (
106
+ <NavigationMenuPrimitive.Content
107
+ data-slot="navigation-menu-content"
108
+ className={cn(
109
+ 'top-0 left-0 w-full p-2.5 md:absolute md:w-auto',
110
+ // without a viewport the content is its own popover surface
111
+ 'group-data-[viewport=false]/navigation-menu:top-full group-data-[viewport=false]/navigation-menu:mt-1.5 group-data-[viewport=false]/navigation-menu:min-w-48 group-data-[viewport=false]/navigation-menu:overflow-hidden group-data-[viewport=false]/navigation-menu:rounded-xl group-data-[viewport=false]/navigation-menu:bg-popover group-data-[viewport=false]/navigation-menu:text-popover-foreground group-data-[viewport=false]/navigation-menu:shadow-pop group-data-[viewport=false]/navigation-menu:duration-100 group-data-[viewport=false]/navigation-menu:data-open:animate-in group-data-[viewport=false]/navigation-menu:data-open:fade-in-0 group-data-[viewport=false]/navigation-menu:data-open:zoom-in-95 group-data-[viewport=false]/navigation-menu:data-closed:animate-out group-data-[viewport=false]/navigation-menu:data-closed:fade-out-0 group-data-[viewport=false]/navigation-menu:data-closed:zoom-out-95',
112
+ className,
113
+ )}
114
+ {...props}
115
+ />
116
+ );
117
+ }
118
+
119
+ /*
120
+ * The viewport is one shared panel every menu animates INTO, sized to whichever
121
+ * content is open. That is what makes the panel appear to resize between menus
122
+ * rather than one closing and another opening — and it is why the panel radius
123
+ * lives here and not on the content.
124
+ */
125
+ function NavigationMenuViewport({
126
+ className,
127
+ ...props
128
+ }: React.ComponentProps<typeof NavigationMenuPrimitive.Viewport>) {
129
+ return (
130
+ <div className="absolute top-full left-0 isolate z-50 flex justify-center">
131
+ <NavigationMenuPrimitive.Viewport
132
+ data-slot="navigation-menu-viewport"
133
+ className={cn(
134
+ 'relative mt-1.5 h-(--radix-navigation-menu-viewport-height) w-full origin-top-center overflow-hidden rounded-xl bg-popover text-popover-foreground shadow-pop duration-200 md:w-(--radix-navigation-menu-viewport-width) dark:ring-foreground/10 data-open:animate-in data-open:zoom-in-90 data-closed:animate-out data-closed:zoom-out-95',
135
+ className,
136
+ )}
137
+ {...props}
138
+ />
139
+ </div>
140
+ );
141
+ }
142
+
143
+ function NavigationMenuLink({
144
+ className,
145
+ ...props
146
+ }: React.ComponentProps<typeof NavigationMenuPrimitive.Link>) {
147
+ return (
148
+ <NavigationMenuPrimitive.Link
149
+ data-slot="navigation-menu-link"
150
+ className={cn(
151
+ 'flex flex-col gap-0.5 rounded-md p-2 text-ui outline-none transition-colors duration-150 ease-decelerate',
152
+ 'hover:bg-accent hover:text-accent-foreground focus-visible:ring-3 focus-visible:ring-ring-control/35',
153
+ // the current page is not muted — it is the one you are on
154
+ 'data-[active=true]:bg-accent data-[active=true]:font-medium data-[active=true]:text-accent-foreground',
155
+ '[&_p]:text-xs [&_p]:font-normal [&_p]:text-muted-foreground [&_svg]:size-3.5 [&_svg]:shrink-0',
156
+ className,
157
+ )}
158
+ {...props}
159
+ />
160
+ );
161
+ }
162
+
163
+ /* The little arrow that tracks which trigger is open. */
164
+ function NavigationMenuIndicator({
165
+ className,
166
+ ...props
167
+ }: React.ComponentProps<typeof NavigationMenuPrimitive.Indicator>) {
168
+ return (
169
+ <NavigationMenuPrimitive.Indicator
170
+ data-slot="navigation-menu-indicator"
171
+ className={cn(
172
+ 'top-full z-50 flex h-1.5 items-end justify-center overflow-hidden duration-200 data-visible:animate-in data-visible:fade-in data-hidden:animate-out data-hidden:fade-out',
173
+ className,
174
+ )}
175
+ {...props}
176
+ >
177
+ <div className="relative top-[60%] size-2 rotate-45 rounded-tl-[2px] bg-popover shadow-pop" />
178
+ </NavigationMenuPrimitive.Indicator>
179
+ );
180
+ }
181
+
182
+ export {
183
+ NavigationMenu,
184
+ NavigationMenuList,
185
+ NavigationMenuItem,
186
+ NavigationMenuContent,
187
+ NavigationMenuTrigger,
188
+ NavigationMenuLink,
189
+ NavigationMenuIndicator,
190
+ NavigationMenuViewport,
191
+ };
@@ -1,6 +1,8 @@
1
1
  import * as React from 'react';
2
+ import { ClockIcon } from 'lucide-react';
2
3
 
3
4
  import { cn } from '@rise-x/ui/lib/utils';
5
+ import { Button } from '@rise-x/ui/components/button';
4
6
 
5
7
  /*
6
8
  * PAGE HEADER. Title, optional back-link, subtitle, actions, and tabs that sit
@@ -102,6 +104,35 @@ function PageHeaderActions({ className, ...props }: React.ComponentProps<'div'>)
102
104
  return <div data-slot="page-header-actions" className={cn('flex gap-2', className)} {...props} />;
103
105
  }
104
106
 
107
+ /* The activity affordance every app ships: one icon button, always the same
108
+ * glyph, first in PageHeaderActions. It opens the activity log as a Sheet
109
+ * sliding in from the right over the dimmed page, with its filter and search
110
+ * inside — never an inline column beside the content (see timeline.tsx).
111
+ * icon-sm because header actions are sm across the system: the header is
112
+ * chrome, and 30px keeps it denser than the content it introduces.
113
+ *
114
+ * forwardRef for the same reason button.tsx uses it: the canonical usage is
115
+ * `<SheetTrigger asChild><PageHeaderActivity /></SheetTrigger>`, and radix's
116
+ * Slot injects a ref the React 18 host would strip from a plain function. */
117
+ const PageHeaderActivity = React.forwardRef<
118
+ HTMLButtonElement,
119
+ React.ComponentPropsWithoutRef<typeof Button>
120
+ >(function PageHeaderActivity({ className, ...props }, ref) {
121
+ return (
122
+ <Button
123
+ ref={ref}
124
+ variant="outline"
125
+ size="icon-sm"
126
+ aria-label="Activity"
127
+ data-slot="page-header-activity"
128
+ className={className}
129
+ {...props}
130
+ >
131
+ <ClockIcon />
132
+ </Button>
133
+ );
134
+ });
135
+
105
136
  /* Tabs as an underline on the header rule, not a segmented control. A segmented
106
137
  * control says "filter this view"; an underlined tab says "this is a different
107
138
  * view of the same thing", which is what a page-level tab is. */
@@ -203,6 +234,7 @@ export {
203
234
  PageHeaderTitle,
204
235
  PageHeaderSubtitle,
205
236
  PageHeaderActions,
237
+ PageHeaderActivity,
206
238
  PageHeaderTabs,
207
239
  PageHeaderTab,
208
240
  Toolbar,
@@ -26,7 +26,7 @@ function PopoverContent({
26
26
  align={align}
27
27
  sideOffset={sideOffset}
28
28
  className={cn(
29
- 'z-50 flex w-72 origin-(--radix-popover-content-transform-origin) flex-col gap-4 rounded-xl bg-popover p-4 text-sm text-popover-foreground shadow-pop outline-hidden duration-100 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 dark:ring-foreground/10 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95',
29
+ 'z-50 flex w-72 origin-(--radix-popover-content-transform-origin) flex-col gap-4 rounded-xl bg-popover p-4 text-ui text-popover-foreground shadow-pop outline-hidden duration-100 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 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95',
30
30
  className,
31
31
  )}
32
32
  {...props}
@@ -43,7 +43,7 @@ function PopoverHeader({ className, ...props }: React.ComponentProps<'div'>) {
43
43
  return (
44
44
  <div
45
45
  data-slot="popover-header"
46
- className={cn('flex flex-col gap-1 text-sm', className)}
46
+ className={cn('flex flex-col gap-1 text-ui', className)}
47
47
  {...props}
48
48
  />
49
49
  );
@@ -14,7 +14,7 @@ function SelectGroup({ className, ...props }: React.ComponentProps<typeof Select
14
14
  return (
15
15
  <SelectPrimitive.Group
16
16
  data-slot="select-group"
17
- className={cn('scroll-my-1.5 p-1.5', className)}
17
+ className={cn('scroll-my-1.5', className)}
18
18
  {...props}
19
19
  />
20
20
  );
@@ -53,8 +53,11 @@ function SelectTrigger({
53
53
  function SelectContent({
54
54
  className,
55
55
  children,
56
- position = 'item-aligned',
57
- align = 'center',
56
+ /* popper, not radix's item-aligned default: every other menu in the kit
57
+ * (dropdown, combobox, date picker) opens BELOW its trigger — a select that
58
+ * overlays its own trigger and the labels around it is the odd one out. */
59
+ position = 'popper',
60
+ align = 'start',
58
61
  ...props
59
62
  }: React.ComponentProps<typeof SelectPrimitive.Content>) {
60
63
  return (
@@ -63,7 +66,10 @@ function SelectContent({
63
66
  data-slot="select-content"
64
67
  data-align-trigger={position === 'item-aligned'}
65
68
  className={cn(
66
- 'relative z-50 max-h-(--radix-select-content-available-height) w-(--radix-select-trigger-width) min-w-36 origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-xl bg-popover text-popover-foreground shadow-pop duration-100 data-[align-trigger=true]:animate-none 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 dark:ring-foreground/10 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95',
69
+ /* p-1.5 matches every other menu surface (dropdown, context,
70
+ * menubar, command) — without it the rounded-md items sit flush
71
+ * against the rounded-xl edge and clip at the corners. */
72
+ 'relative z-50 max-h-(--radix-select-content-available-height) w-(--radix-select-trigger-width) min-w-36 origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-xl bg-popover p-1.5 text-popover-foreground shadow-pop duration-100 data-[align-trigger=true]:animate-none 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 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95',
67
73
  position === 'popper' &&
68
74
  'data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1',
69
75
  className,
@@ -75,10 +81,7 @@ function SelectContent({
75
81
  <SelectScrollUpButton />
76
82
  <SelectPrimitive.Viewport
77
83
  data-position={position}
78
- className={cn(
79
- 'data-[position=popper]:h-(--radix-select-trigger-height) data-[position=popper]:w-full data-[position=popper]:min-w-(--radix-select-trigger-width)',
80
- position === 'popper' && '',
81
- )}
84
+ className="data-[position=popper]:w-full data-[position=popper]:min-w-(--radix-select-trigger-width)"
82
85
  >
83
86
  {children}
84
87
  </SelectPrimitive.Viewport>
@@ -18,6 +18,14 @@ import { XIcon } from 'lucide-react';
18
18
  * "Function components cannot be given refs" warning on every open. Only Sheet
19
19
  * (Root) and SheetPortal are left as plain functions: neither renders a DOM
20
20
  * node, and radix's own are plain too.
21
+ *
22
+ * WHEN. The Sheet is the surface for ON-DEMAND supplementary content — the
23
+ * activity log, an asset render, any "show me more about this" data. It opens
24
+ * from an affordance in the page header (the activity icon button is the
25
+ * canonical case), slides in from the right and dims the page behind it, with
26
+ * any filter or search living inside the panel. The docked Panel (nav.tsx) is
27
+ * only for surfaces that are part of the page's own layout — a persistent
28
+ * master-detail pane or a filter rail — where the page must stay interactive.
21
29
  */
22
30
 
23
31
  function Sheet({ ...props }: React.ComponentProps<typeof SheetPrimitive.Root>) {
@@ -84,8 +92,11 @@ const SheetContent = React.forwardRef<
84
92
  * reads as a separate object you could close. Radius is 18px — the
85
93
  * grouped-surface step — because it is the largest surface on screen. */
86
94
  'fixed z-50 flex flex-col overflow-hidden rounded-2xl bg-popover bg-clip-padding text-ui text-popover-foreground shadow-pop transition duration-200 ease-in-out',
87
- 'data-[side=right]:inset-y-3 data-[side=right]:right-3 data-[side=right]:w-[calc(100%-1.5rem)] data-[side=right]:sm:max-w-md',
88
- 'data-[side=left]:inset-y-3 data-[side=left]:left-3 data-[side=left]:w-[calc(100%-1.5rem)] data-[side=left]:sm:max-w-md',
95
+ /* Matches the inset-3 gutter on both sides — derived from --spacing
96
+ * rather than written as 24px, so it tracks inset-3 by construction
97
+ * instead of relying on this comment to stay true. */
98
+ 'data-[side=right]:inset-y-3 data-[side=right]:right-3 data-[side=right]:w-[calc(100%-(var(--spacing)*6))] data-[side=right]:sm:max-w-md',
99
+ 'data-[side=left]:inset-y-3 data-[side=left]:left-3 data-[side=left]:w-[calc(100%-(var(--spacing)*6))] data-[side=left]:sm:max-w-md',
89
100
  'data-[side=bottom]:inset-x-3 data-[side=bottom]:bottom-3 data-[side=bottom]:h-auto',
90
101
  'data-[side=top]:inset-x-3 data-[side=top]:top-3 data-[side=top]:h-auto',
91
102
  'data-open:animate-in data-open:fade-in-0 data-[side=bottom]:data-open:slide-in-from-bottom-10 data-[side=left]:data-open:slide-in-from-left-10 data-[side=right]:data-open:slide-in-from-right-10 data-[side=top]:data-open:slide-in-from-top-10 data-closed:animate-out data-closed:fade-out-0 data-[side=bottom]:data-closed:slide-out-to-bottom-10 data-[side=left]:data-closed:slide-out-to-left-10 data-[side=right]:data-closed:slide-out-to-right-10 data-[side=top]:data-closed:slide-out-to-top-10',
@@ -155,7 +166,7 @@ const SheetDescription = React.forwardRef<
155
166
  <SheetPrimitive.Description
156
167
  ref={ref}
157
168
  data-slot="sheet-description"
158
- className={cn('text-sm text-muted-foreground', className)}
169
+ className={cn('text-ui text-muted-foreground', className)}
159
170
  {...props}
160
171
  />
161
172
  );
@@ -22,9 +22,22 @@ import { cn } from '@rise-x/ui/lib/utils';
22
22
  * be confused with hover or selection.
23
23
  */
24
24
 
25
- function Table({ className, ...props }: React.ComponentProps<'table'>) {
25
+ function Table({
26
+ className,
27
+ containerClassName,
28
+ ...props
29
+ }: React.ComponentProps<'table'> & {
30
+ /** Extends the scroll container the table always renders inside. Sticky
31
+ * headers pin to THIS element, so a vertically scrolling table puts its
32
+ * max-height + overflow-y here — an outer scroll div never receives the
33
+ * stick. */
34
+ containerClassName?: string;
35
+ }) {
26
36
  return (
27
- <div data-slot="table-container" className="relative w-full overflow-x-auto">
37
+ <div
38
+ data-slot="table-container"
39
+ className={cn('relative w-full overflow-x-auto', containerClassName)}
40
+ >
28
41
  <table
29
42
  data-slot="table"
30
43
  className={cn('w-full caption-bottom border-separate border-spacing-0 text-ui', className)}
@@ -11,6 +11,13 @@ import { cn } from '@rise-x/ui/lib/utils';
11
11
  *
12
12
  * The rail is drawn on the node's ::after rather than as a border on the row,
13
13
  * so the last entry has no dangling tail and nothing needs a modifier class.
14
+ *
15
+ * PLACEMENT. Activity is ambient context, not page content: it opens from an
16
+ * icon button in the page header (every app's default affordance) and slides
17
+ * in from the right as a Sheet over the dimmed page, with its filter and
18
+ * search inside the panel. Never lay it out as an inline column beside the
19
+ * content — that spends a third of every viewport on history the user rarely
20
+ * reads, and the page's real content pays for it.
14
21
  */
15
22
  function Timeline({ className, ...props }: React.ComponentProps<'ol'>) {
16
23
  return <ol data-slot="timeline" className={cn('flex flex-col', className)} {...props} />;
@@ -7,7 +7,7 @@ import { Toggle as TogglePrimitive } from 'radix-ui';
7
7
  import { cn } from '@rise-x/ui/lib/utils';
8
8
 
9
9
  const toggleVariants = cva(
10
- "group/toggle inline-flex items-center justify-center gap-1 rounded-md text-sm font-medium whitespace-nowrap transition-colors outline-none hover:bg-muted hover:text-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/30 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 aria-pressed:bg-muted dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
10
+ "group/toggle inline-flex items-center justify-center gap-1 rounded-md text-ui font-medium whitespace-nowrap transition-colors outline-none hover:bg-muted hover:text-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/30 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 aria-pressed:bg-muted dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
11
11
  {
12
12
  variants: {
13
13
  variant: {
@@ -1,27 +1,46 @@
1
1
  // Root barrel — lets consumers `import { Button, cn } from '@rise-x/ui'`.
2
2
  // Subpath imports (`@rise-x/ui/components/button`) remain the canonical form
3
3
  // written by the shadcn CLI; both resolve to the same source modules.
4
+ export * from './components/accordion';
4
5
  export * from './components/ai';
5
6
  export * from './components/alert';
6
7
  export * from './components/alert-dialog';
8
+ export * from './components/aspect-ratio';
7
9
  export * from './components/avatar';
8
10
  export * from './components/badge';
9
11
  export * from './components/button';
12
+ export * from './components/button-group';
10
13
  export * from './components/calendar';
11
14
  export * from './components/card';
15
+ export * from './components/carousel';
12
16
  export * from './components/chart';
13
17
  export * from './components/checkbox';
18
+ export * from './components/collapsible';
19
+ export * from './components/combobox';
20
+ export * from './components/command';
21
+ export * from './components/context-menu';
14
22
  export * from './components/data-table';
23
+ export * from './components/date-picker';
15
24
  export * from './components/dialog';
25
+ export * from './components/direction';
16
26
  export * from './components/dropdown-menu';
17
27
  export * from './components/empty-state';
28
+ export * from './components/field';
18
29
  export * from './components/file-upload';
30
+ export * from './components/hover-card';
19
31
  export * from './components/input';
32
+ export * from './components/input-group';
33
+ export * from './components/input-otp';
34
+ export * from './components/item';
35
+ export * from './components/kbd';
20
36
  export * from './components/label';
21
37
  export * from './components/list';
22
38
  export * from './components/map';
39
+ export * from './components/menubar';
23
40
  export * from './components/message';
41
+ export * from './components/message-scroller';
24
42
  export * from './components/nav';
43
+ export * from './components/navigation-menu';
25
44
  export * from './components/page-header';
26
45
  export * from './components/popover';
27
46
  export * from './components/progress';