@cosmoops/connect-sdk 0.7.0 → 0.15.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.
- package/CHANGELOG.md +662 -0
- package/README.md +376 -124
- package/dist/cjs/cli/doctor.js +3 -3
- package/dist/cjs/cli/init.js +3 -3
- package/dist/cjs/client/components/access-gate.js +59 -5
- package/dist/cjs/client/components/ai-format.js +135 -0
- package/dist/cjs/client/components/ai-widgets.js +232 -0
- package/dist/cjs/client/components/app-shell.js +80 -45
- package/dist/cjs/client/components/apps-grid.js +3 -2
- package/dist/cjs/client/components/ask-ai.js +353 -0
- package/dist/cjs/client/components/confirm-dialog.js +40 -0
- package/dist/cjs/client/components/cursor-pagination.js +22 -0
- package/dist/cjs/client/components/filter-tabs.js +24 -0
- package/dist/cjs/client/components/grievance-notice.js +30 -0
- package/dist/cjs/client/components/link-button.js +17 -10
- package/dist/cjs/client/components/logo.js +4 -3
- package/dist/cjs/client/components/nav.js +42 -1
- package/dist/cjs/client/components/plan-pricing.js +27 -0
- package/dist/cjs/client/components/plans.js +1 -1
- package/dist/cjs/client/components/platform-gate.js +48 -0
- package/dist/cjs/client/components/shell-context.js +149 -0
- package/dist/cjs/client/components/side-nav.js +50 -24
- package/dist/cjs/client/components/sidebar.js +127 -0
- package/dist/cjs/client/components/subscribe-dialog.js +2 -2
- package/dist/cjs/client/components/subscription.js +1 -1
- package/dist/cjs/client/components/user-menu.js +122 -40
- package/dist/cjs/client/components/workspace-switcher.js +100 -0
- package/dist/cjs/client/components/workspace-type-gate.js +48 -0
- package/dist/cjs/client/index.js +98 -3
- package/dist/cjs/client/provider.js +100 -2
- package/dist/cjs/client/use-checkout.js +9 -5
- package/dist/cjs/errors.js +1 -1
- package/dist/cjs/index.js +11 -1
- package/dist/cjs/next/index.js +2 -2
- package/dist/cjs/server/client.js +25 -2
- package/dist/cjs/server/handler.js +237 -16
- package/dist/cjs/server/http.js +52 -26
- package/dist/cjs/server/resources/acting-as.js +16 -0
- package/dist/cjs/server/resources/ai.js +15 -2
- package/dist/cjs/server/resources/data.js +374 -0
- package/dist/cjs/server/resources/entitlements.js +41 -0
- package/dist/cjs/server/resources/identity.js +9 -3
- package/dist/cjs/server/resources/kv.js +84 -0
- package/dist/cjs/server/resources/platform.js +43 -0
- package/dist/cjs/server/resources/sessions.js +1 -1
- package/dist/cjs/server/resources/workspaces.js +74 -0
- package/dist/cjs/store.js +152 -0
- package/dist/cjs/ui/empty-state.js +28 -0
- package/dist/cjs/ui/index.js +44 -0
- package/dist/cjs/ui/page-header.js +27 -0
- package/dist/cjs/ui/page-shell.js +44 -0
- package/dist/cjs/ui/section.js +20 -0
- package/dist/cjs/ui/setting-row.js +14 -0
- package/dist/cjs/ui/status-chip.js +17 -0
- package/dist/esm/cli/doctor.js +3 -3
- package/dist/esm/cli/init.js +3 -3
- package/dist/esm/client/components/access-gate.js +60 -6
- package/dist/esm/client/components/ai-format.js +129 -0
- package/dist/esm/client/components/ai-widgets.js +223 -0
- package/dist/esm/client/components/app-shell.js +85 -50
- package/dist/esm/client/components/apps-grid.js +3 -2
- package/dist/esm/client/components/ask-ai.js +350 -0
- package/dist/esm/client/components/confirm-dialog.js +37 -0
- package/dist/esm/client/components/cursor-pagination.js +19 -0
- package/dist/esm/client/components/filter-tabs.js +21 -0
- package/dist/esm/client/components/grievance-notice.js +27 -0
- package/dist/esm/client/components/link-button.js +17 -10
- package/dist/esm/client/components/logo.js +4 -3
- package/dist/esm/client/components/nav.js +41 -1
- package/dist/esm/client/components/plan-pricing.js +25 -0
- package/dist/esm/client/components/plans.js +2 -2
- package/dist/esm/client/components/platform-gate.js +45 -0
- package/dist/esm/client/components/shell-context.js +141 -0
- package/dist/esm/client/components/side-nav.js +49 -22
- package/dist/esm/client/components/sidebar.js +120 -0
- package/dist/esm/client/components/subscribe-dialog.js +3 -3
- package/dist/esm/client/components/subscription.js +2 -2
- package/dist/esm/client/components/user-menu.js +121 -41
- package/dist/esm/client/components/workspace-switcher.js +97 -0
- package/dist/esm/client/components/workspace-type-gate.js +45 -0
- package/dist/esm/client/index.js +58 -5
- package/dist/esm/client/provider.js +94 -2
- package/dist/esm/client/use-checkout.js +9 -5
- package/dist/esm/errors.js +1 -1
- package/dist/esm/index.js +1 -0
- package/dist/esm/next/index.js +2 -2
- package/dist/esm/server/client.js +25 -2
- package/dist/esm/server/handler.js +237 -16
- package/dist/esm/server/http.js +52 -26
- package/dist/esm/server/resources/acting-as.js +13 -0
- package/dist/esm/server/resources/ai.js +15 -2
- package/dist/esm/server/resources/data.js +369 -0
- package/dist/esm/server/resources/entitlements.js +41 -0
- package/dist/esm/server/resources/identity.js +9 -3
- package/dist/esm/server/resources/kv.js +80 -0
- package/dist/esm/server/resources/platform.js +39 -0
- package/dist/esm/server/resources/sessions.js +1 -1
- package/dist/esm/server/resources/workspaces.js +70 -0
- package/dist/esm/store.js +141 -0
- package/dist/esm/ui/empty-state.js +25 -0
- package/dist/esm/ui/index.js +34 -0
- package/dist/esm/ui/page-header.js +24 -0
- package/dist/esm/ui/page-shell.js +41 -0
- package/dist/esm/ui/section.js +17 -0
- package/dist/esm/ui/setting-row.js +11 -0
- package/dist/esm/ui/status-chip.js +14 -0
- package/dist/theme.css +87 -0
- package/dist/types/client/components/access-gate.d.ts +17 -3
- package/dist/types/client/components/ai-format.d.ts +24 -0
- package/dist/types/client/components/ai-widgets.d.ts +42 -0
- package/dist/types/client/components/app-shell.d.ts +85 -31
- package/dist/types/client/components/apps-grid.d.ts +11 -2
- package/dist/types/client/components/ask-ai.d.ts +73 -0
- package/dist/types/client/components/confirm-dialog.d.ts +34 -0
- package/dist/types/client/components/cursor-pagination.d.ts +27 -0
- package/dist/types/client/components/filter-tabs.d.ts +26 -0
- package/dist/types/client/components/grievance-notice.d.ts +31 -0
- package/dist/types/client/components/link-button.d.ts +32 -9
- package/dist/types/client/components/logo.d.ts +18 -2
- package/dist/types/client/components/nav.d.ts +27 -3
- package/dist/types/client/components/plan-pricing.d.ts +10 -0
- package/dist/types/client/components/platform-gate.d.ts +53 -0
- package/dist/types/client/components/shell-context.d.ts +116 -0
- package/dist/types/client/components/side-nav.d.ts +28 -14
- package/dist/types/client/components/sidebar.d.ts +95 -0
- package/dist/types/client/components/user-menu.d.ts +70 -23
- package/dist/types/client/components/workspace-switcher.d.ts +49 -0
- package/dist/types/client/components/workspace-type-gate.d.ts +48 -0
- package/dist/types/client/index.d.ts +36 -7
- package/dist/types/client/provider.d.ts +149 -3
- package/dist/types/client/use-checkout.d.ts +8 -4
- package/dist/types/errors.d.ts +1 -1
- package/dist/types/index.d.ts +2 -0
- package/dist/types/next/index.d.ts +1 -1
- package/dist/types/server/client.d.ts +25 -2
- package/dist/types/server/http.d.ts +14 -3
- package/dist/types/server/index.d.ts +4 -0
- package/dist/types/server/resources/acting-as.d.ts +11 -0
- package/dist/types/server/resources/ai.d.ts +9 -1
- package/dist/types/server/resources/data.d.ts +258 -0
- package/dist/types/server/resources/entitlements.d.ts +33 -1
- package/dist/types/server/resources/kv.d.ts +63 -0
- package/dist/types/server/resources/platform.d.ts +32 -0
- package/dist/types/server/resources/workspaces.d.ts +55 -0
- package/dist/types/store.d.ts +96 -0
- package/dist/types/types.d.ts +491 -13
- package/dist/types/ui/empty-state.d.ts +34 -0
- package/dist/types/ui/index.d.ts +40 -0
- package/dist/types/ui/page-header.d.ts +34 -0
- package/dist/types/ui/page-shell.d.ts +39 -0
- package/dist/types/ui/section.d.ts +26 -0
- package/dist/types/ui/setting-row.d.ts +18 -0
- package/dist/types/ui/status-chip.d.ts +36 -0
- package/package.json +13 -3
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import { type ReactNode } from "react";
|
|
2
|
+
import type { ConnectLinkRenderer } from "./nav.js";
|
|
3
|
+
/** A plain anchor - correct anywhere, and a full page load. See `ConnectLinkRenderer`. */
|
|
4
|
+
export declare const defaultRenderLink: ConnectLinkRenderer;
|
|
5
|
+
/**
|
|
6
|
+
* The rail's two widths, in pixels, and the one place they are written down.
|
|
7
|
+
*
|
|
8
|
+
* They are numbers rather than Tailwind classes because the rail animates
|
|
9
|
+
* between them - `motion` interpolates a number and cannot interpolate
|
|
10
|
+
* `w-16` into `w-64`.
|
|
11
|
+
*
|
|
12
|
+
* **The pairing is load-bearing, not arbitrary.** Every row in the sidebar is
|
|
13
|
+
* laid out so its glyph sits exactly `RAIL_GUTTER + ROW_GUTTER + 10px` from
|
|
14
|
+
* the rail's left edge - 32px, which is also `RAIL_COLLAPSED / 2`. So the
|
|
15
|
+
* collapsed rail centres every icon *without a single centring rule*, and
|
|
16
|
+
* nothing moves horizontally while the width animates. Change either width
|
|
17
|
+
* and that identity breaks: the icons drift sideways during the transition,
|
|
18
|
+
* which is the exact stutter this geometry exists to avoid.
|
|
19
|
+
*/
|
|
20
|
+
export declare const RAIL_COLLAPSED = 64;
|
|
21
|
+
export declare const RAIL_EXPANDED = 264;
|
|
22
|
+
/** Horizontal padding inside the rail, on every region. Tailwind `px-3`. */
|
|
23
|
+
export declare const RAIL_GUTTER = 12;
|
|
24
|
+
/**
|
|
25
|
+
* The row shape every sidebar control shares - nav items, the workspace tile,
|
|
26
|
+
* the launcher, the user button.
|
|
27
|
+
*
|
|
28
|
+
* `overflow-hidden` + `whitespace-nowrap` is what makes the collapse smooth:
|
|
29
|
+
* the label is *clipped* by the shrinking rail rather than re-wrapped or
|
|
30
|
+
* re-measured, so a width animation costs no reflow. Fading the label with
|
|
31
|
+
* `SidebarLabel` on top of that hides the clip itself.
|
|
32
|
+
*/
|
|
33
|
+
export declare const SIDEBAR_ROW = "group/row relative flex h-10 w-full shrink-0 items-center justify-start gap-3 overflow-hidden whitespace-nowrap rounded-lg pe-2 text-sm font-normal transition-colors focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-focus";
|
|
34
|
+
/**
|
|
35
|
+
* Leading inset for a row whose glyph is 20px wide (a nav icon, the launcher).
|
|
36
|
+
* `10 + 10 = 20`, and `RAIL_GUTTER + 20 = 32`. See `RAIL_COLLAPSED`.
|
|
37
|
+
*/
|
|
38
|
+
export declare const SIDEBAR_ROW_ICON = "ps-[10px]";
|
|
39
|
+
/**
|
|
40
|
+
* Leading inset for a row whose glyph is 32px wide (the avatar, the workspace
|
|
41
|
+
* tile). `4 + 16 = 20`, landing on the same 32px centre as `SIDEBAR_ROW_ICON`.
|
|
42
|
+
*/
|
|
43
|
+
export declare const SIDEBAR_ROW_TILE = "ps-[4px]";
|
|
44
|
+
/**
|
|
45
|
+
* The class list for one sidebar row, in one place.
|
|
46
|
+
*
|
|
47
|
+
* Three different elements need it - a plain `<button>` (`ConnectSidebarRow`),
|
|
48
|
+
* a rendered link (`ConnectSidebarNav`), and a HeroUI `<Button>` acting as a
|
|
49
|
+
* `Modal`/`Dropdown` trigger (the account row, the launcher, the workspace
|
|
50
|
+
* tile). They cannot share a component, because a React Aria overlay has to
|
|
51
|
+
* own its own trigger element - so they share this instead. A second copy of
|
|
52
|
+
* the string is a row that drifts off the 32px centre and takes the collapse
|
|
53
|
+
* animation's smoothness with it.
|
|
54
|
+
*
|
|
55
|
+
* On the HeroUI trigger: these are all Tailwind *utilities*, and HeroUI's
|
|
56
|
+
* `.button` is a component class, so the utility layer wins - which is what
|
|
57
|
+
* lets a `w-fit`, centred, `px-`-padded button take this shape at all.
|
|
58
|
+
*/
|
|
59
|
+
export declare function sidebarRowClass(options?: Readonly<{
|
|
60
|
+
/** The glyph is 32px (an avatar, a workspace tile) rather than 20px. */
|
|
61
|
+
tile?: boolean;
|
|
62
|
+
/** Paint the active treatment. */
|
|
63
|
+
active?: boolean;
|
|
64
|
+
className?: string;
|
|
65
|
+
}>): string;
|
|
66
|
+
export interface ConnectShellContextValue {
|
|
67
|
+
/** Icon-only rail. Always `false` inside the mobile drawer - see `AppShell`. */
|
|
68
|
+
collapsed: boolean;
|
|
69
|
+
/** Whether a collapse control should be offered at all. */
|
|
70
|
+
collapsible: boolean;
|
|
71
|
+
setCollapsed: (collapsed: boolean) => void;
|
|
72
|
+
renderLink: ConnectLinkRenderer;
|
|
73
|
+
/** The host router's current path, if it supplied one. */
|
|
74
|
+
activePath?: string;
|
|
75
|
+
/** Called after any sidebar link is pressed - the mobile drawer closes itself with this. */
|
|
76
|
+
onNavigate?: () => void;
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Shared state for every part of the shell, so `ConnectSidebarNav`,
|
|
80
|
+
* `ConnectWorkspaceSwitcher` and `ConnectUserButton` all know whether the rail
|
|
81
|
+
* is collapsed without the host threading a prop through three layers.
|
|
82
|
+
*
|
|
83
|
+
* This is the piece that makes the shell *composable* rather than only
|
|
84
|
+
* configurable: the parts are exported and can be rearranged, and they still
|
|
85
|
+
* agree about collapse, routing and the mobile drawer because they read one
|
|
86
|
+
* context instead of one another's props.
|
|
87
|
+
*/
|
|
88
|
+
export declare function ConnectShellProvider({ value, children, }: Readonly<{
|
|
89
|
+
value: ConnectShellContextValue;
|
|
90
|
+
children: ReactNode;
|
|
91
|
+
}>): import("react").JSX.Element;
|
|
92
|
+
/**
|
|
93
|
+
* The shell state a sidebar part is rendering inside.
|
|
94
|
+
*
|
|
95
|
+
* Falls back to "expanded, not collapsible, plain anchors" rather than
|
|
96
|
+
* throwing, because every part is also exported for use *outside* a shell -
|
|
97
|
+
* a host dropping `ConnectSidebarNav` into a layout it already owns should
|
|
98
|
+
* not have to mount a provider to get a nav column.
|
|
99
|
+
*/
|
|
100
|
+
export declare function useConnectShell(): ConnectShellContextValue;
|
|
101
|
+
/**
|
|
102
|
+
* A sidebar row's text, faded out as the rail collapses.
|
|
103
|
+
*
|
|
104
|
+
* Opacity only - never width, height or margin. The rail's own width
|
|
105
|
+
* animation already moves the clip edge past this text; animating the text's
|
|
106
|
+
* box as well would make two things fight over the same pixels and is what
|
|
107
|
+
* makes a collapsing sidebar look like it stutters.
|
|
108
|
+
*
|
|
109
|
+
* Asymmetric timing on purpose. Collapsing, the label leaves *first* (no
|
|
110
|
+
* delay, quick) so the rail never appears to squeeze text; expanding, it
|
|
111
|
+
* arrives *after* the rail has opened enough to hold it.
|
|
112
|
+
*/
|
|
113
|
+
export declare function SidebarLabel({ children, className, }: Readonly<{
|
|
114
|
+
children: ReactNode;
|
|
115
|
+
className?: string;
|
|
116
|
+
}>): import("react").JSX.Element;
|
|
@@ -1,19 +1,20 @@
|
|
|
1
|
+
import { defaultRenderLink } from "./shell-context.js";
|
|
1
2
|
import { type ConnectLinkRenderer, type ConnectNav } from "./nav.js";
|
|
2
|
-
|
|
3
|
-
export
|
|
4
|
-
export interface ConnectSideNavProps {
|
|
3
|
+
export { defaultRenderLink };
|
|
4
|
+
export interface ConnectSidebarNavProps {
|
|
5
5
|
/** Items, sections, or a mix - see `ConnectNav`. */
|
|
6
6
|
nav: ConnectNav;
|
|
7
7
|
/**
|
|
8
|
-
* The current path. Pass your router's own (`usePathname()` in Next)
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
* never has to do.
|
|
8
|
+
* The current path. Pass your router's own (`usePathname()` in Next).
|
|
9
|
+
* Inherited from `AppShell` when omitted; without either, the nav
|
|
10
|
+
* reads `window.location` and patches `history` to hear about client-side
|
|
11
|
+
* navigations - which works, but is guesswork the router never has to do.
|
|
12
|
+
* See `useActivePath`.
|
|
12
13
|
*/
|
|
13
14
|
activePath?: string;
|
|
14
|
-
/** See `ConnectLinkRenderer`.
|
|
15
|
+
/** See `ConnectLinkRenderer`. Inherited from the shell; defaults to a plain `<a>`. */
|
|
15
16
|
renderLink?: ConnectLinkRenderer;
|
|
16
|
-
/** Icon-only rail.
|
|
17
|
+
/** Icon-only rail. Inherited from the shell when omitted. */
|
|
17
18
|
collapsed?: boolean;
|
|
18
19
|
/** Called after any nav link is pressed - the mobile drawer closes itself with this. */
|
|
19
20
|
onNavigate?: () => void;
|
|
@@ -23,9 +24,22 @@ export interface ConnectSideNavProps {
|
|
|
23
24
|
* The sidebar's nav column on its own - sections, items, one level of
|
|
24
25
|
* children, and the active highlight.
|
|
25
26
|
*
|
|
26
|
-
* `
|
|
27
|
-
* is exported for a host that wants the shell's navigation without its
|
|
28
|
-
*
|
|
29
|
-
*
|
|
27
|
+
* `AppShell` renders this inside its rail and its mobile drawer, and it
|
|
28
|
+
* is exported for a host that wants the shell's navigation without its chrome:
|
|
29
|
+
* the same items, the same active resolution, dropped into a layout you
|
|
30
|
+
* already have.
|
|
31
|
+
*
|
|
32
|
+
* Every prop is optional except `nav`, because inside a shell they are all
|
|
33
|
+
* inherited from it. Passing one wins over what the shell says - which is how
|
|
34
|
+
* a second nav column (see `secondaryNav`) can share the rail's collapse state
|
|
35
|
+
* while keeping its own items.
|
|
36
|
+
*/
|
|
37
|
+
export declare function ConnectSidebarNav({ nav, activePath, renderLink, collapsed, onNavigate, className, }: ConnectSidebarNavProps): import("react").JSX.Element;
|
|
38
|
+
/**
|
|
39
|
+
* @deprecated Renamed to `ConnectSidebarNav` in 0.12 - the rail is a
|
|
40
|
+
* `ConnectSidebar` now, and its pieces are named after it. Identical
|
|
41
|
+
* behaviour; this alias will be removed in a later minor.
|
|
30
42
|
*/
|
|
31
|
-
export declare
|
|
43
|
+
export declare const ConnectSideNav: typeof ConnectSidebarNav;
|
|
44
|
+
/** @deprecated Renamed to `ConnectSidebarNavProps`. */
|
|
45
|
+
export type ConnectSideNavProps = ConnectSidebarNavProps;
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
import type { ComponentPropsWithoutRef, ReactNode } from "react";
|
|
2
|
+
export interface ConnectSidebarProps {
|
|
3
|
+
/**
|
|
4
|
+
* The rail's contents, top to bottom. `AppShell` composes the default
|
|
5
|
+
* set; pass your own to rearrange them.
|
|
6
|
+
*/
|
|
7
|
+
children: ReactNode;
|
|
8
|
+
/** Accessible name for the `<aside>`. Defaults to `"Sidebar"`. */
|
|
9
|
+
label?: string;
|
|
10
|
+
className?: string;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* The application rail: a fixed-width column that animates between an
|
|
14
|
+
* icon-only 64px and a labelled 264px.
|
|
15
|
+
*
|
|
16
|
+
* **Why width, and nothing else, animates.** Every row inside puts its glyph
|
|
17
|
+
* on the same 32px centre in both states (see `RAIL_COLLAPSED`), and every
|
|
18
|
+
* label is clipped rather than re-measured (see `SIDEBAR_ROW`). So the only
|
|
19
|
+
* property in flight is this element's width: no child moves, no text
|
|
20
|
+
* re-wraps, and there is no per-frame layout pass on the rows. That is why the
|
|
21
|
+
* collapse looks smooth rather than merely fast.
|
|
22
|
+
*
|
|
23
|
+
* Hidden below `md`. The mobile drawer renders the same children with
|
|
24
|
+
* `collapsed: false`, because a 64px icon rail on a phone is a worse drawer,
|
|
25
|
+
* not a smaller one.
|
|
26
|
+
*/
|
|
27
|
+
export declare function ConnectSidebar({ children, label, className }: ConnectSidebarProps): import("react").JSX.Element;
|
|
28
|
+
export interface ConnectSidebarHeaderProps {
|
|
29
|
+
/** This application's name, in the `cosmo·ops VOICE` lockup. See `ConnectLogo`. */
|
|
30
|
+
name: string;
|
|
31
|
+
/** This application's glyph, drawn on the CosmoOps badge. */
|
|
32
|
+
icon?: ReactNode;
|
|
33
|
+
/** Where the lockup links when the rail is expanded. Defaults to `/`. */
|
|
34
|
+
homeHref?: string;
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* The brand row, and the rail's own expand/collapse control.
|
|
38
|
+
*
|
|
39
|
+
* **Two states, one DOM.** The badge is mounted once and never re-created; the
|
|
40
|
+
* wordmark fades beside it and the collapse button fades at the trailing edge.
|
|
41
|
+
* Swapping which *element* renders the brand would remount it halfway through
|
|
42
|
+
* the width animation and flicker.
|
|
43
|
+
*
|
|
44
|
+
* Collapsed, hovering or focusing the badge swaps it for the expand glyph, so
|
|
45
|
+
* the rail needs no permanent control eating a row. Expanded, the control sits
|
|
46
|
+
* at the header's trailing edge, where it can be aimed at without covering the
|
|
47
|
+
* brand. The swap is pure CSS on a `group` - hovering re-renders nothing,
|
|
48
|
+
* which is what keeps it instant.
|
|
49
|
+
*
|
|
50
|
+
* The trade this makes, deliberately: **collapsed, the lockup is no longer a
|
|
51
|
+
* link home.** It has become the expand control, and one target that navigates
|
|
52
|
+
* on click but expands on click-after-hover would be worse than either. Put
|
|
53
|
+
* home in the nav; every application already does.
|
|
54
|
+
*/
|
|
55
|
+
export declare function ConnectSidebarHeader({ name, icon, homeHref }: ConnectSidebarHeaderProps): import("react").JSX.Element;
|
|
56
|
+
/**
|
|
57
|
+
* The rail's scrolling region, for the primary navigation. Everything else in
|
|
58
|
+
* the sidebar is `shrink-0`, so this is the only part that ever gives way.
|
|
59
|
+
*/
|
|
60
|
+
export declare function ConnectSidebarBody({ children }: Readonly<{
|
|
61
|
+
children: ReactNode;
|
|
62
|
+
}>): import("react").JSX.Element;
|
|
63
|
+
/**
|
|
64
|
+
* A pinned region at the foot of the rail - the secondary nav, the launcher,
|
|
65
|
+
* the account row.
|
|
66
|
+
*
|
|
67
|
+
* `separated` draws the hairline above it. The account row wants one; a
|
|
68
|
+
* secondary nav sitting directly on top of the account row does not, or the
|
|
69
|
+
* rail ends in two rules a few pixels apart.
|
|
70
|
+
*/
|
|
71
|
+
export declare function ConnectSidebarFooter({ children, separated, }: Readonly<{
|
|
72
|
+
children: ReactNode;
|
|
73
|
+
separated?: boolean;
|
|
74
|
+
}>): import("react").JSX.Element;
|
|
75
|
+
export type ConnectSidebarRowProps = Readonly<{
|
|
76
|
+
/** The glyph. 20px by default; 32px when `tile`. */
|
|
77
|
+
icon: ReactNode;
|
|
78
|
+
/** The row's text, and - when it is a string - its accessible name. */
|
|
79
|
+
label: ReactNode;
|
|
80
|
+
/** Overrides the accessible name. Required when `label` is not a string. */
|
|
81
|
+
"aria-label"?: string;
|
|
82
|
+
/** The glyph is 32px (an avatar, a workspace tile) rather than 20px. */
|
|
83
|
+
tile?: boolean;
|
|
84
|
+
/** Trailing content, e.g. a chevron. Clipped with the label while collapsed. */
|
|
85
|
+
trailing?: ReactNode;
|
|
86
|
+
}> & Omit<ComponentPropsWithoutRef<"button">, "aria-label">;
|
|
87
|
+
/**
|
|
88
|
+
* A pressable row in the rail that is not a nav item - the launcher, the
|
|
89
|
+
* account button, anything a host adds to the footer.
|
|
90
|
+
*
|
|
91
|
+
* Exported so a host's own row lines up with the SDK's. It applies the same
|
|
92
|
+
* 32px glyph centre and the same label fade, which is what stops a partner's
|
|
93
|
+
* "Help" row drifting sideways while every row above it holds still.
|
|
94
|
+
*/
|
|
95
|
+
export declare function ConnectSidebarRow({ icon, label, tile, trailing, className, "aria-label": ariaLabel, ...props }: ConnectSidebarRowProps): import("react").JSX.Element;
|
|
@@ -14,35 +14,81 @@ export interface ConnectUserMenuProps {
|
|
|
14
14
|
theme?: ThemeMode;
|
|
15
15
|
onThemeChange?: (theme: ThemeMode) => void;
|
|
16
16
|
}
|
|
17
|
+
export interface ConnectProfileModalProps {
|
|
18
|
+
/** Controlled open state. */
|
|
19
|
+
isOpen: boolean;
|
|
20
|
+
onOpenChange: (isOpen: boolean) => void;
|
|
21
|
+
/** Called after sign-out completes, e.g. to route home. */
|
|
22
|
+
onSignOut?: () => void;
|
|
23
|
+
/** See `ConnectUserButtonProps.theme`. */
|
|
24
|
+
theme?: ThemeMode;
|
|
25
|
+
onThemeChange?: (theme: ThemeMode) => void;
|
|
26
|
+
}
|
|
17
27
|
/**
|
|
18
|
-
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
28
|
+
* The account modal with **no trigger of its own**, driven by the host.
|
|
29
|
+
*
|
|
30
|
+
* For an application that already has an account control it wants to keep -
|
|
31
|
+
* an avatar in its own chrome, a "Manage account" row in its own settings
|
|
32
|
+
* page - and wants Connect's modal behind it rather than rebuilding identity,
|
|
33
|
+
* sessions and sign-out. `ConnectUserButton` is the same modal with the
|
|
34
|
+
* trigger supplied; reach for this one only when that trigger is in the way.
|
|
21
35
|
*
|
|
22
|
-
*
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
36
|
+
* Renders nothing when signed out, open or not - there is no account to show.
|
|
37
|
+
*/
|
|
38
|
+
export declare function ConnectProfileModal({ isOpen, onOpenChange, onSignOut, theme, onThemeChange, }: ConnectProfileModalProps): import("react").JSX.Element | null;
|
|
39
|
+
export interface ConnectUserButtonProps {
|
|
40
|
+
/**
|
|
41
|
+
* How the trigger is drawn.
|
|
42
|
+
*
|
|
43
|
+
* - `"row"` - a full-width sidebar row: avatar, name over email, and a
|
|
44
|
+
* trailing glyph. The default, because the account control now lives in
|
|
45
|
+
* the rail's footer rather than in a top bar.
|
|
46
|
+
* - `"compact"` - the avatar alone, for a dense strip.
|
|
47
|
+
* - `"inline"` - avatar and name side by side, for a bar with room.
|
|
48
|
+
*/
|
|
49
|
+
variant?: "row" | "compact" | "inline";
|
|
50
|
+
/** Called after sign-out completes, e.g. to route home. */
|
|
51
|
+
onSignOut?: () => void;
|
|
52
|
+
className?: string;
|
|
53
|
+
/**
|
|
54
|
+
* Current theme, and where to send a change - the SDK has no theme provider
|
|
55
|
+
* of its own (no `next-themes` dependency), so this is entirely
|
|
56
|
+
* host-controlled. The Appearance section only renders when both are
|
|
57
|
+
* supplied; omit either to leave theme control out of the modal.
|
|
58
|
+
*/
|
|
59
|
+
theme?: ThemeMode;
|
|
60
|
+
onThemeChange?: (theme: ThemeMode) => void;
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* The signed-in account, as a control that opens the account modal.
|
|
28
64
|
*
|
|
29
|
-
*
|
|
30
|
-
*
|
|
31
|
-
*
|
|
65
|
+
* In `"row"` form this is the last thing in the sidebar, which is where an
|
|
66
|
+
* account control belongs: it is the one item in the rail that is about *you*
|
|
67
|
+
* rather than about the product, and the foot of a column is where every
|
|
68
|
+
* application a customer already uses puts that. It collapses with the rail -
|
|
69
|
+
* the avatar holds its position and the name fades - because the avatar alone
|
|
70
|
+
* is still a complete account control, which is exactly what an icon rail
|
|
71
|
+
* needs.
|
|
32
72
|
*
|
|
33
|
-
* Renders nothing when signed out
|
|
34
|
-
* renders nothing when signed *in*, and the two swap
|
|
35
|
-
*
|
|
73
|
+
* Renders nothing when signed out. Pair it with `<ConnectLoginButton>`, which
|
|
74
|
+
* renders nothing when signed *in*, and the two swap with no branch in your
|
|
75
|
+
* own layout.
|
|
36
76
|
*
|
|
37
77
|
* On the HeroUI shape: the trigger is a plain `<Button>` as a **direct child**
|
|
38
|
-
* of `<Modal>`, not wrapped in `<Modal.Trigger>`. `Dropdown.Trigger`
|
|
39
|
-
* the same construction
|
|
40
|
-
* wrapping one produces a button inside a button
|
|
41
|
-
* handling stops working.
|
|
42
|
-
|
|
43
|
-
|
|
78
|
+
* of `<Modal>`, not wrapped in `<Modal.Trigger>`. `Dropdown.Trigger` - and by
|
|
79
|
+
* the same construction `Modal.Trigger` - is itself a React Aria `Button`, so
|
|
80
|
+
* wrapping one produces a button inside a button: invalid markup, and press
|
|
81
|
+
* handling stops working.
|
|
82
|
+
*/
|
|
83
|
+
export declare function ConnectUserButton({ variant, onSignOut, className, theme, onThemeChange, }: ConnectUserButtonProps): import("react").JSX.Element | null;
|
|
84
|
+
/**
|
|
85
|
+
* @deprecated Renamed to `ConnectUserButton` in 0.12 - it is one button that
|
|
86
|
+
* opens a modal, and calling it a "menu" had people looking for a dropdown
|
|
87
|
+
* that never existed. `compact` maps to `variant="compact"`, and the old
|
|
88
|
+
* default (avatar plus name) to `variant="inline"`. This alias will be removed
|
|
89
|
+
* in a later minor.
|
|
44
90
|
*/
|
|
45
|
-
export declare function ConnectUserMenu({ compact,
|
|
91
|
+
export declare function ConnectUserMenu({ compact, ...rest }: ConnectUserMenuProps): import("react").JSX.Element;
|
|
46
92
|
/**
|
|
47
93
|
* The "Manage subscription" action on its own, for layouts that want it
|
|
48
94
|
* visible rather than buried in the account menu - a billing banner, an empty
|
|
@@ -70,7 +116,8 @@ export declare function ConnectInvoicesButton({ className }: Readonly<{
|
|
|
70
116
|
* `ConnectHomeButton`.
|
|
71
117
|
*
|
|
72
118
|
* It was reachable only from inside `ConnectUserMenu`, which meant an app that
|
|
73
|
-
* builds its own account menu had to hardcode `${appUrl}/profile` to offer it
|
|
119
|
+
* builds its own account menu had to hardcode `${appUrl}/profile` to offer it -
|
|
120
|
+
* and got no `return_to`, so the user had no way back.
|
|
74
121
|
*/
|
|
75
122
|
export declare function ConnectProfileButton({ className }: Readonly<{
|
|
76
123
|
className?: string;
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import type { UserWorkspace } from "../../types.js";
|
|
2
|
+
export interface ConnectWorkspaceSwitcherProps {
|
|
3
|
+
/**
|
|
4
|
+
* Called after a successful switch. Defaults to a full reload, which is
|
|
5
|
+
* almost always right: every server-rendered page in the host application
|
|
6
|
+
* was built for the *previous* workspace, and a client-side refresh would
|
|
7
|
+
* leave stale data on screen next to the new workspace's name.
|
|
8
|
+
*/
|
|
9
|
+
onSwitched?: (workspace: UserWorkspace) => void;
|
|
10
|
+
/**
|
|
11
|
+
* Draw the trigger as a sidebar row rather than a plain button. On by
|
|
12
|
+
* default inside `AppShell`, where this sits directly under the
|
|
13
|
+
* brand; pass `false` for a standalone placement in your own chrome.
|
|
14
|
+
*/
|
|
15
|
+
row?: boolean;
|
|
16
|
+
className?: string;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Switches which workspace this application is looking at.
|
|
20
|
+
*
|
|
21
|
+
* **Rendered in the `AppShell` sidebar header by default**, directly
|
|
22
|
+
* under the brand - which workspace you are in scopes everything below it, so
|
|
23
|
+
* it reads as a heading for the nav rather than as one more destination.
|
|
24
|
+
*
|
|
25
|
+
* It decides for itself whether to appear: an account with one workspace is
|
|
26
|
+
* shown nothing, because a switcher offering one option teaches the user
|
|
27
|
+
* nothing and costs a row of chrome on every screen. That is the opposite of
|
|
28
|
+
* Connect's own switcher, which always renders - Connect is where a workspace
|
|
29
|
+
* is *created*, so hiding it at one workspace would guarantee nobody ever
|
|
30
|
+
* reached two. A partner application creates nothing, so it has no such duty.
|
|
31
|
+
*
|
|
32
|
+
* **Authorization is the data, not a prop.** The list comes from the caller's
|
|
33
|
+
* own session (`GET /workspaces` takes no user id), so a workspace the user
|
|
34
|
+
* may not reach is simply not in it. There is deliberately no `roles` prop to
|
|
35
|
+
* pass or forget - the only way to render a row is for Connect to have
|
|
36
|
+
* returned it.
|
|
37
|
+
*
|
|
38
|
+
* Rows the user *belongs to* but cannot use here - a workspace outside the
|
|
39
|
+
* application's audience, or one with no subscription - are shown **disabled
|
|
40
|
+
* with the reason** rather than hidden. Hiding them reads as data loss to the
|
|
41
|
+
* person who owns the workspace; `switch` refuses the same two cases, so the
|
|
42
|
+
* label and the outcome always agree.
|
|
43
|
+
*
|
|
44
|
+
* A switch rotates the session token. The bridge persists the new one in the
|
|
45
|
+
* host application's own session store and the token never reaches this
|
|
46
|
+
* component - so the only thing to do afterwards is reload, which is what
|
|
47
|
+
* `onSwitched` defaults to.
|
|
48
|
+
*/
|
|
49
|
+
export declare function ConnectWorkspaceSwitcher({ onSwitched, row, className, }: Readonly<ConnectWorkspaceSwitcherProps>): import("react").JSX.Element | null;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import type { ReactNode } from "react";
|
|
2
|
+
import type { WorkspaceType } from "../../types.js";
|
|
3
|
+
export interface ConnectWorkspaceTypeGateProps {
|
|
4
|
+
/**
|
|
5
|
+
* The workspace type this subtree is for. Pass an array to accept either -
|
|
6
|
+
* which is the same as not using the gate at all, so it exists only to keep
|
|
7
|
+
* a `type={someVariable}` call site from having to special-case "both".
|
|
8
|
+
*/
|
|
9
|
+
type: WorkspaceType | WorkspaceType[];
|
|
10
|
+
children: ReactNode;
|
|
11
|
+
/**
|
|
12
|
+
* Rendered for a workspace of the other type. Defaults to `null` - hiding
|
|
13
|
+
* the subtree, which is what this gate is normally for.
|
|
14
|
+
*/
|
|
15
|
+
fallback?: ReactNode;
|
|
16
|
+
/** Shown until the session read settles. Defaults to nothing. */
|
|
17
|
+
loading?: ReactNode;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Renders `children` only for a workspace of the given type.
|
|
21
|
+
*
|
|
22
|
+
* ```tsx
|
|
23
|
+
* <ConnectWorkspaceTypeGate type="business">
|
|
24
|
+
* <TeamMembersTable />
|
|
25
|
+
* </ConnectWorkspaceTypeGate>
|
|
26
|
+
* ```
|
|
27
|
+
*
|
|
28
|
+
* The point is dead controls, not access: an `"individual"` workspace has
|
|
29
|
+
* exactly one seat and can never have another, so a members table, an invite
|
|
30
|
+
* button and a seat meter are all things that can only ever fail there.
|
|
31
|
+
* Hiding them is a better answer than letting someone press one and read an
|
|
32
|
+
* error about an account shape they did not choose.
|
|
33
|
+
*
|
|
34
|
+
* This is emphatically **not** the audience gate. It does not know what your
|
|
35
|
+
* application is sold to and will happily render a business-only subtree to a
|
|
36
|
+
* business workspace that has no business being in your application at all -
|
|
37
|
+
* that is `<ConnectAccessGate>`'s job, off the `audience_mismatch` readiness
|
|
38
|
+
* blocker. Use this one *inside* an application both audiences can reach, to
|
|
39
|
+
* vary what each sees.
|
|
40
|
+
*
|
|
41
|
+
* Like every gate in this package it is a **UX gate, not a security
|
|
42
|
+
* boundary**: the browser can ignore it. Anything that must not happen for an
|
|
43
|
+
* individual workspace has to be refused on your server too.
|
|
44
|
+
*
|
|
45
|
+
* Renders `loading` - not `fallback` - while the session is unknown, so a
|
|
46
|
+
* business account never flickers through the individual-account layout.
|
|
47
|
+
*/
|
|
48
|
+
export declare function ConnectWorkspaceTypeGate({ type, children, fallback, loading, }: ConnectWorkspaceTypeGateProps): import("react").JSX.Element;
|
|
@@ -10,30 +10,44 @@
|
|
|
10
10
|
* whatever theme the host application platform already configured, and one theme
|
|
11
11
|
* change lands identically in all of them.
|
|
12
12
|
*/
|
|
13
|
-
export { ConnectProvider, useConnect, useConnectUser, useConnectEntitlements, useConnectPlans, useConnectApps, useConnectAddonUsage, useConnectSessions, useConnectIntegrations, useConnectResource, CONNECT_APP_URL, } from "./provider.js";
|
|
13
|
+
export { ConnectProvider, useConnect, useConnectUser, useConnectWorkspaceType, useConnectAudience, useConnectPlatformAccess, useConnectEntitlements, useConnectPlans, useConnectApps, useConnectCompanyProfile, useConnectAddonUsage, useConnectSessions, useConnectIntegrations, useConnectResource, CONNECT_APP_URL, } from "./provider.js";
|
|
14
14
|
export type { ConnectProviderProps, ConnectContextValue, ConnectSession } from "./provider.js";
|
|
15
15
|
export { blockingBlockers, normalizePlanFeatures } from "../helpers.js";
|
|
16
16
|
export type { WirePlanFeature } from "../helpers.js";
|
|
17
17
|
export { ConnectError, isConnectError } from "../errors.js";
|
|
18
18
|
export type * from "../types.js";
|
|
19
|
+
export { ConnectGrievanceNotice } from "./components/grievance-notice.js";
|
|
20
|
+
export type { ConnectGrievanceNoticeProps } from "./components/grievance-notice.js";
|
|
19
21
|
export { ConnectMark } from "./mark.js";
|
|
20
22
|
export { ConnectLogo } from "./components/logo.js";
|
|
21
23
|
export type { ConnectLogoProps } from "./components/logo.js";
|
|
22
24
|
export { ConnectLoginButton, ConnectRegisterButton } from "./components/auth-buttons.js";
|
|
23
25
|
export type { ConnectAuthButtonProps } from "./components/auth-buttons.js";
|
|
24
|
-
export {
|
|
26
|
+
export { ConnectUserButton, ConnectProfileModal,
|
|
27
|
+
/** @deprecated Renamed to `ConnectUserButton`. */
|
|
28
|
+
ConnectUserMenu, ConnectManageSubscriptionButton, ConnectInvoicesButton, ConnectProfileButton, ConnectHomeButton, ConnectSignOutButton, } from "./components/user-menu.js";
|
|
29
|
+
export type { ConnectUserButtonProps, ConnectProfileModalProps } from "./components/user-menu.js";
|
|
25
30
|
export { ConnectAccountSessions } from "./components/account-sessions.js";
|
|
26
31
|
export type { ConnectAccountSessionsProps } from "./components/account-sessions.js";
|
|
27
32
|
export type { ConnectUserMenuProps } from "./components/user-menu.js";
|
|
28
|
-
export {
|
|
29
|
-
export type {
|
|
30
|
-
export {
|
|
31
|
-
export type {
|
|
33
|
+
export { AppShell } from "./components/app-shell.js";
|
|
34
|
+
export type { AppShellProps } from "./components/app-shell.js";
|
|
35
|
+
export { ConnectSidebar, ConnectSidebarHeader, ConnectSidebarBody, ConnectSidebarFooter, ConnectSidebarRow, } from "./components/sidebar.js";
|
|
36
|
+
export type { ConnectSidebarProps, ConnectSidebarHeaderProps, ConnectSidebarRowProps, } from "./components/sidebar.js";
|
|
37
|
+
export { ConnectShellProvider, useConnectShell, sidebarRowClass, RAIL_COLLAPSED, RAIL_EXPANDED, } from "./components/shell-context.js";
|
|
38
|
+
export type { ConnectShellContextValue } from "./components/shell-context.js";
|
|
39
|
+
export { ConnectSidebarNav, ConnectSideNav } from "./components/side-nav.js";
|
|
40
|
+
export type { ConnectSidebarNavProps, ConnectSideNavProps } from "./components/side-nav.js";
|
|
32
41
|
export { useActivePath } from "./use-active-path.js";
|
|
33
|
-
export { normalizeNav, flattenNav, normalizePath, resolveActivePath, isNavItemActive, gateExemptPaths, } from "./components/nav.js";
|
|
42
|
+
export { normalizeNav, flattenNav, normalizePath, resolveActivePath, isNavItemActive, gateExemptPaths, filterNavForAudience, } from "./components/nav.js";
|
|
34
43
|
export type { ConnectNav, ConnectNavItem, ConnectNavSection, ConnectNavLinkProps, ConnectLinkRenderer, } from "./components/nav.js";
|
|
35
44
|
export { ConnectAppsGrid } from "./components/apps-grid.js";
|
|
36
45
|
export type { ConnectAppsGridProps } from "./components/apps-grid.js";
|
|
46
|
+
export { ConnectAskAi } from "./components/ask-ai.js";
|
|
47
|
+
export type { ConnectAskAiProps } from "./components/ask-ai.js";
|
|
48
|
+
export { AiTable, AiChart, AiMetrics, AiTimeline, AiDetails, AiSteps, AiSources, } from "./components/ai-widgets.js";
|
|
49
|
+
export { formatAiValue, isNumericAiFormat, aiStatusTone, AI_EMPTY_VALUE, AI_TONE_CHIP, AI_TONE_DOT, } from "./components/ai-format.js";
|
|
50
|
+
export type { AiStatusTone } from "./components/ai-format.js";
|
|
37
51
|
export { ConnectIntegrationsModal } from "./components/integrations-modal.js";
|
|
38
52
|
export type { ConnectIntegrationsModalProps } from "./components/integrations-modal.js";
|
|
39
53
|
export { ConnectPlans } from "./components/plans.js";
|
|
@@ -48,11 +62,26 @@ export { ConnectAccessGate, useConnectAccessGate } from "./components/access-gat
|
|
|
48
62
|
export type { ConnectAccessGateProps, ConnectAccessGateState, ConnectAccessGateResult, } from "./components/access-gate.js";
|
|
49
63
|
export { ConnectFeatureGate, useConnectFeature } from "./components/feature-gate.js";
|
|
50
64
|
export type { ConnectFeatureGateProps } from "./components/feature-gate.js";
|
|
65
|
+
export { ConnectWorkspaceTypeGate } from "./components/workspace-type-gate.js";
|
|
66
|
+
export type { ConnectWorkspaceTypeGateProps } from "./components/workspace-type-gate.js";
|
|
67
|
+
export { ConnectPlatformGate } from "./components/platform-gate.js";
|
|
68
|
+
export type { ConnectPlatformGateProps } from "./components/platform-gate.js";
|
|
51
69
|
export { ConnectUsageMeter } from "./components/usage-meter.js";
|
|
52
70
|
export type { ConnectUsageMeterProps } from "./components/usage-meter.js";
|
|
53
71
|
export { ConnectPlansPage } from "./components/plans-page.js";
|
|
54
72
|
export type { ConnectPlansPageProps } from "./components/plans-page.js";
|
|
73
|
+
export { ConnectLinkButton } from "./components/link-button.js";
|
|
74
|
+
export type { ConnectLinkButtonProps } from "./components/link-button.js";
|
|
75
|
+
export { ConnectConfirmDialog } from "./components/confirm-dialog.js";
|
|
76
|
+
export type { ConnectConfirmDialogProps } from "./components/confirm-dialog.js";
|
|
77
|
+
export { ConnectCursorPagination } from "./components/cursor-pagination.js";
|
|
78
|
+
export type { ConnectCursorPaginationProps } from "./components/cursor-pagination.js";
|
|
79
|
+
export { ConnectFilterTabs } from "./components/filter-tabs.js";
|
|
80
|
+
export type { ConnectFilterTabsProps, ConnectFilterTabsOption } from "./components/filter-tabs.js";
|
|
55
81
|
export { useConnectCheckout, buildCheckoutUrl } from "./use-checkout.js";
|
|
56
82
|
export type { ConnectCheckoutStatus, ConnectCheckoutState, ConnectEntitlements, StartCheckoutOptions, CheckoutUrlOptions, } from "./use-checkout.js";
|
|
57
83
|
export { formatPrice, monthlyOf, resolveAction, annualSaving, discountLabel, ACTION_LABEL, groupPlansByTier, resolvePlanGroup, } from "./components/plan-pricing.js";
|
|
58
84
|
export type { PlanAction, PlanTier, ComparablePlan } from "./components/plan-pricing.js";
|
|
85
|
+
export { ConnectWorkspaceSwitcher } from "./components/workspace-switcher.js";
|
|
86
|
+
export type { ConnectWorkspaceSwitcherProps } from "./components/workspace-switcher.js";
|
|
87
|
+
export { useConnectWorkspaces, useConnectWorkspaceMembers } from "./provider.js";
|