@wacht/jsx 1.0.0-beta.2 → 1.0.0-beta.3

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/README.md CHANGED
@@ -1,11 +1,13 @@
1
- # @wacht/jsx
1
+ <h1 align="center">
2
+ <a href="https://wacht.dev" style="text-decoration:none;">@wacht/jsx</a>
3
+ </h1>
2
4
 
3
- Core React UI/auth package for Wacht.
5
+ <p align="center">Core React primitives for Wacht authentication, session state, organization/workspace context, and product surface hooks.</p>
4
6
 
5
- Use this package directly for framework-agnostic React apps, or through:
6
- - `@wacht/nextjs`
7
- - `@wacht/react-router`
8
- - `@wacht/tanstack-router`
7
+ <p align="center">
8
+ <a href="https://docs.wacht.dev">Documentation</a> |
9
+ <a href="https://www.npmjs.com/package/@wacht/jsx">npm</a>
10
+ </p>
9
11
 
10
12
  ## Install
11
13
 
@@ -13,17 +15,15 @@ Use this package directly for framework-agnostic React apps, or through:
13
15
  pnpm add @wacht/jsx @wacht/types
14
16
  ```
15
17
 
16
- ## Basic Setup
18
+ ## Quick start
17
19
 
18
20
  ```tsx
19
- import { DeploymentProvider, SignInForm, SignedIn, SignedOut } from "@wacht/jsx";
21
+ import { DeploymentProvider, SignedIn, SignedOut, SignInForm } from "@wacht/jsx";
20
22
 
21
23
  export function App() {
22
24
  return (
23
- <DeploymentProvider publicKey={process.env.NEXT_PUBLIC_WACHT_PUBLISHABLE_KEY!}>
24
- <SignedIn>
25
- <div>Signed in</div>
26
- </SignedIn>
25
+ <DeploymentProvider publicKey={import.meta.env.VITE_WACHT_PUBLISHABLE_KEY}>
26
+ <SignedIn>Signed in</SignedIn>
27
27
  <SignedOut>
28
28
  <SignInForm />
29
29
  </SignedOut>
@@ -32,14 +32,33 @@ export function App() {
32
32
  }
33
33
  ```
34
34
 
35
- ## Includes
35
+ ## Main exports
36
36
 
37
- - Components: `SignInForm`, `SignUpForm`, `UserButton`, `SignedIn`, `SignedOut`, etc.
38
- - Hooks: `useUser`, `useSession`, `useDeployment`, `useSignIn`, `useSignUp`, etc.
39
- - Permission helpers: `hasOrgPermission`, `hasWorkspacePermission`, `isOrgAdmin`, `isWorkspaceAdmin`
37
+ Components:
40
38
 
41
- For router-aware navigation behavior, use one of the framework adapters instead of raw `@wacht/jsx`.
39
+ - Auth UI: `SignInForm`, `SignUpForm`, `WaitlistForm`, `SSOCallback`, `MagicLinkVerification`
40
+ - Session and navigation: `SignedIn`, `SignedOut`, `SignedInAccounts`, `NavigateToSignIn`
41
+ - User/account: `UserButton`, `UserControls`, `ManageAccount`
42
+ - Notifications: `NotificationBell`, `NotificationPopover`, `NotificationPanel`
43
+
44
+ Hooks:
45
+
46
+ - Auth/session: `useUser`, `useSession`, `useSignIn`, `useSignUp`, `useForgotPassword`
47
+ - Tenancy: `useActiveOrganization`, `useActiveWorkspace`, `useActiveTenancy`
48
+ - Notifications: `useNotifications`, `useNotificationStream`, `useScopeUnread`
49
+ - Agent/webhook/api-auth surfaces: `useAgentSession`, `useWebhookEndpoints`, `useApiAuthKeys`, and related hooks
50
+
51
+ Utilities:
52
+
53
+ - Permission helpers (organization/workspace)
54
+ - URL safety helpers
55
+
56
+ ## Build
57
+
58
+ ```bash
59
+ pnpm build
60
+ ```
42
61
 
43
62
  ## License
44
63
 
45
- Licensed under the Apache License, Version 2.0. See [LICENSE.md](../LICENSE.md).
64
+ Apache License 2.0. See [LICENSE.md](../LICENSE.md).