@sixb/app 0.1.4 → 0.1.6

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
@@ -34,9 +34,9 @@ Two functions generate the entry point files into `.sixb/generated/`:
34
34
  - **`generateRouteManifest(routes, generatedDir)`** -- writes `routes.ts` with static page and
35
35
  layout imports plus native nested `RouteObject` entries. Routes are eager on purpose: project
36
36
  apps bundle small, and a single bundle means no loading gap when navigating between pages.
37
- - **`generateAppEntry(projectRoot, generatedDir, options)`** -- writes `index.html` (HTML shell), `main.tsx` (React entry with BrowserRouter, TanStack Query, and the `@sixb/client` SDK), and `app.webmanifest`.
37
+ - **`generateAppEntry(projectRoot, generatedDir, options)`** -- writes the ordinary and shared HTML bootstraps, their entry points, one common React route tree, and `app.webmanifest`.
38
38
 
39
- The generated entry also intercepts plain same-origin `<a href="/...">` clicks and routes them client-side, so internal links work like react-router's `<Link>` without authors having to remember it. The interceptor is conservative — modified clicks, `target`/`download`/`rel="external"` anchors, cross-origin URLs, reserved Sixb paths (`/api`, `/auth`, `/ws`, `/docs`), and destinations that don't match an app route all keep native browser navigation. `<Link>` remains the idiomatic choice in app code.
39
+ The generated entry also intercepts plain same-origin `<a href="/...">` clicks and routes them client-side, so internal links work like react-router's `<Link>` without authors having to remember it. The interceptor is conservative — modified clicks, `target`/`download`/`rel="external"` anchors, cross-origin URLs, reserved Sixb paths (`/api`, `/auth`, `/ws`, `/docs`, `/shared`), and destinations that don't match an app route all keep native browser navigation. `<Link>` remains the idiomatic choice in app code.
40
40
 
41
41
  If `app/layout.tsx` exists, it is the global wrapper outside the route tree. It can also export a
42
42
  `metadata` object (`title`, `description`, `favicon`, `themeColor`, and `backgroundColor`). Metadata
@@ -50,6 +50,19 @@ React Router hooks such as `useParams`, and stays mounted while navigation remai
50
50
  subtree. Descendant layout metadata is not read. A layout with no project or framework page below
51
51
  it creates no route and is not bundled.
52
52
 
53
+ ### Shared links
54
+
55
+ `/shared/:grantId/...` reuses ordinary pages, layouts, query hooks, and Action mutations. Sixb
56
+ removes the URL secret and establishes an isolated session before loading app code or styles.
57
+ `app/shared` is reserved; no separate pages or data hooks are needed.
58
+
59
+ - Each request is restricted to the Share grant's selected objects, properties, link paths, and Actions.
60
+ - V1 excludes WebSockets, uploads, direct object/link/telemetry writes, and Action-run listing or files.
61
+ - Open shared URLs with native `<a href={url}>` links, not programmatic SPA navigation.
62
+ - Shared pages are not indexable or installable as a PWA.
63
+ - In development, shared pages build on demand and require a browser reload after edits; ordinary
64
+ pages retain HMR.
65
+
53
66
  Add an optional `app/auth.tsx` default export to customize the app audience's magic-link pages. It receives `AuthExperienceProps` from `@sixb/app/auth` with `signIn`, `checkEmail`, `confirm`, `invalidLink`, and `error` states plus framework-owned actions. Sixb builds it separately, includes `app/globals.css`, and serves it from the API's existing `/auth/*` routes. It is not wrapped by `app/layout.tsx`, and it never owns tokens, cookies, callbacks, audience validation, or return redirects. When the file is absent, the generic server login remains the fallback.
54
67
 
55
68
  ### Built-in Agent Routes
@@ -89,6 +102,15 @@ export default function AgentsLayout({ children }: PropsWithChildren) {
89
102
  Explicit props passed to a project-owned `AgentsPage` override provider defaults. The custom width
90
103
  applies to the persistent desktop rail; the mobile sheet keeps its responsive width.
91
104
 
105
+ The provider also accepts `documentPreviewRenderers`. Applications can register document viewers
106
+ without coupling `@sixb/app` or `@sixb/agent-ui` to their implementation.
107
+
108
+ ```tsx
109
+ <AgentWorkspaceProvider documentPreviewRenderers={[workbookPreviewRenderer]}>
110
+ {children}
111
+ </AgentWorkspaceProvider>
112
+ ```
113
+
92
114
  ### Embedded Agent Panel
93
115
 
94
116
  Embed the same conversation runtime without changing the page route:
@@ -111,7 +133,7 @@ function Layout() {
111
133
  <AgentContextProvider>
112
134
  <main><InvoicePage invoiceId="inv-123" /></main>
113
135
  <aside className="h-[42rem]">
114
- <AgentPanel agentId="invoice-assistant" />
136
+ <AgentPanel />
115
137
  </aside>
116
138
  </AgentContextProvider>
117
139
  )
@@ -128,7 +150,7 @@ const view = agentContext.appState("invoice-view", {
128
150
  value: { activeTab, filters },
129
151
  })
130
152
 
131
- <AgentPanel agentId="invoice-assistant" context={[view]} />
153
+ <AgentPanel context={[view]} />
132
154
  ```
133
155
 
134
156
  Context is visible and removable before send, then stored on that user message. `@` adds authorized
@@ -160,6 +182,10 @@ Tailwind's source detection is scoped to `app/`, and the CLI is resolved from th
160
182
 
161
183
  `createCustomApp().start(options)` serves the built app from `.sixb/dist/app/` on a Bun server. When `apiBaseUrl` is provided, it is injected into the served HTML at runtime so the public custom app shell can call the Sixb API origin with credentials.
162
184
 
185
+ Shared links require the built-in server in V1; static SPA fallbacks and external hosting adapters
186
+ are unsupported. It serves the isolated shell with a fresh CSP nonce, `no-store`, `no-referrer`,
187
+ and no eager asset loading. App and API must be same-site (`SameSite=Strict` cookies).
188
+
163
189
  ## Usage
164
190
 
165
191
  Preferred high-level API:
package/dist/agents.d.ts CHANGED
@@ -1,11 +1,11 @@
1
1
  import { type AgentChatPageProps } from "@sixb/agent-ui/react-router";
2
2
  import { type PropsWithChildren } from "react";
3
- export { AgentContextProvider, AgentPanel, type AgentPanelProps, useAgentContext, } from "@sixb/agent-ui";
3
+ export { AgentContextProvider, type AgentDocumentPreviewRenderer, type AgentDocumentPreviewRendererProps, type AgentFileRef, AgentPanel, type AgentPanelProps, useAgentContext, } from "@sixb/agent-ui";
4
4
  export { agentContext } from "@sixb/core/agents/context";
5
5
  export type AgentsPageProps = Omit<AgentChatPageProps, "routeBase">;
6
- type AgentWorkspaceChrome = Pick<AgentsPageProps, "sidebarHeader" | "sidebarFooter" | "sidebarWidth">;
7
- export type AgentWorkspaceProviderProps = PropsWithChildren<AgentWorkspaceChrome>;
6
+ type AgentWorkspaceConfiguration = Pick<AgentsPageProps, "sidebarHeader" | "sidebarFooter" | "sidebarWidth" | "documentPreviewRenderers">;
7
+ export type AgentWorkspaceProviderProps = PropsWithChildren<AgentWorkspaceConfiguration>;
8
8
  /** Configure the framework-owned Agents routes, typically from `app/agents/layout.tsx`. */
9
- export declare function AgentWorkspaceProvider({ sidebarHeader, sidebarFooter, sidebarWidth, children, }: AgentWorkspaceProviderProps): import("react").FunctionComponentElement<import("react").ProviderProps<AgentWorkspaceChrome>>;
9
+ export declare function AgentWorkspaceProvider({ sidebarHeader, sidebarFooter, sidebarWidth, documentPreviewRenderers, children, }: AgentWorkspaceProviderProps): import("react").FunctionComponentElement<import("react").ProviderProps<AgentWorkspaceConfiguration>>;
10
10
  export default function AgentsPage(props: AgentsPageProps): import("react").FunctionComponentElement<AgentChatPageProps>;
11
11
  //# sourceMappingURL=agents.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"agents.d.ts","sourceRoot":"","sources":["../src/agents.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiB,KAAK,kBAAkB,EAAE,MAAM,6BAA6B,CAAA;AACpF,OAAO,EAAgC,KAAK,iBAAiB,EAAc,MAAM,OAAO,CAAA;AAExF,OAAO,EACL,oBAAoB,EACpB,UAAU,EACV,KAAK,eAAe,EACpB,eAAe,GAChB,MAAM,gBAAgB,CAAA;AAEvB,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAA;AAExD,MAAM,MAAM,eAAe,GAAG,IAAI,CAAC,kBAAkB,EAAE,WAAW,CAAC,CAAA;AAEnE,KAAK,oBAAoB,GAAG,IAAI,CAC9B,eAAe,EACf,eAAe,GAAG,eAAe,GAAG,cAAc,CACnD,CAAA;AAED,MAAM,MAAM,2BAA2B,GAAG,iBAAiB,CAAC,oBAAoB,CAAC,CAAA;AAIjF,2FAA2F;AAC3F,wBAAgB,sBAAsB,CAAC,EACrC,aAAa,EACb,aAAa,EACb,YAAY,EACZ,QAAQ,GACT,EAAE,2BAA2B,iGAM7B;AAED,MAAM,CAAC,OAAO,UAAU,UAAU,CAAC,KAAK,EAAE,eAAe,gEAQxD"}
1
+ {"version":3,"file":"agents.d.ts","sourceRoot":"","sources":["../src/agents.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiB,KAAK,kBAAkB,EAAE,MAAM,6BAA6B,CAAA;AACpF,OAAO,EAAgC,KAAK,iBAAiB,EAAc,MAAM,OAAO,CAAA;AAExF,OAAO,EACL,oBAAoB,EACpB,KAAK,4BAA4B,EACjC,KAAK,iCAAiC,EACtC,KAAK,YAAY,EACjB,UAAU,EACV,KAAK,eAAe,EACpB,eAAe,GAChB,MAAM,gBAAgB,CAAA;AAEvB,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAA;AAExD,MAAM,MAAM,eAAe,GAAG,IAAI,CAAC,kBAAkB,EAAE,WAAW,CAAC,CAAA;AAEnE,KAAK,2BAA2B,GAAG,IAAI,CACrC,eAAe,EACf,eAAe,GAAG,eAAe,GAAG,cAAc,GAAG,0BAA0B,CAChF,CAAA;AAED,MAAM,MAAM,2BAA2B,GAAG,iBAAiB,CAAC,2BAA2B,CAAC,CAAA;AAIxF,2FAA2F;AAC3F,wBAAgB,sBAAsB,CAAC,EACrC,aAAa,EACb,aAAa,EACb,YAAY,EACZ,wBAAwB,EACxB,QAAQ,GACT,EAAE,2BAA2B,wGAM7B;AAED,MAAM,CAAC,OAAO,UAAU,UAAU,CAAC,KAAK,EAAE,eAAe,gEAQxD"}
package/dist/agents.js CHANGED
@@ -13,14 +13,15 @@ function AgentWorkspaceProvider({
13
13
  sidebarHeader,
14
14
  sidebarFooter,
15
15
  sidebarWidth,
16
+ documentPreviewRenderers,
16
17
  children
17
18
  }) {
18
- return createElement(AgentWorkspaceContext.Provider, { value: { sidebarHeader, sidebarFooter, sidebarWidth } }, children);
19
+ return createElement(AgentWorkspaceContext.Provider, { value: { sidebarHeader, sidebarFooter, sidebarWidth, documentPreviewRenderers } }, children);
19
20
  }
20
21
  function AgentsPage(props) {
21
- const workspaceChrome = useContext(AgentWorkspaceContext);
22
+ const workspaceConfiguration = useContext(AgentWorkspaceContext);
22
23
  return createElement(AgentChatPage, {
23
- ...workspaceChrome,
24
+ ...workspaceConfiguration,
24
25
  ...props,
25
26
  routeBase: "/agents"
26
27
  });
@@ -34,4 +35,4 @@ export {
34
35
  AgentContextProvider
35
36
  };
36
37
 
37
- //# debugId=FD2DDDBFD9CFF84864756E2164756E21
38
+ //# debugId=424CA12B96B1880764756E2164756E21
@@ -2,9 +2,9 @@
2
2
  "version": 3,
3
3
  "sources": ["../src/agents.ts"],
4
4
  "sourcesContent": [
5
- "import { AgentChatPage, type AgentChatPageProps } from \"@sixb/agent-ui/react-router\"\nimport { createContext, createElement, type PropsWithChildren, useContext } from \"react\"\n\nexport {\n AgentContextProvider,\n AgentPanel,\n type AgentPanelProps,\n useAgentContext,\n} from \"@sixb/agent-ui\"\n\nexport { agentContext } from \"@sixb/core/agents/context\"\n\nexport type AgentsPageProps = Omit<AgentChatPageProps, \"routeBase\">\n\ntype AgentWorkspaceChrome = Pick<\n AgentsPageProps,\n \"sidebarHeader\" | \"sidebarFooter\" | \"sidebarWidth\"\n>\n\nexport type AgentWorkspaceProviderProps = PropsWithChildren<AgentWorkspaceChrome>\n\nconst AgentWorkspaceContext = createContext<AgentWorkspaceChrome>({})\n\n/** Configure the framework-owned Agents routes, typically from `app/agents/layout.tsx`. */\nexport function AgentWorkspaceProvider({\n sidebarHeader,\n sidebarFooter,\n sidebarWidth,\n children,\n}: AgentWorkspaceProviderProps) {\n return createElement(\n AgentWorkspaceContext.Provider,\n { value: { sidebarHeader, sidebarFooter, sidebarWidth } },\n children\n )\n}\n\nexport default function AgentsPage(props: AgentsPageProps) {\n const workspaceChrome = useContext(AgentWorkspaceContext)\n\n return createElement(AgentChatPage, {\n ...workspaceChrome,\n ...props,\n routeBase: \"/agents\",\n })\n}\n"
5
+ "import { AgentChatPage, type AgentChatPageProps } from \"@sixb/agent-ui/react-router\"\nimport { createContext, createElement, type PropsWithChildren, useContext } from \"react\"\n\nexport {\n AgentContextProvider,\n type AgentDocumentPreviewRenderer,\n type AgentDocumentPreviewRendererProps,\n type AgentFileRef,\n AgentPanel,\n type AgentPanelProps,\n useAgentContext,\n} from \"@sixb/agent-ui\"\n\nexport { agentContext } from \"@sixb/core/agents/context\"\n\nexport type AgentsPageProps = Omit<AgentChatPageProps, \"routeBase\">\n\ntype AgentWorkspaceConfiguration = Pick<\n AgentsPageProps,\n \"sidebarHeader\" | \"sidebarFooter\" | \"sidebarWidth\" | \"documentPreviewRenderers\"\n>\n\nexport type AgentWorkspaceProviderProps = PropsWithChildren<AgentWorkspaceConfiguration>\n\nconst AgentWorkspaceContext = createContext<AgentWorkspaceConfiguration>({})\n\n/** Configure the framework-owned Agents routes, typically from `app/agents/layout.tsx`. */\nexport function AgentWorkspaceProvider({\n sidebarHeader,\n sidebarFooter,\n sidebarWidth,\n documentPreviewRenderers,\n children,\n}: AgentWorkspaceProviderProps) {\n return createElement(\n AgentWorkspaceContext.Provider,\n { value: { sidebarHeader, sidebarFooter, sidebarWidth, documentPreviewRenderers } },\n children\n )\n}\n\nexport default function AgentsPage(props: AgentsPageProps) {\n const workspaceConfiguration = useContext(AgentWorkspaceContext)\n\n return createElement(AgentChatPage, {\n ...workspaceConfiguration,\n ...props,\n routeBase: \"/agents\",\n })\n}\n"
6
6
  ],
7
- "mappings": ";;AAAA;AACA;AAEA;AAAA;AAAA;AAAA;AAAA;AAOA;AAWA,IAAM,wBAAwB,cAAoC,CAAC,CAAC;AAG7D,SAAS,sBAAsB;AAAA,EACpC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,GAC8B;AAAA,EAC9B,OAAO,cACL,sBAAsB,UACtB,EAAE,OAAO,EAAE,eAAe,eAAe,aAAa,EAAE,GACxD,QACF;AAAA;AAGF,SAAwB,UAAU,CAAC,OAAwB;AAAA,EACzD,MAAM,kBAAkB,WAAW,qBAAqB;AAAA,EAExD,OAAO,cAAc,eAAe;AAAA,OAC/B;AAAA,OACA;AAAA,IACH,WAAW;AAAA,EACb,CAAC;AAAA;",
8
- "debugId": "FD2DDDBFD9CFF84864756E2164756E21",
7
+ "mappings": ";;AAAA;AACA;AAEA;AAAA;AAAA;AAAA;AAAA;AAUA;AAWA,IAAM,wBAAwB,cAA2C,CAAC,CAAC;AAGpE,SAAS,sBAAsB;AAAA,EACpC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,GAC8B;AAAA,EAC9B,OAAO,cACL,sBAAsB,UACtB,EAAE,OAAO,EAAE,eAAe,eAAe,cAAc,yBAAyB,EAAE,GAClF,QACF;AAAA;AAGF,SAAwB,UAAU,CAAC,OAAwB;AAAA,EACzD,MAAM,yBAAyB,WAAW,qBAAqB;AAAA,EAE/D,OAAO,cAAc,eAAe;AAAA,OAC/B;AAAA,OACA;AAAA,IACH,WAAW;AAAA,EACb,CAAC;AAAA;",
8
+ "debugId": "424CA12B96B1880764756E2164756E21",
9
9
  "names": []
10
10
  }
package/dist/build.d.ts CHANGED
@@ -1,8 +1,13 @@
1
+ export declare const SHARED_APP_SHELL_FILE_NAME = "shared-index.html";
1
2
  export interface BuildAppOptions {
2
3
  /** Path to the generated index.html entry point */
3
4
  entryPath: string;
4
5
  /** Browser TypeScript entry generated alongside `entryPath`. */
5
6
  scriptEntryPath: string;
7
+ /** Isolated shared-link HTML shell. Must be paired with `sharedScriptEntryPath`. */
8
+ sharedEntryPath?: string;
9
+ /** Browser TypeScript entry loaded by the shared-link shell. */
10
+ sharedScriptEntryPath?: string;
6
11
  /** Generated manifest copied to the stable `/app.webmanifest` output path. */
7
12
  manifestPath?: string;
8
13
  /** Output directory, defaults to `.sixb/dist/app` */
@@ -13,6 +18,10 @@ export interface BuildAppResult {
13
18
  outdir: string;
14
19
  logs?: string[];
15
20
  }
21
+ export interface BuildSharedAppDevResult {
22
+ readonly assetPaths: readonly string[];
23
+ readonly html: string;
24
+ }
16
25
  export interface BuildAuthExperienceOptions {
17
26
  /** Generated HTML shell containing the auth bootstrap placeholder. */
18
27
  entryPath: string;
@@ -25,6 +34,16 @@ export interface BuildAuthExperienceOptions {
25
34
  * Builds the generated browser entry and writes a production-ready static shell and bundle.
26
35
  */
27
36
  export declare function buildApp(options: BuildAppOptions): Promise<BuildAppResult>;
37
+ /**
38
+ * Builds the shared shell like production for development, without Bun's HTML/HMR transform.
39
+ * Bun 1.3 injects a script before an inline loader, which would execute application code while the
40
+ * share secret is still in the document URL. The ordinary app keeps HTML-bundle HMR.
41
+ */
42
+ export declare function buildSharedAppDev(options: {
43
+ readonly entryPath: string;
44
+ readonly outdir: string;
45
+ readonly scriptEntryPath: string;
46
+ }): Promise<BuildSharedAppDevResult>;
28
47
  /** Builds the optional custom auth entry as API-served static assets. */
29
48
  export declare function buildAuthExperience(options: BuildAuthExperienceOptions): Promise<BuildAppResult>;
30
49
  export declare function prepareAppHtmlBundleEntry(entryPath: string): Promise<string>;
@@ -1 +1 @@
1
- {"version":3,"file":"build.d.ts","sourceRoot":"","sources":["../src/build.ts"],"names":[],"mappings":"AAeA,MAAM,WAAW,eAAe;IAC9B,mDAAmD;IACnD,SAAS,EAAE,MAAM,CAAA;IACjB,gEAAgE;IAChE,eAAe,EAAE,MAAM,CAAA;IACvB,8EAA8E;IAC9E,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,qDAAqD;IACrD,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB;AAED,MAAM,WAAW,cAAc;IAC7B,OAAO,EAAE,OAAO,CAAA;IAChB,MAAM,EAAE,MAAM,CAAA;IACd,IAAI,CAAC,EAAE,MAAM,EAAE,CAAA;CAChB;AAED,MAAM,WAAW,0BAA0B;IACzC,sEAAsE;IACtE,SAAS,EAAE,MAAM,CAAA;IACjB,gEAAgE;IAChE,eAAe,EAAE,MAAM,CAAA;IACvB,mEAAmE;IACnE,MAAM,EAAE,MAAM,CAAA;CACf;AAED;;GAEG;AACH,wBAAsB,QAAQ,CAAC,OAAO,EAAE,eAAe,GAAG,OAAO,CAAC,cAAc,CAAC,CA2EhF;AAED,yEAAyE;AACzE,wBAAsB,mBAAmB,CACvC,OAAO,EAAE,0BAA0B,GAClC,OAAO,CAAC,cA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Q,CAAC,MAAM,EAAE,MAAM,CAAA;IACvB,QAAQ,CAAC,eAAe,EAAE,MAAM,CAAA;CACjC,GAAG,OAAO,CAAC,uBAAuB,CAAC,CAuBnC;AAoGD,yEAAyE;AACzE,wBAAsB,mBAAmB,CACvC,OAAO,EAAE,0BAA0B,GAClC,OAAO,CAAC,cAAc,CAAC,CA+DzB;AAKD,wBAAsB,yBAAyB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAUlF;AAED,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAEzD"}
package/dist/codegen.d.ts CHANGED
@@ -28,8 +28,11 @@ export declare function generateAuthExperienceEntry(projectRoot: string, generat
28
28
  } | null>;
29
29
  /**
30
30
  * Generates the app entry files:
31
- * - `.sixb/generated/index.html` — HTML shell
32
- * - `.sixb/generated/main.tsx` — React entry with BrowserRouter
31
+ * - `.sixb/generated/index.html` — ordinary authenticated HTML shell
32
+ * - `.sixb/generated/main.tsx` — ordinary authentication bootstrap
33
+ * - `.sixb/generated/app-runtime.tsx` — shared route, layout, and query runtime
34
+ * - `.sixb/generated/shared-index.html` — isolated shared-link HTML shell
35
+ * - `.sixb/generated/shared-main.tsx` — delegated-session bootstrap
33
36
  * - `.sixb/generated/app.webmanifest` — installable app identity
34
37
  */
35
38
  export declare function generateAppEntry(projectRoot: string, generatedDir: string, options?: {
@@ -50,5 +53,8 @@ export declare function generateAppEntry(projectRoot: string, generatedDir: stri
50
53
  htmlPath: string;
51
54
  mainPath: string;
52
55
  manifestPath: string;
56
+ runtimePath: string;
57
+ sharedHtmlPath: string;
58
+ sharedMainPath: string;
53
59
  }>;
54
60
  //# sourceMappingURL=codegen.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"codegen.d.ts","sourceRoot":"","sources":["../src/codegen.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAA;AAIrD,OAAO,EAA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,CAAA;IACb,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,QAAQ,CAAC,EAAE,mBAAmB,CAAA;IAC9B,WAAW,CAAC,EAAE,OAAO,CAAA;CACtB;AAED,MAAM,WAAW,kBAAkB;IACjC,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,MAAM,CAAA;IACZ,GAAG,EAAE,MAAM,CAAA;IACX,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC,CAAA;CACtB;AAED,MAAM,WAAW,iBAAiB;IAChC,UAAU,IAAI,OAAO,CAAC,SAAS,EAAE,CAAC,CAAA;IAClC,SAAS,IAAI,OAAO,CAAC,OAAO,CAAC,CAAA;IAC7B,qBAAqB,CACnB,OAAO,CAAC,EAAE,gCAAgC,GACzC,OAAO,CAAC,+BAA+B,GAAG,IAAI,CAAC,CAAA;IAClD,GAAG,CAAC,OAAO,CAAC,EAAE,mBAAmB,GAAG,OAAO,CAAC,kBAAkB,CAAC,CAAA;IAC/D,KAAK,CAAC,OAAO,CAAC,EAAE,qBAAqB,GAAG,OAAO,CAAC,cAAc,CAAC,CAAA;IAC/D,KAAK,CAAC,OAAO,CAAC,EAAE,qBAAqB,GAAG,OAAO,CAAC,kBAAkB,CAAC,CAAA;CACpE;AAYD,wBAAsB,eAAe,CAAC,OAAO,EAAE,sBAAsB,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAuhBjG"}
@@ -0,0 +1,3 @@
1
+ /** Served only by development browser servers; the CLI marks a generation ready last. */
2
+ export declare function devReloadResponse(request: Request): Response;
3
+ //# sourceMappingURL=dev-reload.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dev-reload.d.ts","sourceRoot":"","sources":["../src/dev-reload.ts"],"names":[],"mappings":"AAAA,yFAAyF;AACzF,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,OAAO,GAAG,QAAQ,CAoD5D"}
package/dist/index.d.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  export { type CreateCustomAppOptions, type CustomAppBuildOptions, type CustomAppDevOptions, type CustomAppDevServer, type CustomAppInstance, type CustomAppStartOptions, type CustomAuthExperienceBuildOptions, type CustomAuthExperienceBuildResult, createCustomApp, } from "./createCustomApp";
2
+ export { devReloadResponse } from "./dev-reload";
2
3
  export type { AppMetadata } from "./metadata";
3
4
  export { createTailwindCssCompiler, type TailwindCssCompiler, type TailwindCssCompilerOptions, } from "./tailwind";
4
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,sBAAsB,EAC3B,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,qBAAqB,EAC1B,KAAK,gCAAgC,EACrC,KAAK,+BAA+B,EACpC,eAAe,GAChB,MAAM,mBAAmB,CAAA;AAC1B,YAAY,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAC7C,OAAO,EACL,yBAAyB,EACzB,KAAK,mBAAmB,EACxB,KAAK,0BAA0B,GAChC,MAAM,YAAY,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,sBAAsB,EAC3B,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,qBAAqB,EAC1B,KAAK,gCAAgC,EACrC,KAAK,+BAA+B,EACpC,eAAe,GAChB,MAAM,mBAAmB,CAAA;AAC1B,OAAO,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAA;AAChD,YAAY,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAC7C,OAAO,EACL,yBAAyB,EACzB,KAAK,mBAAmB,EACxB,KAAK,0BAA0B,GAChC,MAAM,YAAY,CAAA"}