@upstart.gg/sdk 0.0.129 → 0.0.130

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 (39) hide show
  1. package/dist/shared/chunk-L6WHBSRZ.js +8 -0
  2. package/dist/shared/{chunk-6K3KZDFC.js → chunk-UAQHU6L6.js} +1 -1
  3. package/dist/shared/{chunk-VTBI7WX3.js → chunk-YFFTZ5T6.js} +1 -1
  4. package/dist/shared/context.d.ts +5 -6
  5. package/dist/shared/context.d.ts.map +1 -1
  6. package/dist/shared/datarecords/external/airtable/client.d.ts +8 -0
  7. package/dist/shared/datarecords/external/airtable/client.d.ts.map +1 -0
  8. package/dist/shared/datarecords/external/airtable/handler.d.ts +6 -6
  9. package/dist/shared/datarecords/external/airtable/handler.d.ts.map +1 -1
  10. package/dist/shared/datarecords/external/airtable/handler.js +3 -0
  11. package/dist/shared/datarecords/external/airtable/options.d.ts.map +1 -1
  12. package/dist/shared/datarecords/external/airtable/types.d.ts +15 -0
  13. package/dist/shared/datarecords/external/airtable/types.d.ts.map +1 -0
  14. package/dist/shared/datarecords/external/google/sheets/client.d.ts +14 -0
  15. package/dist/shared/datarecords/external/google/sheets/client.d.ts.map +1 -0
  16. package/dist/shared/datarecords/external/google/sheets/handler.d.ts +4 -6
  17. package/dist/shared/datarecords/external/google/sheets/handler.d.ts.map +1 -1
  18. package/dist/shared/datarecords/external/google/sheets/handler.js +6 -0
  19. package/dist/shared/datarecords/external/notion/client.d.ts +8 -0
  20. package/dist/shared/datarecords/external/notion/client.d.ts.map +1 -0
  21. package/dist/shared/datarecords/external/notion/handler.d.ts +9 -0
  22. package/dist/shared/datarecords/external/notion/handler.d.ts.map +1 -0
  23. package/dist/shared/datarecords/external/notion/handler.js +3 -0
  24. package/dist/shared/datarecords/external/notion/utils.d.ts +5 -0
  25. package/dist/shared/datarecords/external/notion/utils.d.ts.map +1 -0
  26. package/dist/shared/datarecords/types.d.ts +147 -0
  27. package/dist/shared/datarecords/types.d.ts.map +1 -1
  28. package/dist/shared/datarecords/types.js +1 -1
  29. package/dist/shared/page.d.ts +12 -38
  30. package/dist/shared/page.d.ts.map +1 -1
  31. package/dist/shared/page.js +1 -1
  32. package/dist/shared/site.d.ts +112 -13
  33. package/dist/shared/site.d.ts.map +1 -1
  34. package/dist/shared/site.js +1 -1
  35. package/dist/shared/sitemap.d.ts +170 -14
  36. package/dist/shared/sitemap.d.ts.map +1 -1
  37. package/dist/shared/sitemap.js +1 -1
  38. package/package.json +3 -2
  39. package/dist/shared/chunk-C2S243PB.js +0 -8
@@ -0,0 +1,8 @@
1
+ /*! Upstart.gg - Copyright (C) 2024 Flippable - https://github.com/upstart-gg/upstart/blob/main/LICENSE */
2
+
3
+ import{a as i}from"./chunk-YFFTZ5T6.js";import{a as t}from"./chunk-SFKZAUPW.js";import{Type as e}from"@sinclair/typebox";var a=e.Pick(i,["id","label","path","attributes"]),p=e.Array(e.Object({id:e.String({title:"Section ID (slug format)"}),name:e.String({title:"Section name"}),description:e.String({title:"A long description of the section",description:`You must elaborate a clear and detailled plan that describes:
4
+ - The section purpose in the page, in detail.
5
+ - The section structure, look & feel, and structural/design organization, in detail
6
+ - the types of bricks (e.g. "container", "text", "video", "carousel", etc) that will be used and their purpose, in detail
7
+
8
+ IMPORTANT: be very descriptive and precise in your plan. The more details you provide, the better the generated page will be.`})},{additionalProperties:!1}),{title:"Sections plan",description:"A plan for the sections of the page. Used to generate the page content."}),o=e.Composite([a,e.Object({status:e.Optional(t(["draft","published"],{title:"Page status",enumNames:["Draft","Published"],description:"The status of the page. Can be draft or published. [AI instructions: Dont generate this.]","ai:instructions":"Do not generate this."}))})],{description:"Pages map. The complete list of site pages & their metadata",additionalProperties:!1}),c=e.Array(o);export{a,p as b,o as c,c as d};
@@ -1,3 +1,3 @@
1
1
  /*! Upstart.gg - Copyright (C) 2024 Flippable - https://github.com/upstart-gg/upstart/blob/main/LICENSE */
2
2
 
3
- import{Type as t}from"@sinclair/typebox";import{Type as e}from"@sinclair/typebox";var n=e.Object({externalUrl:e.Optional(e.String()),baseId:e.String({pattern:"^app[A-Za-z0-9]+$",description:'Airtable Base ID starting with "app"'}),baseName:e.Optional(e.String({description:"Airtable Base Name"})),tableId:e.String({pattern:"^tbl[A-Za-z0-9]+$",description:'Airtable Table ID starting with "tbl"'}),tableName:e.Optional(e.String({description:"Table name as shown in Airtable interface"}))});import{Type as r}from"@sinclair/typebox";var s=r.Object({url:r.String({format:"uri",title:"Webhook URL"}),headers:r.Optional(r.Record(r.String(),r.String(),{title:"Headers",description:"Additional headers to include in the webhook request"}))});import{Type as i}from"@sinclair/typebox";var p=i.Object({spreadsheetId:i.String(),spreadsheetUrl:i.Optional(i.String()),spreadsheetName:i.Optional(i.String()),externalUrl:i.Optional(i.String())});import{Type as o}from"@sinclair/typebox";var l=o.Object({url:o.Optional(o.String()),id:o.String({pattern:"^[A-Za-z0-9\\-]+$",description:"Notion Database ID"}),name:o.String({description:"Notion Database Name"}),properties:o.Any()});var D=t.Union([t.Literal("airtable"),t.Literal("google-sheets"),t.Literal("notion"),t.Literal("generic-webhook"),t.Literal("internal")]),c=t.Object({provider:t.Literal("internal"),schema:t.Any({title:"Schema",description:"JSON Schema of the datarecord. Always of type 'object' and representing a row that will be saved.",examples:[{type:"object",properties:{firstname:{type:"string",title:"Firstname"},lastname:{type:"string",title:"Lastname"},email:{type:"string",format:"email",title:"Email"}},required:["email"],title:"Newsletter Subscription"}]}),indexes:t.Array(t.Object({name:t.String({title:"Index name"}),fields:t.Array(t.String(),{title:"Fields to index"}),unique:t.Optional(t.Boolean({title:"Unique index",default:!1}))}),{title:"Indexes",description:"IMPORTANT: Indexes to create on the datarecord. use it to enforce uniqueness or improve query performance."})},{examples:[{provider:"internal",schema:{type:"object",properties:{firstname:{type:"string",title:"Firstname"},lastname:{type:"string",title:"Lastname"},email:{type:"string",format:"email",title:"Email"}},required:["email"],title:"Newsletter Subscription"},indexes:[{name:"email_index",fields:["email"],unique:!0}]}]}),a=t.Object({schema:t.Any({title:"Schema",description:"JSON Schema of the datarecord. Always of type 'object' and representing a row that will be saved.",examples:[{type:"object",properties:{firstname:{type:"string",title:"Firstname"},lastname:{type:"string",title:"Lastname"},email:{type:"string",format:"email",title:"Email"}},required:["email"],title:"Newsletter Subscription"}]})}),d=t.Union([t.Composite([t.Object({provider:t.Literal("airtable"),options:n}),a]),t.Composite([t.Object({provider:t.Literal("google-sheets"),options:p}),a]),t.Composite([t.Object({provider:t.Literal("notion"),options:l}),a]),t.Composite([t.Object({provider:t.Literal("generic-webhook"),options:s}),a]),c]),m=t.Object({id:t.String({title:"Datarecord ID",comment:"A unique identifier for the datarecord, e.g., 'newsletter_subscriptions'"}),label:t.String({title:"Name of the datarecord",comment:"For example, 'Newsletter Subscriptions'"}),description:t.Optional(t.String({title:"Description of the datarecord"}))}),b=t.Composite([d,m]),I=t.Composite([m,c]),q=t.Array(b);export{D as a,d as b,I as c,q as d};
3
+ import{Type as t}from"@sinclair/typebox";import{Type as e}from"@sinclair/typebox";var n=e.Object({externalUrl:e.Optional(e.String()),baseId:e.String({pattern:"^app[A-Za-z0-9]+$",description:'Airtable Base ID starting with "app"'}),baseName:e.Optional(e.String({description:"Airtable Base Name"})),tableId:e.String({pattern:"^tbl[A-Za-z0-9]+$",description:'Airtable Table ID starting with "tbl"'}),tableName:e.Optional(e.String({description:"Table name as shown in Airtable interface"}))});import{Type as i}from"@sinclair/typebox";var p=i.Object({url:i.String({format:"uri",title:"Webhook URL"}),headers:i.Optional(i.Record(i.String(),i.String(),{title:"Headers",description:"Additional headers to include in the webhook request"}))});import{Type as r}from"@sinclair/typebox";var s=r.Object({spreadsheetId:r.String(),spreadsheetUrl:r.Optional(r.String()),spreadsheetName:r.Optional(r.String()),externalUrl:r.Optional(r.String())});import{Type as o}from"@sinclair/typebox";var l=o.Object({url:o.Optional(o.String()),id:o.String({pattern:"^[A-Za-z0-9\\-]+$",description:"Notion Database ID"}),name:o.String({description:"Notion Database Name"}),properties:o.Any()});var U=t.Union([t.Literal("airtable"),t.Literal("google-sheets"),t.Literal("notion"),t.Literal("generic-webhook"),t.Literal("internal")]),c=t.Object({provider:t.Literal("internal"),schema:t.Any({title:"Schema",description:"JSON Schema of the datarecord. Always of type 'object' and representing a row that will be saved.",examples:[{type:"object",properties:{firstname:{type:"string",title:"Firstname"},lastname:{type:"string",title:"Lastname"},email:{type:"string",format:"email",title:"Email"}},required:["email"],title:"Newsletter Subscription"}]}),indexes:t.Array(t.Object({name:t.String({title:"Index name"}),fields:t.Array(t.String(),{title:"Fields to index"}),unique:t.Optional(t.Boolean({title:"Unique index",default:!1}))}),{title:"Indexes",description:"IMPORTANT: Indexes to create on the datarecord. use it to enforce uniqueness or improve query performance."})},{examples:[{provider:"internal",schema:{type:"object",properties:{firstname:{type:"string",title:"Firstname"},lastname:{type:"string",title:"Lastname"},email:{type:"string",format:"email",title:"Email"}},required:["email"],title:"Newsletter Subscription"},indexes:[{name:"email_index",fields:["email"],unique:!0}]}]}),a=t.Object({schema:t.Any({title:"Schema",description:"JSON Schema of the datarecord. Always of type 'object' and representing a row that will be saved.",examples:[{type:"object",properties:{firstname:{type:"string",title:"Firstname"},lastname:{type:"string",title:"Lastname"},email:{type:"string",format:"email",title:"Email"}},required:["email"],title:"Newsletter Subscription"}]})}),d=t.Union([t.Composite([t.Object({provider:t.Literal("airtable"),options:n}),a]),t.Composite([t.Object({provider:t.Literal("google-sheets"),options:s}),a]),t.Composite([t.Object({provider:t.Literal("notion"),options:l}),a]),t.Composite([t.Object({provider:t.Literal("generic-webhook"),options:p}),a]),c]),m=t.Object({id:t.String({title:"Datarecord ID",comment:"A unique identifier for the datarecord, e.g., 'newsletter_subscriptions'"}),label:t.String({title:"Name of the datarecord",comment:"For example, 'Newsletter Subscriptions'"}),description:t.Optional(t.String({title:"Description of the datarecord"}))}),b=t.Composite([d,m]),k=t.Composite([m,c]),C=t.Array(b),y=t.Object({id:t.String(),name:t.String(),data:t.Any(),base:t.Optional(t.Object({id:t.String(),name:t.String(),data:t.Any()}))}),M=t.Array(y),S=t.Object({type:t.Literal("string"),title:t.String({description:"String field. May be single-line or multi-line, enum, email or url"}),format:t.Optional(t.Union([t.Literal("email"),t.Literal("url"),t.Literal("date"),t.Literal("date-time")])),"ui:placeholder":t.Optional(t.String()),minLength:t.Optional(t.Number()),maxLength:t.Optional(t.Number()),enum:t.Optional(t.Array(t.String(),{minItems:1})),metadata:t.Optional(t.Object({order:t.Optional(t.Number()),"ui:multiline":t.Literal(!0)}))}),g=t.Object({type:t.Literal("boolean"),title:t.String(),metadata:t.Optional(t.Object({order:t.Optional(t.Number())}))}),O=t.Object({type:t.Literal("number"),title:t.String(),min:t.Optional(t.Number()),max:t.Optional(t.Number()),default:t.Optional(t.Number()),metadata:t.Optional(t.Object({order:t.Optional(t.Number())}))}),h=t.Union([S,g,O]),f=t.Record(t.String(),h),F=t.Object({id:t.Optional(t.String()),type:t.Literal("object"),properties:f,required:t.Optional(t.Array(t.String()))});export{U as a,d as b,k as c,C as d,y as e,M as f,S as g,g as h,O as i,h as j,f as k,F as l};
@@ -1,3 +1,3 @@
1
1
  /*! Upstart.gg - Copyright (C) 2024 Flippable - https://github.com/upstart-gg/upstart/blob/main/LICENSE */
2
2
 
3
- import{a as t}from"./chunk-EYPREFMH.js";import{e as a}from"./chunk-NLEWXPVM.js";import{Type as e}from"@sinclair/typebox";var s=e.Object({id:e.String({description:"The unique ID of the page. Use a human readable url-safe slug"}),label:e.String({description:"The label (name) of the page"}),path:e.String({description:"The path of the page in the URL. Should be unique"}),sections:e.Array(a,{description:"The sections of the page. See the Section schema"}),tags:e.Array(e.String(),{description:"The tags of the page, used for organizating and filtering pages"}),attributes:t});export{s as a};
3
+ import{a as t}from"./chunk-EYPREFMH.js";import{e as a}from"./chunk-NLEWXPVM.js";import{Type as e}from"@sinclair/typebox";var n=e.Object({id:e.String({description:"The unique ID of the page. Use a human readable url-safe slug"}),label:e.String({description:"The label (name) of the page"}),path:e.String({description:"The path of the page in the URL. Should be unique"}),sections:e.Array(a,{description:"The sections of the page. See the Section schema"}),attributes:t});export{n as a};
@@ -1,11 +1,10 @@
1
- import type { GenericPageConfig } from "./page";
1
+ import type { VersionedPage } from "./page";
2
2
  import type { Site } from "./site";
3
3
  import type { Sitemap } from "./sitemap";
4
4
  export type GenerationState = {
5
5
  isReady: boolean;
6
6
  hasSitemap: boolean;
7
7
  hasThemesGenerated: boolean;
8
- pages: GenericPageConfig[];
9
8
  sitemap: Sitemap;
10
9
  };
11
10
  export type CallContextProps = {
@@ -14,13 +13,13 @@ export type CallContextProps = {
14
13
  */
15
14
  site: Site;
16
15
  /**
17
- * All pages in the site.
16
+ * Sitemap
18
17
  */
19
- pages: GenericPageConfig[];
18
+ sitemap: Sitemap;
20
19
  /**
21
- * Current page ID. Undefined if flow is "setup" and no paage has been created yet.
20
+ * Current page. Undefined if flow is "setup" and no page has been created yet.
22
21
  */
23
- currentPageId?: string;
22
+ page?: VersionedPage;
24
23
  /**
25
24
  * When generating a new site, the flow should be "setup".
26
25
  * Otherwise, it should be "edit".
@@ -1 +1 @@
1
- {"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../src/shared/context.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,QAAQ,CAAC;AAChD,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AACnC,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEzC,MAAM,MAAM,eAAe,GAAG;IAC5B,OAAO,EAAE,OAAO,CAAC;IACjB,UAAU,EAAE,OAAO,CAAC;IACpB,kBAAkB,EAAE,OAAO,CAAC;IAC5B,KAAK,EAAE,iBAAiB,EAAE,CAAC;IAC3B,OAAO,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF,MAAM,MAAM,gBAAgB,GAAG;IAC7B;;OAEG;IACH,IAAI,EAAE,IAAI,CAAC;IACX;;OAEG;IACH,KAAK,EAAE,iBAAiB,EAAE,CAAC;IAC3B;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB;;;OAGG;IACH,IAAI,EAAE,OAAO,GAAG,MAAM,CAAC;IACvB;;OAEG;IACH,eAAe,CAAC,EAAE,eAAe,CAAC;IAClC;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB,CAAC"}
1
+ {"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../src/shared/context.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,QAAQ,CAAC;AAC5C,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AACnC,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEzC,MAAM,MAAM,eAAe,GAAG;IAC5B,OAAO,EAAE,OAAO,CAAC;IACjB,UAAU,EAAE,OAAO,CAAC;IACpB,kBAAkB,EAAE,OAAO,CAAC;IAC5B,OAAO,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF,MAAM,MAAM,gBAAgB,GAAG;IAC7B;;OAEG;IACH,IAAI,EAAE,IAAI,CAAC;IACX;;OAEG;IACH,OAAO,EAAE,OAAO,CAAC;IACjB;;OAEG;IACH,IAAI,CAAC,EAAE,aAAa,CAAC;IACrB;;;OAGG;IACH,IAAI,EAAE,OAAO,GAAG,MAAM,CAAC;IACvB;;OAEG;IACH,eAAe,CAAC,EAAE,eAAe,CAAC;IAClC;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB,CAAC"}
@@ -0,0 +1,8 @@
1
+ export default function getClient(token: string): {
2
+ callApi<R, P extends Record<string, unknown> = Record<string, unknown>>(path: string, method?: "GET" | "POST" | "DELETE" | "PUT" | "PATCH", body?: P | null): Promise<{
3
+ status: number;
4
+ success: boolean;
5
+ data: R;
6
+ }>;
7
+ };
8
+ //# sourceMappingURL=client.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../../../src/shared/datarecords/external/airtable/client.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,OAAO,UAAU,SAAS,CAAC,KAAK,EAAE,MAAM;YAM7B,CAAC,EAAE,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,kCAC1C,MAAM,WACJ,KAAK,GAAG,MAAM,GAAG,QAAQ,GAAG,KAAK,GAAG,OAAO,SAC7C,CAAC,GAAG,IAAI;;;cA8BoB,CAAC;;EAsBxC"}
@@ -1,8 +1,8 @@
1
+ import type { Schema } from "../../types";
1
2
  import type { AirtableOptions } from "./options";
2
- /**
3
- * WARNING: not tested yet!!
4
- *
5
- * @todo test this function in a real environment
6
- */
7
- export default function airtableHandler(formData: FormData, options: AirtableOptions, accessToken: string): Promise<boolean>;
3
+ import type { CreateAirtableTableResponse } from "./types";
4
+ export declare function saveRecord(formData: FormData, options: AirtableOptions, accessToken: string): Promise<{
5
+ id: string;
6
+ } | null>;
7
+ export declare function createTable(name: string, schema: Schema, baseId: string, accessToken: string): Promise<CreateAirtableTableResponse | null>;
8
8
  //# sourceMappingURL=handler.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"handler.d.ts","sourceRoot":"","sources":["../../../../../src/shared/datarecords/external/airtable/handler.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AAEjD;;;;GAIG;AACH,wBAA8B,eAAe,CAC3C,QAAQ,EAAE,QAAQ,EAClB,OAAO,EAAE,eAAe,EACxB,WAAW,EAAE,MAAM,oBAcpB"}
1
+ {"version":3,"file":"handler.d.ts","sourceRoot":"","sources":["../../../../../src/shared/datarecords/external/airtable/handler.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAE1C,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AACjD,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,SAAS,CAAC;AAE3D,wBAAsB,UAAU,CAC9B,QAAQ,EAAE,QAAQ,EAClB,OAAO,EAAE,eAAe,EACxB,WAAW,EAAE,MAAM,GAClB,OAAO,CAAC;IAAE,EAAE,EAAE,MAAM,CAAA;CAAE,GAAG,IAAI,CAAC,CA6BhC;AAED,wBAAsB,WAAW,CAC/B,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,MAAM,EACd,WAAW,EAAE,MAAM,GAClB,OAAO,CAAC,2BAA2B,GAAG,IAAI,CAAC,CA8F7C"}
@@ -0,0 +1,3 @@
1
+ /*! Upstart.gg - Copyright (C) 2024 Flippable - https://github.com/upstart-gg/upstart/blob/main/LICENSE */
2
+
3
+ var m=a=>new Promise(i=>setTimeout(i,a));function c(a){if(!a)throw new Error("Missing Airtable API token");return{async callApi(i,l="GET",s=null){let o=`https://api.airtable.com/${i}`,e=5,n=3e4;for(let t=1;t<=e;t++)try{let r=await fetch(o,{method:l,headers:{Authorization:`Bearer ${a}`,"Content-Type":"application/json"},body:s?JSON.stringify(s):void 0});if(r.status===429&&t<e){console.warn(`Airtable rate limit hit (429) on attempt ${t}/${e}. Waiting ${n/1e3}s before retry...`),await m(n);continue}return{status:r.status,success:r.ok,data:await r.json()}}catch(r){if(t<e){console.warn(`Network error on attempt ${t}/${e}. Waiting ${n/1e3}s before retry...`,r),await m(n);continue}throw console.error(`Error on attempt ${t}/${e}:`,r),r}throw new Error(`Airtable API rate limit exceeded after ${e} attempts`)}}}async function y(a,i,l){try{let s=c(l),o={};for(let[n,t]of a.entries())o[n]=t;let e=await s.callApi(`v0/${i.baseId}/${i.tableId}`,"POST",{records:[{fields:o}]});if(!e.success)throw new Error(`Failed to push data to Airtable: ${e.status} - ${JSON.stringify(e.data)}`);return e.data.records[0]?{id:e.data.records[0].id}:null}catch(s){console.error("Error pushing data to Airtable:",s)}return null}async function d(a,i,l,s){let o=Object.entries(i.properties).map(([n,t])=>{if(t.type==="string")return t.format==="email"?{name:t.title,type:"email"}:t.format==="url"?{name:t.title,type:"url"}:t.format==="date"?{name:t.title,type:"date"}:t.format==="date-time"?{name:t.title,type:"dateTime"}:t.metadata?.["ui:multiline"]?{name:t.title,type:"multilineText"}:t.enum?{name:t.title,type:"singleSelect",options:t.enum.map(r=>({id:r,name:r}))}:{name:t.title,type:"singleLineText"};if(t.type==="boolean")return{name:t.title,type:"checkbox"};if(t.type==="number")return{name:t.title,type:"number"}}),e={name:a,description:`Table created by Upstart for ${a}`,fields:o};try{let t=await c(s).callApi(`v0/meta/bases/${l}/tables`,"POST",e);if(!t.success)throw new Error(`Failed to create Airtable table: ${t.status} - ${JSON.stringify(t.data)}`);return t.data}catch(n){console.error("Error creating Airtable table:",n)}return null}export{d as createTable,y as saveRecord};
@@ -1 +1 @@
1
- {"version":3,"file":"options.d.ts","sourceRoot":"","sources":["../../../../../src/shared/datarecords/external/airtable/options.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAEtD,eAAO,MAAM,eAAe;;;;;;EAoB1B,CAAC;AAEH,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC,OAAO,eAAe,CAAC,CAAC"}
1
+ {"version":3,"file":"options.d.ts","sourceRoot":"","sources":["../../../../../src/shared/datarecords/external/airtable/options.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAEtD,eAAO,MAAM,eAAe;;;;;;EAgB1B,CAAC;AAEH,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC,OAAO,eAAe,CAAC,CAAC"}
@@ -0,0 +1,15 @@
1
+ import { type Static } from "@sinclair/typebox";
2
+ declare const createAirtableTableResponseSchema: import("@sinclair/typebox").TObject<{
3
+ id: import("@sinclair/typebox").TString;
4
+ name: import("@sinclair/typebox").TString;
5
+ description: import("@sinclair/typebox").TString;
6
+ primaryFieldId: import("@sinclair/typebox").TString;
7
+ fields: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
8
+ id: import("@sinclair/typebox").TString;
9
+ name: import("@sinclair/typebox").TString;
10
+ type: import("@sinclair/typebox").TString;
11
+ }>>;
12
+ }>;
13
+ export type CreateAirtableTableResponse = Static<typeof createAirtableTableResponseSchema>;
14
+ export {};
15
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../src/shared/datarecords/external/airtable/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAEtD,QAAA,MAAM,iCAAiC;;;;;;;;;;EAYrC,CAAC;AAEH,MAAM,MAAM,2BAA2B,GAAG,MAAM,CAAC,OAAO,iCAAiC,CAAC,CAAC"}
@@ -0,0 +1,14 @@
1
+ interface ApiResponse<T> {
2
+ success: boolean;
3
+ data: T;
4
+ status: number;
5
+ headers: Headers;
6
+ }
7
+ declare class GoogleDriveClient {
8
+ private accessToken;
9
+ constructor(accessToken: string);
10
+ callDriveApi<T>(endpoint: string, method?: "GET" | "POST" | "PUT" | "PATCH", body?: unknown): Promise<ApiResponse<T>>;
11
+ }
12
+ export default function getClient(accessToken: string): GoogleDriveClient;
13
+ export {};
14
+ //# sourceMappingURL=client.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../../../../src/shared/datarecords/external/google/sheets/client.ts"],"names":[],"mappings":"AAAA,UAAU,WAAW,CAAC,CAAC;IACrB,OAAO,EAAE,OAAO,CAAC;IACjB,IAAI,EAAE,CAAC,CAAC;IACR,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,cAAM,iBAAiB;IACrB,OAAO,CAAC,WAAW,CAAS;gBAEhB,WAAW,EAAE,MAAM;IAIzB,YAAY,CAAC,CAAC,EAClB,QAAQ,EAAE,MAAM,EAChB,MAAM,GAAE,KAAK,GAAG,MAAM,GAAG,KAAK,GAAG,OAAe,EAChD,IAAI,CAAC,EAAE,OAAO,GACb,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC;CAyF3B;AAED,MAAM,CAAC,OAAO,UAAU,SAAS,CAAC,WAAW,EAAE,MAAM,GAAG,iBAAiB,CAExE"}
@@ -1,8 +1,6 @@
1
+ import type { TablesList } from "../../../types";
1
2
  import type { GoogleSheetsOptions } from "./options";
2
- /**
3
- * WARNING: not tested yet!!
4
- *
5
- * @todo test this function in a real environment
6
- */
7
- export default function googleSheetsHandler(formData: FormData, options: GoogleSheetsOptions, accessToken: string): Promise<boolean>;
3
+ export declare function saveRecord(formData: FormData, options: GoogleSheetsOptions, accessToken: string): Promise<boolean>;
4
+ export declare function getSchema(accessToken: string, options: GoogleSheetsOptions): Promise<Record<string, unknown> | null>;
5
+ export declare function listTables(accessToken: string): Promise<TablesList>;
8
6
  //# sourceMappingURL=handler.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"handler.d.ts","sourceRoot":"","sources":["../../../../../../src/shared/datarecords/external/google/sheets/handler.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,WAAW,CAAC;AAErD;;;;GAIG;AACH,wBAA8B,mBAAmB,CAC/C,QAAQ,EAAE,QAAQ,EAClB,OAAO,EAAE,mBAAmB,EAC5B,WAAW,EAAE,MAAM,oBAepB"}
1
+ {"version":3,"file":"handler.d.ts","sourceRoot":"","sources":["../../../../../../src/shared/datarecords/external/google/sheets/handler.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAEjD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,WAAW,CAAC;AAErD,wBAAsB,UAAU,CAC9B,QAAQ,EAAE,QAAQ,EAClB,OAAO,EAAE,mBAAmB,EAC5B,WAAW,EAAE,MAAM,GAClB,OAAO,CAAC,OAAO,CAAC,CAkGlB;AAED,wBAAsB,SAAS,CAC7B,WAAW,EAAE,MAAM,EACnB,OAAO,EAAE,mBAAmB,GAC3B,OAAO,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,CAAC,CAiBzC;AAED,wBAAsB,UAAU,CAAC,WAAW,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,CAAC,CA4CzE"}
@@ -0,0 +1,6 @@
1
+ /*! Upstart.gg - Copyright (C) 2024 Flippable - https://github.com/upstart-gg/upstart/blob/main/LICENSE */
2
+
3
+ var h=class{accessToken;constructor(s){this.accessToken=s}async callDriveApi(s,o="GET",t){let r=t instanceof ArrayBuffer||t instanceof Uint8Array,u={Authorization:`Bearer ${this.accessToken}`};r?u["Content-Type"]="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":u["Content-Type"]="application/json";let e=await fetch(s,{method:o,headers:u,body:r?t:t?JSON.stringify(t):void 0});if(s.includes("export")&&s.includes("mimeType=text/csv")){let i=await e.text();return{success:e.ok,data:i,status:e.status,headers:e.headers}}if(s.includes("export")&&s.includes("mimeType=application/vnd.openxmlformats-officedocument.spreadsheetml.sheet")){let i=await e.arrayBuffer();return{success:e.ok,data:i,status:e.status,headers:e.headers}}if(s.includes("upload/")&&e.ok)try{let i=await e.json();return{success:e.ok,data:i,status:e.status,headers:e.headers}}catch{return{success:!0,data:{message:"Upload successful"},status:e.status,headers:e.headers}}if(!e.ok&&e.headers.get("content-type")?.includes("text/html"))return{success:!1,data:{error:"HTML error response",details:(await e.text()).substring(0,200)},status:e.status,headers:e.headers};let c=await e.json();return{success:e.ok,data:c,status:e.status,headers:e.headers}}};function p(n){return new h(n)}async function x(n,s,o){try{if(!o)throw new Error("Access token is required");if(!s.spreadsheetId)throw new Error("Spreadsheet ID is required");let t=p(o),r=await t.callDriveApi(`https://www.googleapis.com/drive/v3/files/${s.spreadsheetId}/export?mimeType=text/csv`,"GET");if(!r.success)throw new Error(`Failed to download spreadsheet: ${r.status}`);let e=r.data.trim().split(`
4
+ `),c={};for(let[l,a]of n.entries())c[l]=a;let i=Object.keys(c),d=[];e.length===0||e[0].trim()===""?d.push(i.join(",")):d=[...e];let g=[i.map(l=>{let a=c[l]?.toString()||"";return a.includes(",")||a.includes('"')||a.includes(`
5
+ `)?`"${a.replace(/"/g,'""')}"`:a}).join(",")];d.push(...g);let w=d.join(`
6
+ `),m=await t.callDriveApi(`https://www.googleapis.com/upload/drive/v3/files/${s.spreadsheetId}?uploadType=resumable`,"PATCH",{mimeType:"application/vnd.google-apps.spreadsheet"});if(!m.success){let l=await m.data;throw new Error(`Failed to initiate upload: ${m.status} - ${l}`)}let f=m.headers.get("Location");if(!f)throw new Error("No upload URL returned from Google Drive");return(await fetch(f,{method:"PUT",headers:{"Content-Type":"text/csv"},body:w})).ok}catch(t){return console.error("Error pushing data to Google Sheets:",t),!1}}async function k(n,s){try{let t=await p(n).callDriveApi(`files/${s.spreadsheetId}/export?mimeType=application/vnd.openxmlformats-officedocument.spreadsheetml.sheet`,"GET");if(!t.success)throw new Error(`Failed to get spreadsheet schema: ${t.status}`);return t.data}catch(o){return console.error("Error getting Google Sheets schema:",o),null}}async function E(n){try{if(!n)throw new Error("Access token is required");let o=await p(n).callDriveApi("https://www.googleapis.com/drive/v3/files?q=mimeType='application/vnd.google-apps.spreadsheet'&fields=files(id,name,mimeType,createdTime,modifiedTime,webViewLink)","GET");if(!o.success)throw new Error(`Failed to list Google Sheets: ${o.status}`);return o.data.files.map(r=>({id:r.id,name:r.name,data:{mimeType:r.mimeType,createdTime:r.createdTime,modifiedTime:r.modifiedTime,webViewLink:r.webViewLink}}))}catch(s){return console.error("Error listing Google Sheets:",s),[]}}export{k as getSchema,E as listTables,x as saveRecord};
@@ -0,0 +1,8 @@
1
+ export default function getClient(token: string): {
2
+ callApi<R, P extends Record<string, unknown> = Record<string, unknown>>(path: string, method?: "GET" | "POST" | "DELETE" | "PUT" | "PATCH", body?: P | null): Promise<{
3
+ status: number;
4
+ success: boolean;
5
+ data: R;
6
+ }>;
7
+ };
8
+ //# sourceMappingURL=client.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../../../src/shared/datarecords/external/notion/client.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,OAAO,UAAU,SAAS,CAAC,KAAK,EAAE,MAAM;YAM7B,CAAC,EAAE,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,kCAC1C,MAAM,WACJ,KAAK,GAAG,MAAM,GAAG,QAAQ,GAAG,KAAK,GAAG,OAAO,SAC7C,CAAC,GAAG,IAAI;;;cA+BoB,CAAC;;EAsBxC"}
@@ -0,0 +1,9 @@
1
+ import { type CreateDatabaseResponse, type DatabaseObjectResponse } from "@notionhq/client";
2
+ import type { Schema, TablesList } from "../../types";
3
+ import type { NotionOptions } from "./options";
4
+ export type { CreateDatabaseResponse, DatabaseObjectResponse };
5
+ export declare function saveRecord(formData: FormData, options: NotionOptions, accessToken: string): Promise<import("@notionhq/client").CreatePageResponse>;
6
+ export declare function listTables(accessToken: string): Promise<TablesList>;
7
+ export declare function listPages(accessToken: string): Promise<TablesList>;
8
+ export declare function createTable(name: string, schema: Schema, pageId: string, accessToken: string): Promise<NotionOptions>;
9
+ //# sourceMappingURL=handler.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"handler.d.ts","sourceRoot":"","sources":["../../../../../src/shared/datarecords/external/notion/handler.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,sBAAsB,EAC3B,KAAK,sBAAsB,EAE5B,MAAM,kBAAkB,CAAC;AAC1B,OAAO,KAAK,EAAE,MAAM,EAAS,UAAU,EAAE,MAAM,aAAa,CAAC;AAC7D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAE/C,YAAY,EAAE,sBAAsB,EAAE,sBAAsB,EAAE,CAAC;AAE/D,wBAAsB,UAAU,CAAC,QAAQ,EAAE,QAAQ,EAAE,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,0DAe/F;AAED,wBAAsB,UAAU,CAAC,WAAW,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,CAAC,CAgCzE;AAED,wBAAsB,SAAS,CAAC,WAAW,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,CAAC,CAsCxE;AAoCD,wBAAsB,WAAW,CAC/B,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,MAAM,EACd,WAAW,EAAE,MAAM,GAClB,OAAO,CAAC,aAAa,CAAC,CA+BxB"}
@@ -0,0 +1,3 @@
1
+ /*! Upstart.gg - Copyright (C) 2024 Flippable - https://github.com/upstart-gg/upstart/blob/main/LICENSE */
2
+
3
+ import{Client as c}from"@notionhq/client";function l(s,r){let e={};for(let[t,a]of s.entries())if(!(a==null||a==="")&&t in r)switch(r[t].type){case"title":e[t]={title:[{text:{content:String(a)}}]};break;case"rich_text":e[t]={rich_text:[{text:{content:String(a)}}]};break;case"email":e[t]={email:String(a)};break;case"phone_number":e[t]={phone_number:String(a)};break;case"url":e[t]={url:String(a)};break;case"number":e[t]={number:Number(a)};break;case"checkbox":e[t]={checkbox:!!a};break;case"date":e[t]={date:a?{start:String(a)}:null};break;default:console.warn(`Unsupported property type for key "${t}": ${r[t].type}`),e[t]={rich_text:[{text:{content:String(a)}}]}}return e}async function f(s,r,e){let t=new c({auth:e}),a=l(s,r.properties),o=await t.pages.create({parent:{database_id:r.id},properties:{...a}});if(!o)throw new Error("Failed to push data to Notion");return o}async function m(s){try{let e=await new c({auth:s}).search({filter:{property:"object",value:"database"}}),t=[];for(let a in e.results){let o=e.results[a],i={id:o.id,name:o.title[0]?.plain_text,properties:o.properties,url:o.url},p={id:o.id,name:o.title[0]?.plain_text,data:i};t.push(p)}return t}catch(r){throw console.error("Error listing Notion databases:",r),r}}async function g(s){try{let e=await new c({auth:s}).search({filter:{property:"object",value:"page"}}),t=[];for(let a in e.results){let o=e.results[a];if(o.parent.type!=="database_id"){let i={id:o.id,name:o.properties.title&&o.properties.title.type==="title"&&Array.isArray(o.properties.title.title)&&o.properties.title.title[0]?.plain_text?o.properties.title.title[0].plain_text:"No Title",data:o.properties};t.push(i)}}return t}catch(r){throw console.error("Error listing Notion databases:",r),r}}function b(s){let r={};for(let[e,t]of Object.entries(s.properties))t.type==="string"&&(e===s.required?.[0]?r[e]={title:{},name:e,type:"title"}:r[e]={rich_text:{},name:e,type:"rich_text"}),t.type==="number"&&(r[e]={number:{}}),t.type==="boolean"&&(r[e]={checkbox:{}});return r}async function h(s,r,e,t){let a=b(r),o={parent:{type:"page_id",page_id:e},title:[{type:"text",text:{content:s}}],properties:a},i=new c({auth:t}),p=await i.databases.create(o);if(!p)throw new Error("Failed to create Notion database");let n=await i.databases.retrieve({database_id:p.id});if(!n)throw new Error("Failed to retrieve Notion database after creation");return{id:n.id,name:n.title[0]?.plain_text,properties:n.properties,url:n.url}}export{h as createTable,g as listPages,m as listTables,f as saveRecord};
@@ -0,0 +1,5 @@
1
+ import type { NotionOptions } from "./options";
2
+ type NotionDatabaseProperties = NotionOptions["properties"];
3
+ export declare function buildCreatePageParameters(data: FormData, databaseProperties: NotionDatabaseProperties): Record<string, any>;
4
+ export {};
5
+ //# sourceMappingURL=utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../../src/shared/datarecords/external/notion/utils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAE/C,KAAK,wBAAwB,GAAG,aAAa,CAAC,YAAY,CAAC,CAAC;AAE5D,wBAAgB,yBAAyB,CAAC,IAAI,EAAE,QAAQ,EAAE,kBAAkB,EAAE,wBAAwB,uBA0ErG"}
@@ -73,5 +73,152 @@ export declare const datarecordsList: import("@sinclair/typebox").TArray<import(
73
73
  description: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
74
74
  }>>;
75
75
  export type DatarecordsList = Static<typeof datarecordsList>;
76
+ export declare const table: import("@sinclair/typebox").TObject<{
77
+ id: import("@sinclair/typebox").TString;
78
+ name: import("@sinclair/typebox").TString;
79
+ data: import("@sinclair/typebox").TAny;
80
+ base: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
81
+ id: import("@sinclair/typebox").TString;
82
+ name: import("@sinclair/typebox").TString;
83
+ data: import("@sinclair/typebox").TAny;
84
+ }>>;
85
+ }>;
86
+ export type Table = Static<typeof table>;
87
+ export declare const tablesList: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
88
+ id: import("@sinclair/typebox").TString;
89
+ name: import("@sinclair/typebox").TString;
90
+ data: import("@sinclair/typebox").TAny;
91
+ base: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
92
+ id: import("@sinclair/typebox").TString;
93
+ name: import("@sinclair/typebox").TString;
94
+ data: import("@sinclair/typebox").TAny;
95
+ }>>;
96
+ }>>;
97
+ export type TablesList = Static<typeof tablesList>;
98
+ export declare const stringProperty: import("@sinclair/typebox").TObject<{
99
+ type: import("@sinclair/typebox").TLiteral<"string">;
100
+ title: import("@sinclair/typebox").TString;
101
+ format: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"email">, import("@sinclair/typebox").TLiteral<"url">, import("@sinclair/typebox").TLiteral<"date">, import("@sinclair/typebox").TLiteral<"date-time">]>>;
102
+ "ui:placeholder": import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
103
+ minLength: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
104
+ maxLength: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
105
+ enum: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
106
+ metadata: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
107
+ order: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
108
+ "ui:multiline": import("@sinclair/typebox").TLiteral<true>;
109
+ }>>;
110
+ }>;
111
+ export type StringProperty = Static<typeof stringProperty>;
112
+ export declare const booleanProperty: import("@sinclair/typebox").TObject<{
113
+ type: import("@sinclair/typebox").TLiteral<"boolean">;
114
+ title: import("@sinclair/typebox").TString;
115
+ metadata: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
116
+ order: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
117
+ }>>;
118
+ }>;
119
+ export type BooleanProperty = Static<typeof booleanProperty>;
120
+ export declare const numberProperty: import("@sinclair/typebox").TObject<{
121
+ type: import("@sinclair/typebox").TLiteral<"number">;
122
+ title: import("@sinclair/typebox").TString;
123
+ min: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
124
+ max: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
125
+ default: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
126
+ metadata: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
127
+ order: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
128
+ }>>;
129
+ }>;
130
+ export type NumberProperty = Static<typeof numberProperty>;
131
+ export declare const schemaProperty: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
132
+ type: import("@sinclair/typebox").TLiteral<"string">;
133
+ title: import("@sinclair/typebox").TString;
134
+ format: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"email">, import("@sinclair/typebox").TLiteral<"url">, import("@sinclair/typebox").TLiteral<"date">, import("@sinclair/typebox").TLiteral<"date-time">]>>;
135
+ "ui:placeholder": import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
136
+ minLength: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
137
+ maxLength: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
138
+ enum: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
139
+ metadata: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
140
+ order: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
141
+ "ui:multiline": import("@sinclair/typebox").TLiteral<true>;
142
+ }>>;
143
+ }>, import("@sinclair/typebox").TObject<{
144
+ type: import("@sinclair/typebox").TLiteral<"boolean">;
145
+ title: import("@sinclair/typebox").TString;
146
+ metadata: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
147
+ order: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
148
+ }>>;
149
+ }>, import("@sinclair/typebox").TObject<{
150
+ type: import("@sinclair/typebox").TLiteral<"number">;
151
+ title: import("@sinclair/typebox").TString;
152
+ min: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
153
+ max: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
154
+ default: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
155
+ metadata: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
156
+ order: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
157
+ }>>;
158
+ }>]>;
159
+ export type SchemaProperty = Static<typeof schemaProperty>;
160
+ export declare const schemaProperties: import("@sinclair/typebox").TRecord<import("@sinclair/typebox").TString, import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
161
+ type: import("@sinclair/typebox").TLiteral<"string">;
162
+ title: import("@sinclair/typebox").TString;
163
+ format: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"email">, import("@sinclair/typebox").TLiteral<"url">, import("@sinclair/typebox").TLiteral<"date">, import("@sinclair/typebox").TLiteral<"date-time">]>>;
164
+ "ui:placeholder": import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
165
+ minLength: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
166
+ maxLength: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
167
+ enum: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
168
+ metadata: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
169
+ order: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
170
+ "ui:multiline": import("@sinclair/typebox").TLiteral<true>;
171
+ }>>;
172
+ }>, import("@sinclair/typebox").TObject<{
173
+ type: import("@sinclair/typebox").TLiteral<"boolean">;
174
+ title: import("@sinclair/typebox").TString;
175
+ metadata: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
176
+ order: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
177
+ }>>;
178
+ }>, import("@sinclair/typebox").TObject<{
179
+ type: import("@sinclair/typebox").TLiteral<"number">;
180
+ title: import("@sinclair/typebox").TString;
181
+ min: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
182
+ max: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
183
+ default: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
184
+ metadata: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
185
+ order: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
186
+ }>>;
187
+ }>]>>;
188
+ export type SchemaProperties = Static<typeof schemaProperties>;
189
+ export declare const schema: import("@sinclair/typebox").TObject<{
190
+ id: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
191
+ type: import("@sinclair/typebox").TLiteral<"object">;
192
+ properties: import("@sinclair/typebox").TRecord<import("@sinclair/typebox").TString, import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
193
+ type: import("@sinclair/typebox").TLiteral<"string">;
194
+ title: import("@sinclair/typebox").TString;
195
+ format: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"email">, import("@sinclair/typebox").TLiteral<"url">, import("@sinclair/typebox").TLiteral<"date">, import("@sinclair/typebox").TLiteral<"date-time">]>>;
196
+ "ui:placeholder": import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
197
+ minLength: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
198
+ maxLength: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
199
+ enum: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
200
+ metadata: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
201
+ order: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
202
+ "ui:multiline": import("@sinclair/typebox").TLiteral<true>;
203
+ }>>;
204
+ }>, import("@sinclair/typebox").TObject<{
205
+ type: import("@sinclair/typebox").TLiteral<"boolean">;
206
+ title: import("@sinclair/typebox").TString;
207
+ metadata: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
208
+ order: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
209
+ }>>;
210
+ }>, import("@sinclair/typebox").TObject<{
211
+ type: import("@sinclair/typebox").TLiteral<"number">;
212
+ title: import("@sinclair/typebox").TString;
213
+ min: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
214
+ max: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
215
+ default: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
216
+ metadata: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
217
+ order: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
218
+ }>>;
219
+ }>]>>;
220
+ required: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
221
+ }>;
222
+ export type Schema = Static<typeof schema>;
76
223
  export {};
77
224
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/shared/datarecords/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAMtD,eAAO,MAAM,eAAe,0SAO1B,CAAC;AAEH,MAAM,MAAM,mBAAmB,GAAG,MAAM,CAAC,OAAO,eAAe,CAAC,CAAC;AAmFjE,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IA8BhC,CAAC;AAcH,QAAA,MAAM,kBAAkB;;;;;;EAA8D,CAAC;AAEvF,eAAO,MAAM,0BAA0B;;;;;;;;;;;EAA2D,CAAC;AACnG,MAAM,MAAM,UAAU,GAAG,MAAM,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAE3D,eAAO,MAAM,eAAe;;;;;;GAAiC,CAAC;AAC9D,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC,OAAO,eAAe,CAAC,CAAC"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/shared/datarecords/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAMtD,eAAO,MAAM,eAAe,0SAO1B,CAAC;AAEH,MAAM,MAAM,mBAAmB,GAAG,MAAM,CAAC,OAAO,eAAe,CAAC,CAAC;AAmFjE,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IA8BhC,CAAC;AAcH,QAAA,MAAM,kBAAkB;;;;;;EAA8D,CAAC;AAEvF,eAAO,MAAM,0BAA0B;;;;;;;;;;;EAA2D,CAAC;AACnG,MAAM,MAAM,UAAU,GAAG,MAAM,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAE3D,eAAO,MAAM,eAAe;;;;;;GAAiC,CAAC;AAC9D,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC,OAAO,eAAe,CAAC,CAAC;AAE7D,eAAO,MAAM,KAAK;;;;;;;;;EAWhB,CAAC;AACH,MAAM,MAAM,KAAK,GAAG,MAAM,CAAC,OAAO,KAAK,CAAC,CAAC;AAEzC,eAAO,MAAM,UAAU;;;;;;;;;GAAoB,CAAC;AAC5C,MAAM,MAAM,UAAU,GAAG,MAAM,CAAC,OAAO,UAAU,CAAC,CAAC;AAInD,eAAO,MAAM,cAAc;;;;;;;;;;;;EAgBzB,CAAC;AACH,MAAM,MAAM,cAAc,GAAG,MAAM,CAAC,OAAO,cAAc,CAAC,CAAC;AAE3D,eAAO,MAAM,eAAe;;;;;;EAQ1B,CAAC;AACH,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC,OAAO,eAAe,CAAC,CAAC;AAE7D,eAAO,MAAM,cAAc;;;;;;;;;EAWzB,CAAC;AACH,MAAM,MAAM,cAAc,GAAG,MAAM,CAAC,OAAO,cAAc,CAAC,CAAC;AAG3D,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;IAAgE,CAAC;AAE5F,MAAM,MAAM,cAAc,GAAG,MAAM,CAAC,OAAO,cAAc,CAAC,CAAC;AAE3D,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;KAA6C,CAAC;AAC3E,MAAM,MAAM,gBAAgB,GAAG,MAAM,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAE/D,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAKjB,CAAC;AACH,MAAM,MAAM,MAAM,GAAG,MAAM,CAAC,OAAO,MAAM,CAAC,CAAC"}
@@ -1,3 +1,3 @@
1
1
  /*! Upstart.gg - Copyright (C) 2024 Flippable - https://github.com/upstart-gg/upstart/blob/main/LICENSE */
2
2
 
3
- import{a,b,c,d}from"../chunk-6K3KZDFC.js";export{a as connectorSchema,b as datarecordsConnectors,d as datarecordsList,c as internalDatarecordManifest};
3
+ import{a,b,c,d,e,f,g,h,i,j,k,l}from"../chunk-UAQHU6L6.js";export{h as booleanProperty,a as connectorSchema,b as datarecordsConnectors,d as datarecordsList,c as internalDatarecordManifest,i as numberProperty,l as schema,k as schemaProperties,j as schemaProperty,g as stringProperty,e as table,f as tablesList};
@@ -1,41 +1,4 @@
1
- import { type PageAttributes } from "./attributes";
2
- import { type Section } from "./bricks";
3
- import type { Theme } from "./theme";
4
1
  import { type Static } from "@sinclair/typebox";
5
- import type { DatasourcesList } from "./datasources/types";
6
- import type { PageInfo, Sitemap } from "./sitemap";
7
- /**
8
- * The Page config represents the page configuration (datasources, attributes, etc)
9
- */
10
- export type PageConfig<D extends DatasourcesList> = PageInfo & {
11
- /**
12
- * Data sources manifests for the page. Undefined if no data sources are defined.
13
- */
14
- datasources?: D;
15
- /**
16
- * Resolved static data sources for the page.
17
- * Undefined if no data sources are defined.
18
- */
19
- data?: Record<string, unknown[]>;
20
- /**
21
- * Page attributes. (can override site attributes)
22
- */
23
- attributes: PageAttributes;
24
- sections: Section[];
25
- tags: string[];
26
- };
27
- export type GenericPageConfig = PageConfig<DatasourcesList>;
28
- /**
29
- * Page context has attr (possibly inherited from site) but not attributes declaration, as they are not needed to render the page.
30
- * It also have the sitemap and theme.
31
- */
32
- export type GenericPageContext = GenericPageConfig & {
33
- siteId: string;
34
- hostname: string;
35
- theme: Theme;
36
- sitemap: Sitemap;
37
- pathParams?: Record<string, string>;
38
- };
39
2
  export declare const pageSchema: import("@sinclair/typebox").TObject<{
40
3
  id: import("@sinclair/typebox").TString;
41
4
  label: import("@sinclair/typebox").TString;
@@ -82,7 +45,6 @@ export declare const pageSchema: import("@sinclair/typebox").TObject<{
82
45
  propsMapping: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{}>>;
83
46
  }>>;
84
47
  }>>;
85
- tags: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>;
86
48
  attributes: import("@sinclair/typebox").TObject<{
87
49
  colorPreset: import("@sinclair/typebox").TObject<{
88
50
  color: import("@sinclair/typebox").TUnsafe<string>;
@@ -141,4 +103,16 @@ export declare const pageSchema: import("@sinclair/typebox").TObject<{
141
103
  }>;
142
104
  }>;
143
105
  export type Page = Static<typeof pageSchema>;
106
+ export type VersionedPage = Page & {
107
+ version: string;
108
+ };
109
+ /**
110
+ * Page context represents the page config PLUS:
111
+ * - the pathParams of the actual request.
112
+ * - the resolved data for the page.
113
+ */
114
+ export type PageContext = VersionedPage & {
115
+ pathParams?: Record<string, string>;
116
+ data?: Record<string, unknown[]>;
117
+ };
144
118
  //# sourceMappingURL=page.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"page.d.ts","sourceRoot":"","sources":["../../src/shared/page.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,cAAc,EAAwB,MAAM,cAAc,CAAC;AACzE,OAAO,EAAE,KAAK,OAAO,EAAiB,MAAM,UAAU,CAAC;AACvD,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EAAQ,KAAK,MAAM,EAAE,MAAM,mBAAmB,CAAC;AACtD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAC3D,OAAO,KAAK,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEnD;;GAEG;AACH,MAAM,MAAM,UAAU,CAAC,CAAC,SAAS,eAAe,IAAI,QAAQ,GAAG;IAC7D;;OAEG;IACH,WAAW,CAAC,EAAE,CAAC,CAAC;IAChB;;;OAGG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,EAAE,CAAC,CAAC;IACjC;;OAEG;IACH,UAAU,EAAE,cAAc,CAAC;IAE3B,QAAQ,EAAE,OAAO,EAAE,CAAC;IACpB,IAAI,EAAE,MAAM,EAAE,CAAC;CAChB,CAAC;AAEF,MAAM,MAAM,iBAAiB,GAAG,UAAU,CAAC,eAAe,CAAC,CAAC;AAE5D;;;GAGG;AACH,MAAM,MAAM,kBAAkB,GAAG,iBAAiB,GAAG;IACnD,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,KAAK,CAAC;IACb,OAAO,EAAE,OAAO,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CACrC,CAAC;AAEF,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAWrB,CAAC;AAEH,MAAM,MAAM,IAAI,GAAG,MAAM,CAAC,OAAO,UAAU,CAAC,CAAC"}
1
+ {"version":3,"file":"page.d.ts","sourceRoot":"","sources":["../../src/shared/page.ts"],"names":[],"mappings":"AAEA,OAAO,EAAQ,KAAK,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAEtD,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAQrB,CAAC;AAEH,MAAM,MAAM,IAAI,GAAG,MAAM,CAAC,OAAO,UAAU,CAAC,CAAC;AAE7C,MAAM,MAAM,aAAa,GAAG,IAAI,GAAG;IAAE,OAAO,EAAE,MAAM,CAAA;CAAE,CAAC;AAEvD;;;;GAIG;AACH,MAAM,MAAM,WAAW,GAAG,aAAa,GAAG;IACxC,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACpC,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,EAAE,CAAC,CAAC;CAClC,CAAC"}
@@ -1,3 +1,3 @@
1
1
  /*! Upstart.gg - Copyright (C) 2024 Flippable - https://github.com/upstart-gg/upstart/blob/main/LICENSE */
2
2
 
3
- import{a}from"./chunk-VTBI7WX3.js";import"./chunk-EYPREFMH.js";import"./chunk-TATG6SFZ.js";import"./chunk-NLEWXPVM.js";import"./chunk-L42YBY5I.js";import"./chunk-AQPN5SE2.js";import"./chunk-DQXDGV67.js";import"./chunk-IFEIRRZ2.js";import"./chunk-7DMUDZ4H.js";import"./chunk-LSPN22SI.js";import"./chunk-QSZWDE3D.js";import"./chunk-ETYYRWLK.js";import"./chunk-4TH3C76A.js";import"./chunk-FKNNTHWX.js";import"./chunk-JS4K5JRM.js";import"./chunk-WU6Q4WYD.js";import"./chunk-QISTDGPP.js";import"./chunk-LFQZRGHS.js";import"./chunk-SLRU4CT6.js";import"./chunk-MKIXZXWS.js";import"./chunk-TTTXV7TJ.js";import"./chunk-UHF6IEKV.js";import"./chunk-LGP6GWIY.js";import"./chunk-X43MB5WD.js";import"./chunk-NNI225RG.js";import"./chunk-ZQGNYK5I.js";import"./chunk-KHFNN4P3.js";import"./chunk-3EM3B4DX.js";import"./chunk-BZGNY7LB.js";import"./chunk-IIFTGWFZ.js";import"./chunk-MPBYGS6W.js";import"./chunk-OIOYMECS.js";import"./chunk-VPFCY4DH.js";import"./chunk-TWBY2GOR.js";import"./chunk-CT3EI7YN.js";import"./chunk-6WCGUAQN.js";import"./chunk-T4LMBG2G.js";import"./chunk-C3VGP4CA.js";import"./chunk-ACVLF55Q.js";import"./chunk-6FITVVZX.js";import"./chunk-YIFNKP4J.js";import"./chunk-UU2MSQXY.js";import"./chunk-T3LIA4YB.js";import"./chunk-RGLVKILY.js";import"./chunk-YBGPPF7T.js";import"./chunk-VZPXXFVX.js";import"./chunk-UMHXXXVP.js";import"./chunk-2IYSJYNE.js";import"./chunk-E22E4XWE.js";import"./chunk-EJGNYD4V.js";import"./chunk-5N6MBJJ4.js";import"./chunk-SFKZAUPW.js";import"./chunk-VGRYSAXA.js";import"./chunk-I46VBMLF.js";export{a as pageSchema};
3
+ import{a}from"./chunk-YFFTZ5T6.js";import"./chunk-EYPREFMH.js";import"./chunk-TATG6SFZ.js";import"./chunk-NLEWXPVM.js";import"./chunk-L42YBY5I.js";import"./chunk-AQPN5SE2.js";import"./chunk-DQXDGV67.js";import"./chunk-IFEIRRZ2.js";import"./chunk-7DMUDZ4H.js";import"./chunk-LSPN22SI.js";import"./chunk-QSZWDE3D.js";import"./chunk-ETYYRWLK.js";import"./chunk-4TH3C76A.js";import"./chunk-FKNNTHWX.js";import"./chunk-JS4K5JRM.js";import"./chunk-WU6Q4WYD.js";import"./chunk-QISTDGPP.js";import"./chunk-LFQZRGHS.js";import"./chunk-SLRU4CT6.js";import"./chunk-MKIXZXWS.js";import"./chunk-TTTXV7TJ.js";import"./chunk-UHF6IEKV.js";import"./chunk-LGP6GWIY.js";import"./chunk-X43MB5WD.js";import"./chunk-NNI225RG.js";import"./chunk-ZQGNYK5I.js";import"./chunk-KHFNN4P3.js";import"./chunk-3EM3B4DX.js";import"./chunk-BZGNY7LB.js";import"./chunk-IIFTGWFZ.js";import"./chunk-MPBYGS6W.js";import"./chunk-OIOYMECS.js";import"./chunk-VPFCY4DH.js";import"./chunk-TWBY2GOR.js";import"./chunk-CT3EI7YN.js";import"./chunk-6WCGUAQN.js";import"./chunk-T4LMBG2G.js";import"./chunk-C3VGP4CA.js";import"./chunk-ACVLF55Q.js";import"./chunk-6FITVVZX.js";import"./chunk-YIFNKP4J.js";import"./chunk-UU2MSQXY.js";import"./chunk-T3LIA4YB.js";import"./chunk-RGLVKILY.js";import"./chunk-YBGPPF7T.js";import"./chunk-VZPXXFVX.js";import"./chunk-UMHXXXVP.js";import"./chunk-2IYSJYNE.js";import"./chunk-E22E4XWE.js";import"./chunk-EJGNYD4V.js";import"./chunk-5N6MBJJ4.js";import"./chunk-SFKZAUPW.js";import"./chunk-VGRYSAXA.js";import"./chunk-I46VBMLF.js";export{a as pageSchema};
@@ -204,13 +204,63 @@ export declare const siteSchema: import("@sinclair/typebox").TObject<{
204
204
  id: import("@sinclair/typebox").TString;
205
205
  label: import("@sinclair/typebox").TString;
206
206
  path: import("@sinclair/typebox").TString;
207
- tags: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>;
208
- status: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"draft" | "published">>;
209
- sectionsPlan: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
210
- id: import("@sinclair/typebox").TString;
211
- name: import("@sinclair/typebox").TString;
207
+ attributes: import("@sinclair/typebox").TObject<{
208
+ colorPreset: import("@sinclair/typebox").TObject<{
209
+ color: import("@sinclair/typebox").TUnsafe<string>;
210
+ gradientDirection: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"bg-gradient-to-t" | "bg-gradient-to-r" | "bg-gradient-to-b" | "bg-gradient-to-l" | "bg-gradient-to-tl" | "bg-gradient-to-tr" | "bg-gradient-to-br" | "bg-gradient-to-bl">>;
211
+ }>;
212
+ tags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
213
+ path: import("@sinclair/typebox").TString;
214
+ queries: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
215
+ queryId: import("@sinclair/typebox").TString;
216
+ alias: import("@sinclair/typebox").TString;
217
+ params: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
218
+ field: import("@sinclair/typebox").TString;
219
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"eq">, import("@sinclair/typebox").TLiteral<"ne">, import("@sinclair/typebox").TLiteral<"contains">, import("@sinclair/typebox").TLiteral<"notContains">, import("@sinclair/typebox").TLiteral<"startsWith">, import("@sinclair/typebox").TLiteral<"notStartsWith">, import("@sinclair/typebox").TLiteral<"endsWith">, import("@sinclair/typebox").TLiteral<"notEndsWith">]>;
220
+ value: import("@sinclair/typebox").TString;
221
+ }>, import("@sinclair/typebox").TObject<{
222
+ field: import("@sinclair/typebox").TString;
223
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"eq">, import("@sinclair/typebox").TLiteral<"ne">, import("@sinclair/typebox").TLiteral<"lt">, import("@sinclair/typebox").TLiteral<"lte">, import("@sinclair/typebox").TLiteral<"gt">, import("@sinclair/typebox").TLiteral<"gte">]>;
224
+ value: import("@sinclair/typebox").TNumber;
225
+ }>, import("@sinclair/typebox").TObject<{
226
+ field: import("@sinclair/typebox").TString;
227
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"before">, import("@sinclair/typebox").TLiteral<"after">]>;
228
+ value: import("@sinclair/typebox").TString;
229
+ }>, import("@sinclair/typebox").TObject<{
230
+ field: import("@sinclair/typebox").TString;
231
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"beforeNow">, import("@sinclair/typebox").TLiteral<"afterNow">]>;
232
+ value: import("@sinclair/typebox").TNull;
233
+ }>, import("@sinclair/typebox").TObject<{
234
+ field: import("@sinclair/typebox").TString;
235
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"contains">, import("@sinclair/typebox").TLiteral<"notContains">, import("@sinclair/typebox").TLiteral<"containsAll">, import("@sinclair/typebox").TLiteral<"containsAny">, import("@sinclair/typebox").TLiteral<"notContainsAny">]>;
236
+ value: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>;
237
+ }>, import("@sinclair/typebox").TObject<{
238
+ field: import("@sinclair/typebox").TString;
239
+ op: import("@sinclair/typebox").TLiteral<"eq">;
240
+ value: import("@sinclair/typebox").TBoolean;
241
+ }>]>>>;
242
+ }>>>;
243
+ title: import("@sinclair/typebox").TString;
212
244
  description: import("@sinclair/typebox").TString;
213
- }>>;
245
+ keywords: import("@sinclair/typebox").TString;
246
+ ogImage: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
247
+ src: import("@sinclair/typebox").TString;
248
+ alt: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
249
+ fit: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"object-none">, import("@sinclair/typebox").TLiteral<"object-contain">, import("@sinclair/typebox").TLiteral<"object-cover">, import("@sinclair/typebox").TLiteral<"object-fill">, import("@sinclair/typebox").TLiteral<"object-scale-down">]>>;
250
+ position: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"object-top">, import("@sinclair/typebox").TLiteral<"object-center">, import("@sinclair/typebox").TLiteral<"object-bottom">, import("@sinclair/typebox").TLiteral<"object-left">, import("@sinclair/typebox").TLiteral<"object-right">, import("@sinclair/typebox").TLiteral<"object-top-left">, import("@sinclair/typebox").TLiteral<"object-top-right">, import("@sinclair/typebox").TLiteral<"object-bottom-left">, import("@sinclair/typebox").TLiteral<"object-bottom-right">]>>;
251
+ }>>;
252
+ robotsIndexing: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
253
+ language: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"ar" | "zh" | "cs" | "nl" | "en" | "fr" | "de" | "he" | "hi" | "it" | "ja" | "ko" | "fa" | "pl" | "pt" | "ru" | "es" | "tr" | "vi">>;
254
+ additionalTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
255
+ headTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
256
+ bodyTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
257
+ }>> | import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
258
+ headTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
259
+ bodyTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
260
+ }>>;
261
+ lastUpdated: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
262
+ }>;
263
+ status: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"draft" | "published">>;
214
264
  }>>;
215
265
  sitePrompt: import("@sinclair/typebox").TString;
216
266
  }>;
@@ -422,13 +472,63 @@ declare const siteAndPagesSchema: import("@sinclair/typebox").TObject<{
422
472
  id: import("@sinclair/typebox").TString;
423
473
  label: import("@sinclair/typebox").TString;
424
474
  path: import("@sinclair/typebox").TString;
425
- tags: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>;
426
- status: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"draft" | "published">>;
427
- sectionsPlan: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
428
- id: import("@sinclair/typebox").TString;
429
- name: import("@sinclair/typebox").TString;
475
+ attributes: import("@sinclair/typebox").TObject<{
476
+ colorPreset: import("@sinclair/typebox").TObject<{
477
+ color: import("@sinclair/typebox").TUnsafe<string>;
478
+ gradientDirection: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"bg-gradient-to-t" | "bg-gradient-to-r" | "bg-gradient-to-b" | "bg-gradient-to-l" | "bg-gradient-to-tl" | "bg-gradient-to-tr" | "bg-gradient-to-br" | "bg-gradient-to-bl">>;
479
+ }>;
480
+ tags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
481
+ path: import("@sinclair/typebox").TString;
482
+ queries: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
483
+ queryId: import("@sinclair/typebox").TString;
484
+ alias: import("@sinclair/typebox").TString;
485
+ params: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
486
+ field: import("@sinclair/typebox").TString;
487
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"eq">, import("@sinclair/typebox").TLiteral<"ne">, import("@sinclair/typebox").TLiteral<"contains">, import("@sinclair/typebox").TLiteral<"notContains">, import("@sinclair/typebox").TLiteral<"startsWith">, import("@sinclair/typebox").TLiteral<"notStartsWith">, import("@sinclair/typebox").TLiteral<"endsWith">, import("@sinclair/typebox").TLiteral<"notEndsWith">]>;
488
+ value: import("@sinclair/typebox").TString;
489
+ }>, import("@sinclair/typebox").TObject<{
490
+ field: import("@sinclair/typebox").TString;
491
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"eq">, import("@sinclair/typebox").TLiteral<"ne">, import("@sinclair/typebox").TLiteral<"lt">, import("@sinclair/typebox").TLiteral<"lte">, import("@sinclair/typebox").TLiteral<"gt">, import("@sinclair/typebox").TLiteral<"gte">]>;
492
+ value: import("@sinclair/typebox").TNumber;
493
+ }>, import("@sinclair/typebox").TObject<{
494
+ field: import("@sinclair/typebox").TString;
495
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"before">, import("@sinclair/typebox").TLiteral<"after">]>;
496
+ value: import("@sinclair/typebox").TString;
497
+ }>, import("@sinclair/typebox").TObject<{
498
+ field: import("@sinclair/typebox").TString;
499
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"beforeNow">, import("@sinclair/typebox").TLiteral<"afterNow">]>;
500
+ value: import("@sinclair/typebox").TNull;
501
+ }>, import("@sinclair/typebox").TObject<{
502
+ field: import("@sinclair/typebox").TString;
503
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"contains">, import("@sinclair/typebox").TLiteral<"notContains">, import("@sinclair/typebox").TLiteral<"containsAll">, import("@sinclair/typebox").TLiteral<"containsAny">, import("@sinclair/typebox").TLiteral<"notContainsAny">]>;
504
+ value: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>;
505
+ }>, import("@sinclair/typebox").TObject<{
506
+ field: import("@sinclair/typebox").TString;
507
+ op: import("@sinclair/typebox").TLiteral<"eq">;
508
+ value: import("@sinclair/typebox").TBoolean;
509
+ }>]>>>;
510
+ }>>>;
511
+ title: import("@sinclair/typebox").TString;
430
512
  description: import("@sinclair/typebox").TString;
431
- }>>;
513
+ keywords: import("@sinclair/typebox").TString;
514
+ ogImage: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
515
+ src: import("@sinclair/typebox").TString;
516
+ alt: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
517
+ fit: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"object-none">, import("@sinclair/typebox").TLiteral<"object-contain">, import("@sinclair/typebox").TLiteral<"object-cover">, import("@sinclair/typebox").TLiteral<"object-fill">, import("@sinclair/typebox").TLiteral<"object-scale-down">]>>;
518
+ position: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"object-top">, import("@sinclair/typebox").TLiteral<"object-center">, import("@sinclair/typebox").TLiteral<"object-bottom">, import("@sinclair/typebox").TLiteral<"object-left">, import("@sinclair/typebox").TLiteral<"object-right">, import("@sinclair/typebox").TLiteral<"object-top-left">, import("@sinclair/typebox").TLiteral<"object-top-right">, import("@sinclair/typebox").TLiteral<"object-bottom-left">, import("@sinclair/typebox").TLiteral<"object-bottom-right">]>>;
519
+ }>>;
520
+ robotsIndexing: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
521
+ language: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"ar" | "zh" | "cs" | "nl" | "en" | "fr" | "de" | "he" | "hi" | "it" | "ja" | "ko" | "fa" | "pl" | "pt" | "ru" | "es" | "tr" | "vi">>;
522
+ additionalTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
523
+ headTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
524
+ bodyTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
525
+ }>> | import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
526
+ headTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
527
+ bodyTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
528
+ }>>;
529
+ lastUpdated: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
530
+ }>;
531
+ status: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"draft" | "published">>;
432
532
  }>>;
433
533
  sitePrompt: import("@sinclair/typebox").TString;
434
534
  }>;
@@ -478,7 +578,6 @@ declare const siteAndPagesSchema: import("@sinclair/typebox").TObject<{
478
578
  propsMapping: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{}>>;
479
579
  }>>;
480
580
  }>>;
481
- tags: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>;
482
581
  attributes: import("@sinclair/typebox").TObject<{
483
582
  colorPreset: import("@sinclair/typebox").TObject<{
484
583
  color: import("@sinclair/typebox").TUnsafe<string>;
@@ -1 +1 @@
1
- {"version":3,"file":"site.d.ts","sourceRoot":"","sources":["../../src/shared/site.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAUtD,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAWrB,CAAC;AAEH,MAAM,MAAM,IAAI,GAAG,MAAM,CAAC,OAAO,UAAU,CAAC,CAAC;AAC7C,MAAM,MAAM,UAAU,GAAG,IAAI,CAAC,IAAI,EAAE,YAAY,CAAC,CAAC;AAElD,QAAA,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAGtB,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,MAAM,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAEnE,wBAAgB,iBAAiB,CAAC,UAAU,EAAE,MAAM,GAAG,kBAAkB,CAmwCxE"}
1
+ {"version":3,"file":"site.d.ts","sourceRoot":"","sources":["../../src/shared/site.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAUtD,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAWrB,CAAC;AAEH,MAAM,MAAM,IAAI,GAAG,MAAM,CAAC,OAAO,UAAU,CAAC,CAAC;AAC7C,MAAM,MAAM,UAAU,GAAG,IAAI,CAAC,IAAI,EAAE,YAAY,CAAC,CAAC;AAElD,QAAA,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAGtB,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,MAAM,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAEnE,wBAAgB,iBAAiB,CAAC,UAAU,EAAE,MAAM,GAAG,kBAAkB,CA+vCxE"}
@@ -1,3 +1,3 @@
1
1
  /*! Upstart.gg - Copyright (C) 2024 Flippable - https://github.com/upstart-gg/upstart/blob/main/LICENSE */
2
2
 
3
- import{d as m}from"./chunk-C2S243PB.js";import{b as o,d as c}from"./chunk-HHO3ONTQ.js";import{d}from"./chunk-6K3KZDFC.js";import{a as n}from"./chunk-VTBI7WX3.js";import{a as p}from"./chunk-ZJNA4QQC.js";import{b as s,c as a,d as l}from"./chunk-EYPREFMH.js";import"./chunk-TATG6SFZ.js";import{a as t}from"./chunk-NLEWXPVM.js";import"./chunk-L42YBY5I.js";import"./chunk-AQPN5SE2.js";import"./chunk-DQXDGV67.js";import"./chunk-IFEIRRZ2.js";import"./chunk-7DMUDZ4H.js";import"./chunk-LSPN22SI.js";import"./chunk-QSZWDE3D.js";import"./chunk-ETYYRWLK.js";import"./chunk-4TH3C76A.js";import"./chunk-FKNNTHWX.js";import"./chunk-JS4K5JRM.js";import"./chunk-WU6Q4WYD.js";import"./chunk-QISTDGPP.js";import"./chunk-LFQZRGHS.js";import"./chunk-SLRU4CT6.js";import"./chunk-MKIXZXWS.js";import"./chunk-TTTXV7TJ.js";import"./chunk-UHF6IEKV.js";import"./chunk-LGP6GWIY.js";import"./chunk-X43MB5WD.js";import"./chunk-NNI225RG.js";import"./chunk-ZQGNYK5I.js";import"./chunk-KHFNN4P3.js";import"./chunk-3EM3B4DX.js";import"./chunk-BZGNY7LB.js";import"./chunk-IIFTGWFZ.js";import"./chunk-MPBYGS6W.js";import"./chunk-OIOYMECS.js";import"./chunk-VPFCY4DH.js";import"./chunk-TWBY2GOR.js";import"./chunk-CT3EI7YN.js";import"./chunk-6WCGUAQN.js";import"./chunk-T4LMBG2G.js";import"./chunk-C3VGP4CA.js";import"./chunk-ACVLF55Q.js";import"./chunk-6FITVVZX.js";import"./chunk-YIFNKP4J.js";import"./chunk-UU2MSQXY.js";import"./chunk-T3LIA4YB.js";import"./chunk-RGLVKILY.js";import"./chunk-YBGPPF7T.js";import"./chunk-VZPXXFVX.js";import"./chunk-UMHXXXVP.js";import"./chunk-2IYSJYNE.js";import"./chunk-E22E4XWE.js";import"./chunk-EJGNYD4V.js";import{c as r}from"./chunk-5N6MBJJ4.js";import"./chunk-SFKZAUPW.js";import"./chunk-VGRYSAXA.js";import"./chunk-I46VBMLF.js";import{Type as i}from"@sinclair/typebox";var b=i.Object({id:i.String(),label:i.String(),hostname:i.String(),attributes:s,datasources:r,datarecords:d,themes:i.Array(o),theme:o,sitemap:m,sitePrompt:p}),v=i.Object({site:b,pages:i.Array(n)});function w(u){let e=0;return{site:{id:crypto.randomUUID(),label:"New site",hostname:"example.com",sitePrompt:u,theme:c,themes:[],sitemap:[{id:"_default_",label:"First page with really really long name that should be truncated",path:"/",tags:[],sectionsPlan:[]},{id:"_page_2",label:"Second page with really really long name that should be truncated",path:"/secondPage",tags:[],sectionsPlan:[]}],attributes:l(),datarecords:[{id:"a7f26d80-d68e-4b7a-a4a3-e41c454670ce",label:"Simple Datarecord",schema:{type:"object",properties:{lastName:{type:"string",title:"Last Name","ui:placeholder":"Enter your last name",metadata:{order:0}},firstName:{type:"string",title:"First Name","ui:placeholder":"Enter your first name",metadata:{order:1}}}},provider:"internal"},{id:"aacfe76d-4309-466c-83ad-fda8b02b043d",label:"Complex Datarecord",schema:{type:"object",required:["firstName","lastName"],properties:{lastName:{type:"string",title:"Last Name",metadata:{order:1}},firstName:{type:"string",title:"First Name",metadata:{order:0}},multiline2:{type:"string",title:"Message",metadata:{order:4,"ui:multiline":!0},maxLength:30,minLength:1},age:{type:"number",title:"age",minimum:1,metadata:{order:2}},url:{type:"string",title:"personal web site",format:"uri",metadata:{order:3,"ui:placeholder":"https://mysite.example"},description:"your personal website url"},agree:{type:"boolean",title:"agree",metadata:{order:5}},favoriteColor:{enum:["blue","green","red","yellow","purple"],type:"string",title:"Favorite Color",metadata:{order:6},description:"Select your favorite color"},favoriteSeason:{enum:["spring","summer","autumn","winter"],type:"string",title:"Favorite Season",metadata:{order:6,"ui:widget":"radio"},description:"Select your favorite season"},favoriteMusic:{enum:["technology","politics","sports","music","movies"],type:"string",title:"Interests",metadata:{order:6,"ui:widget":"checkbox"},description:"What kind of subjects are you interested in?"},registrationDate:{type:"string",title:"Registration date",format:"date",metadata:{order:7}},email:{type:"string",title:"Email",format:"email",metadata:{order:8}},address:{type:"string",title:"Address",metadata:{order:9}},multiline1:{type:"string",title:"some text",metadata:{order:10,"ui:multiline":!0}},datetimes:{type:"string",title:"A datetime",format:"date-time",metadata:{order:11}}}},provider:"internal"}],datasources:[{id:"employees",label:"Company employees",provider:"custom",schema:{type:"array",items:{type:"object",properties:{$id:{type:"string",title:"Id",format:"nanoid"},$publicationDate:{type:"string",format:"date-time",title:"Publication Date"},$lastModificationDate:{type:"string",format:"date-time",title:"Last Modification Date"},$slug:{type:"string",format:"slug",title:"Slug"},avatarUrl:{title:"Avatar URL",type:"string",format:"uri",default:"https://placehold.co/100x100"},firstName:{type:"string",title:"First Name"},lastName:{type:"string",title:"Last Name"},email:{type:"string",format:"email",title:"Email"},height:{type:"number",title:"Height"},admin:{type:"boolean",title:"Is Admin"},startedOn:{type:"string",format:"date",title:"Started On"},tags:{type:"array",items:{type:"string"},title:"Tags"}},required:["firstName","lastName","email","$id","$slug","$publicationDate","$lastModificationDate"]},examples:[{$id:"example-1",$publicationDate:"2023-01-01T00:00:00Z",$lastModificationDate:"2023-01-01T00:00:00Z",$slug:"john-doe",firstName:"John",lastName:"Doe",email:"john.doe@example.com",avatarUrl:"https://placehold.co/100x100",height:180,admin:!1,startedOn:"2020-01-01",tags:["developer","javascript"]},{$id:"example-2",$publicationDate:"2023-01-02T00:00:00Z",$lastModificationDate:"2023-01-02T00:00:00Z",$slug:"jane-smith",firstName:"Jane",lastName:"Smith",email:"jane.smith@example.com",avatarUrl:"https://placehold.co/100x100",height:165,admin:!1,startedOn:"2020-01-01",tags:["designer","figma"]},{$id:"example-3",$publicationDate:"2023-01-03T00:00:00Z",$lastModificationDate:"2023-01-03T00:00:00Z",$slug:"alice-johnson",firstName:"Alice",lastName:"Johnson",email:"alice.johnson@example.com",avatarUrl:"https://placehold.co/100x100",height:170,admin:!1,startedOn:"2020-01-01",tags:["developer","react"]},{$id:"example-4",$publicationDate:"2023-01-04T00:00:00Z",$lastModificationDate:"2023-01-04T00:00:00Z",$slug:"bob-brown",firstName:"Bob",lastName:"Brown",email:"bob.brown@example.com",avatarUrl:"https://placehold.co/100x100",height:175,admin:!1,startedOn:"2020-01-01",tags:["developer","vue"]},{$id:"example-5",$publicationDate:"2023-01-05T00:00:00Z",$lastModificationDate:"2023-01-05T00:00:00Z",$slug:"charlie-white",firstName:"Charlie",lastName:"White",email:"charlie.white@example.com",avatarUrl:"https://placehold.co/100x100",height:160,admin:!1,startedOn:"2020-01-01",tags:["designer","figma"]}]},indexes:[{fields:["$id"],name:"idx_unique_id"},{fields:["$slug"],name:"idx_unique_slug"},{fields:["$publicationDate"],name:"idx_unique_publicationDate"},{fields:["$lastModificationDate"],name:"idx_unique_lastModificationDate"},{fields:["email"],name:"idx_unique_email"},{fields:["admin"],name:"idx_unique_admin"},{fields:["startedOn"],name:"idx_unique_startedOn"},{fields:["tags"],name:"idx_unique_tags"}]},{id:"employees2",label:"Company employees 2",provider:"custom",schema:{type:"array",items:{type:"object",properties:{$id:{type:"string",title:"ID"},$publicationDate:{type:"string",format:"date-time",title:"Publication Date"},$lastModificationDate:{type:"string",format:"date-time",title:"Last Modification Date"},$slug:{type:"string",title:"Slug"},firstName:{type:"string",title:"First Name"},lastName:{type:"string",title:"Last Name"},tags:{type:"array",items:{type:"string"},title:"Tags"}},required:["firstName","lastName","$id","$slug","$publicationDate","$lastModificationDate"]}},indexes:[{fields:["$id"],name:"idx_unique_id"},{fields:["$slug"],name:"idx_unique_slug"},{fields:["$publicationDate"],name:"idx_unique_publicationDate"},{fields:["$lastModificationDate"],name:"idx_unique_lastModificationDate"},{fields:["lastName"],name:"idx_unique_lastName"},{fields:["tags"],name:"idx_unique_tags"}]}]},pages:[{id:"_default_",label:"First page with really really long name that should be truncated",path:"/blog/:slug",sections:[{id:`s_${t()}`,label:"Top",order:++e,props:{variant:"navbar"},bricks:[{id:t(),type:"navbar",props:{brand:"My Site",navigation:{staticItems:[{urlOrPageId:"/about"},{urlOrPageId:"/contact"}]}}}]},{id:`s_${t()}`,order:++e,label:"Media",props:{},bricks:[{id:t(),type:"video",props:{url:"https://www.youtube.com/watch?v=dQw4w9WgXcQ"}},{id:t(),type:"image",props:{image:{alt:"Sample Image"},height:"200px"}},{id:t(),type:"icon",props:{icon:"mdi:heart"}}]},{id:`s_${t()}`,order:++e,label:"Containers",props:{},bricks:[{id:t(),type:"box",props:{loop:{over:"allEmployees"},direction:"flex-row",$children:[{id:t(),type:"button",props:{label:"Button #1"}},{id:t(),type:"button",props:{label:"Button #2"}},{id:t(),type:"button",props:{label:"Button #3"}},{id:t(),type:"button",props:{label:"Button #4"}}]}},{id:t(),type:"box",props:{direction:"flex-col",datasource:{id:"employees"},$children:[{id:t(),type:"text",props:{content:"Hello this is the first text in the dynamic box.<br />I'm on a new line explicitly.<br />I'm the third line and I'm the longest of them all! Yeah!"}},{id:t(),type:"button",props:{label:"Button #1 in dynamic box with a {{$slug}}"}},{id:t(),type:"button",props:{label:"Small label"}},{id:t(),type:"button",props:{label:"Button #3 with the largest label"}}]}}]},{id:`s_${t()}`,order:++e,label:"Dynamic",bricks:[{type:"box",props:{alignSelf:"self-auto",datasource:{},$children:[]},id:t()}],props:{}},{id:`s_${t()}`,order:++e,label:"Section 8",bricks:[{type:"form",props:{alignSelf:"self-auto",color:"base100",align:"vertical",padding:"p-4",fontSize:"inherit",button:{size:"block",rounding:"rounded-md",border:{width:"border",rounding:"rounded-md"}},title:"My form",buttonLabel:"Submit",successMessage:"Thank you for your submission!",errorMessage:"There was an error submitting the form. Please try again later.",height:"104.4px"},id:"brick-OKkJLZl"}],props:{}},{id:`s_${t()}`,label:"Testimonial",order:++e,props:{justifyContent:"justify-center",alignItems:"items-start"},bricks:[{id:t(),type:"box",props:{alignSelf:"self-auto",datasource:{id:"employees2"},$children:[{id:t(),type:"testimonials",props:{testimonials:{author:"{{firstName}} {{lastName}}",text:"{{testimonial}}",socialIcon:"{{icon}}",company:"{{company}}"}}}]}},{type:"testimonials",props:{alignSelf:"self-auto",orientation:"horizontal",testimonials:[{author:"Billy Gates",text:"Upstart rocks! I love the flexibility and ease of use. Can't wait to see more features!",socialIcon:"mdi:twitter",company:"Microsoft"},{author:"Jeff Bezos",text:"Amazing product! Upstart has transformed the way I build websites. Highly recommend it!",socialIcon:"mdi:facebook",company:"Amazon"},{author:"Elon Musk",text:"Upstart is a game changer! The possibilities are endless.",socialIcon:"mdi:linkedin",company:"SpaceX"},{author:"Mark Zuckerberg",text:"Upstart is a fantastic tool for building modern websites. I'm impressed!",socialIcon:"mdi:facebook",company:"Meta"}]},id:"s_uuqtYzo"}]},{id:`s_${t()}`,label:"SocialLinks",order:++e,props:{justifyContent:"justify-center"},bricks:[{type:"social-links",props:{alignSelf:"self-auto",links:[{href:"https://facebook.com",label:"Facebook",icon:"mdi:facebook"},{href:"https://instagram.com",label:"Instagram",icon:"mdi:instagram"},{href:"https://x.com",label:"X",icon:"mdi:twitter"}]},id:t()},{type:"button",props:{alignSelf:"self-auto",label:"hey ho!",justifyContent:"justify-center",type:"button",height:"42px"},id:t()}]},{id:`s_${t()}`,label:"Form",order:++e,props:{justifyContent:"justify-center",alignItems:"items-start"},bricks:[{id:t(),type:"images-gallery",props:{}},{id:t(),type:"form",props:{padding:"p-4",datarecordId:"a7f26d80-d68e-4b7a-a4a3-e41c454670ce",title:"Simple Form",intro:"This is a simple form to collect user information.",button:{label:"Register",size:"block",borderRadius:"rounded-lg"}}},{id:t(),type:"form",props:{padding:"p-4",datarecordId:"aacfe76d-4309-466c-83ad-fda8b02b043d",title:"Complex Form",intro:"This is a complex form with various field types.",button:{label:"Submit Form",borderRadius:"rounded-md",color:"btn-color-accent"}}}]},{id:`s_content-${t()}`,label:"Hero",order:++e,props:{minHeight:"400px"},bricks:[{id:`b_${t()}`,type:"hero",props:{}}]},{id:`s_content-${t()}`,label:"Content",order:++e,props:{},bricks:[{id:`b_${t()}`,type:"text",props:{text:"This is some sample content for the second page."}},{id:`b_${t()}`,type:"spacer",props:{width:"20px"}},{id:`b_${t()}`,type:"card",props:{title:"Welcome to My Site",text:"This is a sample card body. You can edit this content.",cardImage:{src:"https://placehold.co/300x200@2x/EEEEEE/333333/svg?text=Sample",alt:"Sample"}}}]},{id:`s_content-${t()}`,label:"Bottom",order:++e,props:{},bricks:[{id:`b_${t()}`,type:"footer",props:{linksSections:[{sectionTitle:"Links",links:[{title:"About",url:"/about"},{title:"Contact",url:"/contact"},{title:"Privacy Policy",url:"/privacy"}]},{sectionTitle:"Social",links:[{title:"Twitter",url:"https://twitter.com"},{title:"Facebook",url:"https://facebook.com"},{title:"Instagram",url:"https://instagram.com"}]},{sectionTitle:"Legal",links:[{title:"Terms of Service",url:"/terms"},{title:"Cookie Policy",url:"/cookies"}]},{sectionTitle:"Contact",links:[{title:"Email Us",url:"mailto:"},{title:"Support",url:"/support"}]}]}}]}],tags:[],attributes:a({path:"/blog/:slug",queries:[{queryId:"get-employee",alias:"employee",params:[{field:"$id",op:"eq",value:":slug"}]},{queryId:"get-employees",alias:"allEmployees"}]})},{id:"_page_2",label:"Second page with really really long name that should be truncated",path:"/secondPage",sections:[{id:`s_${t()}`,label:"Top",order:++e,props:{variant:"navbar"},bricks:[{id:t(),type:"navbar",props:{brand:"My Site",navigation:{staticItems:[{urlOrPageId:"/about"},{urlOrPageId:"/contact"}]}}}]},{id:`s_${t()}`,label:"Form",order:++e,props:{justifyContent:"justify-center"},bricks:[{id:t(),type:"form",props:{padding:"p-4",datarecordId:"a7f26d80-d68e-4b7a-a4a3-e41c454670ce",title:"Simple Form",intro:"This is a simple form to collect user information.",button:{label:"Register",position:"center",borderRadius:"rounded-lg"},align:"horizontal"}},{type:"button",props:{alignSelf:"self-auto",label:"My button",justifyContent:"justify-center",type:"button"},id:t()},{id:t(),type:"form",props:{padding:"p-4",datarecordId:"aacfe76d-4309-466c-83ad-fda8b02b043d",title:"Complex Form",intro:"This is a complex form with various field types.",button:{label:"Register 2",borderRadius:"rounded-lg"}}}]},{id:`s_content-${t()}`,label:"Hero",order:++e,props:{minHeight:"400px"},bricks:[{id:`b_${t()}`,type:"hero",props:{color:"primary"}}]},{id:`s_content-${t()}`,label:"Content",order:++e,props:{},bricks:[{id:`b_${t()}`,type:"text",props:{preset:"subtle-accent",content:"Irure dolor sit amet, consectetur adipiscing elit."}},{id:`b_${t()}`,type:"vbox",props:{$children:[{id:`b_${t()}`,type:"text",props:{preset:"subtle-accent",content:"Irure dolor sit amet, consectetur adipiscing elit."}},{id:`b_${t()}`,type:"text",props:{preset:"subtle-accent",content:"Lorem ipsum dolor sit amet, consectetur adipiscing elit."}}]}},{id:`b_${t()}`,type:"text",props:{preset:"subtle-accent",content:"Irure dolor sit amet, consectetur adipiscing elit."}},{id:`b_${t()}`,type:"spacer",props:{}},{id:`b_${t()}`,type:"card",props:{title:"Welcome to My Site",text:"This is a sample card body. You can edit this content.",cardImage:{src:"https://placehold.co/300x200@2x/EEEEEE/333333/svg?text=Sample",alt:"Sample"}}}]},{id:`s_content-${t()}`,label:"Bottom",order:++e,props:{direction:"flex-row"},bricks:[{id:`b_${t()}`,type:"footer",props:{linksSections:[{sectionTitle:"Links",links:[{title:"About",url:"/about"},{title:"Contact",url:"/contact"},{title:"Privacy Policy",url:"/privacy"}]},{sectionTitle:"Social",links:[{title:"Twitter",url:"https://twitter.com"},{title:"Facebook",url:"https://facebook.com"},{title:"Instagram",url:"https://instagram.com"}]},{sectionTitle:"Legal",links:[{title:"Terms of Service",url:"/terms"},{title:"Cookie Policy",url:"/cookies"}]},{sectionTitle:"Contact",links:[{title:"Email Us",url:"mailto:"},{title:"Support",url:"/support"}]}]}}]}],tags:[],attributes:a()}]}}export{w as createEmptyConfig,b as siteSchema};
3
+ import{d as m}from"./chunk-L6WHBSRZ.js";import{b as o,d as c}from"./chunk-HHO3ONTQ.js";import{d}from"./chunk-UAQHU6L6.js";import{a as n}from"./chunk-YFFTZ5T6.js";import{a as p}from"./chunk-ZJNA4QQC.js";import{b as s,c as a,d as l}from"./chunk-EYPREFMH.js";import"./chunk-TATG6SFZ.js";import{a as t}from"./chunk-NLEWXPVM.js";import"./chunk-L42YBY5I.js";import"./chunk-AQPN5SE2.js";import"./chunk-DQXDGV67.js";import"./chunk-IFEIRRZ2.js";import"./chunk-7DMUDZ4H.js";import"./chunk-LSPN22SI.js";import"./chunk-QSZWDE3D.js";import"./chunk-ETYYRWLK.js";import"./chunk-4TH3C76A.js";import"./chunk-FKNNTHWX.js";import"./chunk-JS4K5JRM.js";import"./chunk-WU6Q4WYD.js";import"./chunk-QISTDGPP.js";import"./chunk-LFQZRGHS.js";import"./chunk-SLRU4CT6.js";import"./chunk-MKIXZXWS.js";import"./chunk-TTTXV7TJ.js";import"./chunk-UHF6IEKV.js";import"./chunk-LGP6GWIY.js";import"./chunk-X43MB5WD.js";import"./chunk-NNI225RG.js";import"./chunk-ZQGNYK5I.js";import"./chunk-KHFNN4P3.js";import"./chunk-3EM3B4DX.js";import"./chunk-BZGNY7LB.js";import"./chunk-IIFTGWFZ.js";import"./chunk-MPBYGS6W.js";import"./chunk-OIOYMECS.js";import"./chunk-VPFCY4DH.js";import"./chunk-TWBY2GOR.js";import"./chunk-CT3EI7YN.js";import"./chunk-6WCGUAQN.js";import"./chunk-T4LMBG2G.js";import"./chunk-C3VGP4CA.js";import"./chunk-ACVLF55Q.js";import"./chunk-6FITVVZX.js";import"./chunk-YIFNKP4J.js";import"./chunk-UU2MSQXY.js";import"./chunk-T3LIA4YB.js";import"./chunk-RGLVKILY.js";import"./chunk-YBGPPF7T.js";import"./chunk-VZPXXFVX.js";import"./chunk-UMHXXXVP.js";import"./chunk-2IYSJYNE.js";import"./chunk-E22E4XWE.js";import"./chunk-EJGNYD4V.js";import{c as r}from"./chunk-5N6MBJJ4.js";import"./chunk-SFKZAUPW.js";import"./chunk-VGRYSAXA.js";import"./chunk-I46VBMLF.js";import{Type as i}from"@sinclair/typebox";var b=i.Object({id:i.String(),label:i.String(),hostname:i.String(),attributes:s,datasources:r,datarecords:d,themes:i.Array(o),theme:o,sitemap:m,sitePrompt:p}),v=i.Object({site:b,pages:i.Array(n)});function w(u){let e=0;return{site:{id:crypto.randomUUID(),label:"New site",hostname:"example.com",sitePrompt:u,theme:c,themes:[],sitemap:[{id:"_default_",label:"First page with really really long name that should be truncated",path:"/",attributes:a({path:"/"})},{id:"_page_2",label:"Second page with really really long name that should be truncated",path:"/secondPage",attributes:a({path:"/secondPage"})}],attributes:l(),datarecords:[{id:"a7f26d80-d68e-4b7a-a4a3-e41c454670ce",label:"Simple Datarecord",schema:{type:"object",properties:{lastName:{type:"string",title:"Last Name","ui:placeholder":"Enter your last name",metadata:{order:0}},firstName:{type:"string",title:"First Name","ui:placeholder":"Enter your first name",metadata:{order:1}}}},provider:"internal"},{id:"aacfe76d-4309-466c-83ad-fda8b02b043d",label:"Complex Datarecord",schema:{type:"object",required:["firstName","lastName"],properties:{lastName:{type:"string",title:"Last Name",metadata:{order:1}},firstName:{type:"string",title:"First Name",metadata:{order:0}},multiline2:{type:"string",title:"Message",metadata:{order:4,"ui:multiline":!0},maxLength:30,minLength:1},age:{type:"number",title:"age",minimum:1,metadata:{order:2}},url:{type:"string",title:"personal web site",format:"uri",metadata:{order:3,"ui:placeholder":"https://mysite.example"},description:"your personal website url"},agree:{type:"boolean",title:"agree",metadata:{order:5}},favoriteColor:{enum:["blue","green","red","yellow","purple"],type:"string",title:"Favorite Color",metadata:{order:6},description:"Select your favorite color"},favoriteSeason:{enum:["spring","summer","autumn","winter"],type:"string",title:"Favorite Season",metadata:{order:6,"ui:widget":"radio"},description:"Select your favorite season"},favoriteMusic:{enum:["technology","politics","sports","music","movies"],type:"string",title:"Interests",metadata:{order:6,"ui:widget":"checkbox"},description:"What kind of subjects are you interested in?"},registrationDate:{type:"string",title:"Registration date",format:"date",metadata:{order:7}},email:{type:"string",title:"Email",format:"email",metadata:{order:8}},address:{type:"string",title:"Address",metadata:{order:9}},multiline1:{type:"string",title:"some text",metadata:{order:10,"ui:multiline":!0}},datetimes:{type:"string",title:"A datetime",format:"date-time",metadata:{order:11}}}},provider:"internal"}],datasources:[{id:"employees",label:"Company employees",provider:"custom",schema:{type:"array",items:{type:"object",properties:{$id:{type:"string",title:"Id",format:"nanoid"},$publicationDate:{type:"string",format:"date-time",title:"Publication Date"},$lastModificationDate:{type:"string",format:"date-time",title:"Last Modification Date"},$slug:{type:"string",format:"slug",title:"Slug"},avatarUrl:{title:"Avatar URL",type:"string",format:"uri",default:"https://placehold.co/100x100"},firstName:{type:"string",title:"First Name"},lastName:{type:"string",title:"Last Name"},email:{type:"string",format:"email",title:"Email"},height:{type:"number",title:"Height"},admin:{type:"boolean",title:"Is Admin"},startedOn:{type:"string",format:"date",title:"Started On"},tags:{type:"array",items:{type:"string"},title:"Tags"}},required:["firstName","lastName","email","$id","$slug","$publicationDate","$lastModificationDate"]},examples:[{$id:"example-1",$publicationDate:"2023-01-01T00:00:00Z",$lastModificationDate:"2023-01-01T00:00:00Z",$slug:"john-doe",firstName:"John",lastName:"Doe",email:"john.doe@example.com",avatarUrl:"https://placehold.co/100x100",height:180,admin:!1,startedOn:"2020-01-01",tags:["developer","javascript"]},{$id:"example-2",$publicationDate:"2023-01-02T00:00:00Z",$lastModificationDate:"2023-01-02T00:00:00Z",$slug:"jane-smith",firstName:"Jane",lastName:"Smith",email:"jane.smith@example.com",avatarUrl:"https://placehold.co/100x100",height:165,admin:!1,startedOn:"2020-01-01",tags:["designer","figma"]},{$id:"example-3",$publicationDate:"2023-01-03T00:00:00Z",$lastModificationDate:"2023-01-03T00:00:00Z",$slug:"alice-johnson",firstName:"Alice",lastName:"Johnson",email:"alice.johnson@example.com",avatarUrl:"https://placehold.co/100x100",height:170,admin:!1,startedOn:"2020-01-01",tags:["developer","react"]},{$id:"example-4",$publicationDate:"2023-01-04T00:00:00Z",$lastModificationDate:"2023-01-04T00:00:00Z",$slug:"bob-brown",firstName:"Bob",lastName:"Brown",email:"bob.brown@example.com",avatarUrl:"https://placehold.co/100x100",height:175,admin:!1,startedOn:"2020-01-01",tags:["developer","vue"]},{$id:"example-5",$publicationDate:"2023-01-05T00:00:00Z",$lastModificationDate:"2023-01-05T00:00:00Z",$slug:"charlie-white",firstName:"Charlie",lastName:"White",email:"charlie.white@example.com",avatarUrl:"https://placehold.co/100x100",height:160,admin:!1,startedOn:"2020-01-01",tags:["designer","figma"]}]},indexes:[{fields:["$id"],name:"idx_unique_id"},{fields:["$slug"],name:"idx_unique_slug"},{fields:["$publicationDate"],name:"idx_unique_publicationDate"},{fields:["$lastModificationDate"],name:"idx_unique_lastModificationDate"},{fields:["email"],name:"idx_unique_email"},{fields:["admin"],name:"idx_unique_admin"},{fields:["startedOn"],name:"idx_unique_startedOn"},{fields:["tags"],name:"idx_unique_tags"}]},{id:"employees2",label:"Company employees 2",provider:"custom",schema:{type:"array",items:{type:"object",properties:{$id:{type:"string",title:"ID"},$publicationDate:{type:"string",format:"date-time",title:"Publication Date"},$lastModificationDate:{type:"string",format:"date-time",title:"Last Modification Date"},$slug:{type:"string",title:"Slug"},firstName:{type:"string",title:"First Name"},lastName:{type:"string",title:"Last Name"},tags:{type:"array",items:{type:"string"},title:"Tags"}},required:["firstName","lastName","$id","$slug","$publicationDate","$lastModificationDate"]}},indexes:[{fields:["$id"],name:"idx_unique_id"},{fields:["$slug"],name:"idx_unique_slug"},{fields:["$publicationDate"],name:"idx_unique_publicationDate"},{fields:["$lastModificationDate"],name:"idx_unique_lastModificationDate"},{fields:["lastName"],name:"idx_unique_lastName"},{fields:["tags"],name:"idx_unique_tags"}]}]},pages:[{id:"_default_",label:"First page with really really long name that should be truncated",path:"/blog/:slug",sections:[{id:`s_${t()}`,label:"Top",order:++e,props:{variant:"navbar"},bricks:[{id:t(),type:"navbar",props:{brand:"My Site",navigation:{staticItems:[{urlOrPageId:"/about"},{urlOrPageId:"/contact"}]}}}]},{id:`s_${t()}`,order:++e,label:"Media",props:{},bricks:[{id:t(),type:"video",props:{url:"https://www.youtube.com/watch?v=dQw4w9WgXcQ"}},{id:t(),type:"image",props:{image:{alt:"Sample Image"},height:"200px"}},{id:t(),type:"icon",props:{icon:"mdi:heart"}}]},{id:`s_${t()}`,order:++e,label:"Containers",props:{},bricks:[{id:t(),type:"box",props:{loop:{over:"allEmployees"},direction:"flex-row",$children:[{id:t(),type:"button",props:{label:"Button #1"}},{id:t(),type:"button",props:{label:"Button #2"}},{id:t(),type:"button",props:{label:"Button #3"}},{id:t(),type:"button",props:{label:"Button #4"}}]}},{id:t(),type:"box",props:{direction:"flex-col",datasource:{id:"employees"},$children:[{id:t(),type:"text",props:{content:"Hello this is the first text in the dynamic box.<br />I'm on a new line explicitly.<br />I'm the third line and I'm the longest of them all! Yeah!"}},{id:t(),type:"button",props:{label:"Button #1 in dynamic box with a {{$slug}}"}},{id:t(),type:"button",props:{label:"Small label"}},{id:t(),type:"button",props:{label:"Button #3 with the largest label"}}]}}]},{id:`s_${t()}`,order:++e,label:"Dynamic",bricks:[{type:"box",props:{alignSelf:"self-auto",datasource:{},$children:[]},id:t()}],props:{}},{id:`s_${t()}`,order:++e,label:"Section 8",bricks:[{type:"form",props:{alignSelf:"self-auto",color:"base100",align:"vertical",padding:"p-4",fontSize:"inherit",button:{size:"block",rounding:"rounded-md",border:{width:"border",rounding:"rounded-md"}},title:"My form",buttonLabel:"Submit",successMessage:"Thank you for your submission!",errorMessage:"There was an error submitting the form. Please try again later.",height:"104.4px"},id:"brick-OKkJLZl"}],props:{}},{id:`s_${t()}`,label:"Testimonial",order:++e,props:{justifyContent:"justify-center",alignItems:"items-start"},bricks:[{id:t(),type:"box",props:{alignSelf:"self-auto",datasource:{id:"employees2"},$children:[{id:t(),type:"testimonials",props:{testimonials:{author:"{{firstName}} {{lastName}}",text:"{{testimonial}}",socialIcon:"{{icon}}",company:"{{company}}"}}}]}},{type:"testimonials",props:{alignSelf:"self-auto",orientation:"horizontal",testimonials:[{author:"Billy Gates",text:"Upstart rocks! I love the flexibility and ease of use. Can't wait to see more features!",socialIcon:"mdi:twitter",company:"Microsoft"},{author:"Jeff Bezos",text:"Amazing product! Upstart has transformed the way I build websites. Highly recommend it!",socialIcon:"mdi:facebook",company:"Amazon"},{author:"Elon Musk",text:"Upstart is a game changer! The possibilities are endless.",socialIcon:"mdi:linkedin",company:"SpaceX"},{author:"Mark Zuckerberg",text:"Upstart is a fantastic tool for building modern websites. I'm impressed!",socialIcon:"mdi:facebook",company:"Meta"}]},id:"s_uuqtYzo"}]},{id:`s_${t()}`,label:"SocialLinks",order:++e,props:{justifyContent:"justify-center"},bricks:[{type:"social-links",props:{alignSelf:"self-auto",links:[{href:"https://facebook.com",label:"Facebook",icon:"mdi:facebook"},{href:"https://instagram.com",label:"Instagram",icon:"mdi:instagram"},{href:"https://x.com",label:"X",icon:"mdi:twitter"}]},id:t()},{type:"button",props:{alignSelf:"self-auto",label:"hey ho!",justifyContent:"justify-center",type:"button",height:"42px"},id:t()}]},{id:`s_${t()}`,label:"Form",order:++e,props:{justifyContent:"justify-center",alignItems:"items-start"},bricks:[{id:t(),type:"images-gallery",props:{}},{id:t(),type:"form",props:{padding:"p-4",datarecordId:"a7f26d80-d68e-4b7a-a4a3-e41c454670ce",title:"Simple Form",intro:"This is a simple form to collect user information.",button:{label:"Register",size:"block",borderRadius:"rounded-lg"}}},{id:t(),type:"form",props:{padding:"p-4",datarecordId:"aacfe76d-4309-466c-83ad-fda8b02b043d",title:"Complex Form",intro:"This is a complex form with various field types.",button:{label:"Submit Form",borderRadius:"rounded-md",color:"btn-color-accent"}}}]},{id:`s_content-${t()}`,label:"Hero",order:++e,props:{minHeight:"400px"},bricks:[{id:`b_${t()}`,type:"hero",props:{}}]},{id:`s_content-${t()}`,label:"Content",order:++e,props:{},bricks:[{id:`b_${t()}`,type:"text",props:{text:"This is some sample content for the second page."}},{id:`b_${t()}`,type:"spacer",props:{width:"20px"}},{id:`b_${t()}`,type:"card",props:{title:"Welcome to My Site",text:"This is a sample card body. You can edit this content.",cardImage:{src:"https://placehold.co/300x200@2x/EEEEEE/333333/svg?text=Sample",alt:"Sample"}}}]},{id:`s_content-${t()}`,label:"Bottom",order:++e,props:{},bricks:[{id:`b_${t()}`,type:"footer",props:{linksSections:[{sectionTitle:"Links",links:[{title:"About",url:"/about"},{title:"Contact",url:"/contact"},{title:"Privacy Policy",url:"/privacy"}]},{sectionTitle:"Social",links:[{title:"Twitter",url:"https://twitter.com"},{title:"Facebook",url:"https://facebook.com"},{title:"Instagram",url:"https://instagram.com"}]},{sectionTitle:"Legal",links:[{title:"Terms of Service",url:"/terms"},{title:"Cookie Policy",url:"/cookies"}]},{sectionTitle:"Contact",links:[{title:"Email Us",url:"mailto:"},{title:"Support",url:"/support"}]}]}}]}],attributes:a({path:"/blog/:slug",queries:[{queryId:"get-employee",alias:"employee",params:[{field:"$id",op:"eq",value:":slug"}]},{queryId:"get-employees",alias:"allEmployees"}]})},{id:"_page_2",label:"Second page with really really long name that should be truncated",path:"/secondPage",sections:[{id:`s_${t()}`,label:"Top",order:++e,props:{variant:"navbar"},bricks:[{id:t(),type:"navbar",props:{brand:"My Site",navigation:{staticItems:[{urlOrPageId:"/about"},{urlOrPageId:"/contact"}]}}}]},{id:`s_${t()}`,label:"Form",order:++e,props:{justifyContent:"justify-center"},bricks:[{id:t(),type:"form",props:{padding:"p-4",datarecordId:"a7f26d80-d68e-4b7a-a4a3-e41c454670ce",title:"Simple Form",intro:"This is a simple form to collect user information.",button:{label:"Register",position:"center",borderRadius:"rounded-lg"},align:"horizontal"}},{type:"button",props:{alignSelf:"self-auto",label:"My button",justifyContent:"justify-center",type:"button"},id:t()},{id:t(),type:"form",props:{padding:"p-4",datarecordId:"aacfe76d-4309-466c-83ad-fda8b02b043d",title:"Complex Form",intro:"This is a complex form with various field types.",button:{label:"Register 2",borderRadius:"rounded-lg"}}}]},{id:`s_content-${t()}`,label:"Hero",order:++e,props:{minHeight:"400px"},bricks:[{id:`b_${t()}`,type:"hero",props:{color:"primary"}}]},{id:`s_content-${t()}`,label:"Content",order:++e,props:{},bricks:[{id:`b_${t()}`,type:"text",props:{preset:"subtle-accent",content:"Irure dolor sit amet, consectetur adipiscing elit."}},{id:`b_${t()}`,type:"vbox",props:{$children:[{id:`b_${t()}`,type:"text",props:{preset:"subtle-accent",content:"Irure dolor sit amet, consectetur adipiscing elit."}},{id:`b_${t()}`,type:"text",props:{preset:"subtle-accent",content:"Lorem ipsum dolor sit amet, consectetur adipiscing elit."}}]}},{id:`b_${t()}`,type:"text",props:{preset:"subtle-accent",content:"Irure dolor sit amet, consectetur adipiscing elit."}},{id:`b_${t()}`,type:"spacer",props:{}},{id:`b_${t()}`,type:"card",props:{title:"Welcome to My Site",text:"This is a sample card body. You can edit this content.",cardImage:{src:"https://placehold.co/300x200@2x/EEEEEE/333333/svg?text=Sample",alt:"Sample"}}}]},{id:`s_content-${t()}`,label:"Bottom",order:++e,props:{direction:"flex-row"},bricks:[{id:`b_${t()}`,type:"footer",props:{linksSections:[{sectionTitle:"Links",links:[{title:"About",url:"/about"},{title:"Contact",url:"/contact"},{title:"Privacy Policy",url:"/privacy"}]},{sectionTitle:"Social",links:[{title:"Twitter",url:"https://twitter.com"},{title:"Facebook",url:"https://facebook.com"},{title:"Instagram",url:"https://instagram.com"}]},{sectionTitle:"Legal",links:[{title:"Terms of Service",url:"/terms"},{title:"Cookie Policy",url:"/cookies"}]},{sectionTitle:"Contact",links:[{title:"Email Us",url:"mailto:"},{title:"Support",url:"/support"}]}]}}]}],attributes:a()}]}}export{w as createEmptyConfig,b as siteSchema};
@@ -1,10 +1,66 @@
1
1
  import { type Static } from "@sinclair/typebox";
2
- export declare const pageInfoSchema: import("@sinclair/typebox").TObject<{
2
+ export declare const sitemapPageEntry: import("@sinclair/typebox").TObject<{
3
3
  id: import("@sinclair/typebox").TString;
4
4
  label: import("@sinclair/typebox").TString;
5
5
  path: import("@sinclair/typebox").TString;
6
+ attributes: import("@sinclair/typebox").TObject<{
7
+ colorPreset: import("@sinclair/typebox").TObject<{
8
+ color: import("@sinclair/typebox").TUnsafe<string>;
9
+ gradientDirection: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"bg-gradient-to-t" | "bg-gradient-to-r" | "bg-gradient-to-b" | "bg-gradient-to-l" | "bg-gradient-to-tl" | "bg-gradient-to-tr" | "bg-gradient-to-br" | "bg-gradient-to-bl">>;
10
+ }>;
11
+ tags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
12
+ path: import("@sinclair/typebox").TString;
13
+ queries: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
14
+ queryId: import("@sinclair/typebox").TString;
15
+ alias: import("@sinclair/typebox").TString;
16
+ params: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
17
+ field: import("@sinclair/typebox").TString;
18
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"eq">, import("@sinclair/typebox").TLiteral<"ne">, import("@sinclair/typebox").TLiteral<"contains">, import("@sinclair/typebox").TLiteral<"notContains">, import("@sinclair/typebox").TLiteral<"startsWith">, import("@sinclair/typebox").TLiteral<"notStartsWith">, import("@sinclair/typebox").TLiteral<"endsWith">, import("@sinclair/typebox").TLiteral<"notEndsWith">]>;
19
+ value: import("@sinclair/typebox").TString;
20
+ }>, import("@sinclair/typebox").TObject<{
21
+ field: import("@sinclair/typebox").TString;
22
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"eq">, import("@sinclair/typebox").TLiteral<"ne">, import("@sinclair/typebox").TLiteral<"lt">, import("@sinclair/typebox").TLiteral<"lte">, import("@sinclair/typebox").TLiteral<"gt">, import("@sinclair/typebox").TLiteral<"gte">]>;
23
+ value: import("@sinclair/typebox").TNumber;
24
+ }>, import("@sinclair/typebox").TObject<{
25
+ field: import("@sinclair/typebox").TString;
26
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"before">, import("@sinclair/typebox").TLiteral<"after">]>;
27
+ value: import("@sinclair/typebox").TString;
28
+ }>, import("@sinclair/typebox").TObject<{
29
+ field: import("@sinclair/typebox").TString;
30
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"beforeNow">, import("@sinclair/typebox").TLiteral<"afterNow">]>;
31
+ value: import("@sinclair/typebox").TNull;
32
+ }>, import("@sinclair/typebox").TObject<{
33
+ field: import("@sinclair/typebox").TString;
34
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"contains">, import("@sinclair/typebox").TLiteral<"notContains">, import("@sinclair/typebox").TLiteral<"containsAll">, import("@sinclair/typebox").TLiteral<"containsAny">, import("@sinclair/typebox").TLiteral<"notContainsAny">]>;
35
+ value: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>;
36
+ }>, import("@sinclair/typebox").TObject<{
37
+ field: import("@sinclair/typebox").TString;
38
+ op: import("@sinclair/typebox").TLiteral<"eq">;
39
+ value: import("@sinclair/typebox").TBoolean;
40
+ }>]>>>;
41
+ }>>>;
42
+ title: import("@sinclair/typebox").TString;
43
+ description: import("@sinclair/typebox").TString;
44
+ keywords: import("@sinclair/typebox").TString;
45
+ ogImage: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
46
+ src: import("@sinclair/typebox").TString;
47
+ alt: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
48
+ fit: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"object-none">, import("@sinclair/typebox").TLiteral<"object-contain">, import("@sinclair/typebox").TLiteral<"object-cover">, import("@sinclair/typebox").TLiteral<"object-fill">, import("@sinclair/typebox").TLiteral<"object-scale-down">]>>;
49
+ position: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"object-top">, import("@sinclair/typebox").TLiteral<"object-center">, import("@sinclair/typebox").TLiteral<"object-bottom">, import("@sinclair/typebox").TLiteral<"object-left">, import("@sinclair/typebox").TLiteral<"object-right">, import("@sinclair/typebox").TLiteral<"object-top-left">, import("@sinclair/typebox").TLiteral<"object-top-right">, import("@sinclair/typebox").TLiteral<"object-bottom-left">, import("@sinclair/typebox").TLiteral<"object-bottom-right">]>>;
50
+ }>>;
51
+ robotsIndexing: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
52
+ language: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"ar" | "zh" | "cs" | "nl" | "en" | "fr" | "de" | "he" | "hi" | "it" | "ja" | "ko" | "fa" | "pl" | "pt" | "ru" | "es" | "tr" | "vi">>;
53
+ additionalTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
54
+ headTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
55
+ bodyTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
56
+ }>> | import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
57
+ headTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
58
+ bodyTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
59
+ }>>;
60
+ lastUpdated: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
61
+ }>;
6
62
  }>;
7
- export type PageInfo = Static<typeof pageInfoSchema>;
63
+ export type SitemapPageEntry = Static<typeof sitemapPageEntry>;
8
64
  export declare const sectionsPlanSchema: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
9
65
  id: import("@sinclair/typebox").TString;
10
66
  name: import("@sinclair/typebox").TString;
@@ -14,25 +70,125 @@ export declare const sitemapEntry: import("@sinclair/typebox").TObject<{
14
70
  id: import("@sinclair/typebox").TString;
15
71
  label: import("@sinclair/typebox").TString;
16
72
  path: import("@sinclair/typebox").TString;
17
- tags: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>;
18
- status: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"draft" | "published">>;
19
- sectionsPlan: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
20
- id: import("@sinclair/typebox").TString;
21
- name: import("@sinclair/typebox").TString;
73
+ attributes: import("@sinclair/typebox").TObject<{
74
+ colorPreset: import("@sinclair/typebox").TObject<{
75
+ color: import("@sinclair/typebox").TUnsafe<string>;
76
+ gradientDirection: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"bg-gradient-to-t" | "bg-gradient-to-r" | "bg-gradient-to-b" | "bg-gradient-to-l" | "bg-gradient-to-tl" | "bg-gradient-to-tr" | "bg-gradient-to-br" | "bg-gradient-to-bl">>;
77
+ }>;
78
+ tags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
79
+ path: import("@sinclair/typebox").TString;
80
+ queries: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
81
+ queryId: import("@sinclair/typebox").TString;
82
+ alias: import("@sinclair/typebox").TString;
83
+ params: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
84
+ field: import("@sinclair/typebox").TString;
85
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"eq">, import("@sinclair/typebox").TLiteral<"ne">, import("@sinclair/typebox").TLiteral<"contains">, import("@sinclair/typebox").TLiteral<"notContains">, import("@sinclair/typebox").TLiteral<"startsWith">, import("@sinclair/typebox").TLiteral<"notStartsWith">, import("@sinclair/typebox").TLiteral<"endsWith">, import("@sinclair/typebox").TLiteral<"notEndsWith">]>;
86
+ value: import("@sinclair/typebox").TString;
87
+ }>, import("@sinclair/typebox").TObject<{
88
+ field: import("@sinclair/typebox").TString;
89
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"eq">, import("@sinclair/typebox").TLiteral<"ne">, import("@sinclair/typebox").TLiteral<"lt">, import("@sinclair/typebox").TLiteral<"lte">, import("@sinclair/typebox").TLiteral<"gt">, import("@sinclair/typebox").TLiteral<"gte">]>;
90
+ value: import("@sinclair/typebox").TNumber;
91
+ }>, import("@sinclair/typebox").TObject<{
92
+ field: import("@sinclair/typebox").TString;
93
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"before">, import("@sinclair/typebox").TLiteral<"after">]>;
94
+ value: import("@sinclair/typebox").TString;
95
+ }>, import("@sinclair/typebox").TObject<{
96
+ field: import("@sinclair/typebox").TString;
97
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"beforeNow">, import("@sinclair/typebox").TLiteral<"afterNow">]>;
98
+ value: import("@sinclair/typebox").TNull;
99
+ }>, import("@sinclair/typebox").TObject<{
100
+ field: import("@sinclair/typebox").TString;
101
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"contains">, import("@sinclair/typebox").TLiteral<"notContains">, import("@sinclair/typebox").TLiteral<"containsAll">, import("@sinclair/typebox").TLiteral<"containsAny">, import("@sinclair/typebox").TLiteral<"notContainsAny">]>;
102
+ value: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>;
103
+ }>, import("@sinclair/typebox").TObject<{
104
+ field: import("@sinclair/typebox").TString;
105
+ op: import("@sinclair/typebox").TLiteral<"eq">;
106
+ value: import("@sinclair/typebox").TBoolean;
107
+ }>]>>>;
108
+ }>>>;
109
+ title: import("@sinclair/typebox").TString;
22
110
  description: import("@sinclair/typebox").TString;
23
- }>>;
111
+ keywords: import("@sinclair/typebox").TString;
112
+ ogImage: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
113
+ src: import("@sinclair/typebox").TString;
114
+ alt: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
115
+ fit: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"object-none">, import("@sinclair/typebox").TLiteral<"object-contain">, import("@sinclair/typebox").TLiteral<"object-cover">, import("@sinclair/typebox").TLiteral<"object-fill">, import("@sinclair/typebox").TLiteral<"object-scale-down">]>>;
116
+ position: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"object-top">, import("@sinclair/typebox").TLiteral<"object-center">, import("@sinclair/typebox").TLiteral<"object-bottom">, import("@sinclair/typebox").TLiteral<"object-left">, import("@sinclair/typebox").TLiteral<"object-right">, import("@sinclair/typebox").TLiteral<"object-top-left">, import("@sinclair/typebox").TLiteral<"object-top-right">, import("@sinclair/typebox").TLiteral<"object-bottom-left">, import("@sinclair/typebox").TLiteral<"object-bottom-right">]>>;
117
+ }>>;
118
+ robotsIndexing: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
119
+ language: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"ar" | "zh" | "cs" | "nl" | "en" | "fr" | "de" | "he" | "hi" | "it" | "ja" | "ko" | "fa" | "pl" | "pt" | "ru" | "es" | "tr" | "vi">>;
120
+ additionalTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
121
+ headTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
122
+ bodyTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
123
+ }>> | import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
124
+ headTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
125
+ bodyTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
126
+ }>>;
127
+ lastUpdated: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
128
+ }>;
129
+ status: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"draft" | "published">>;
24
130
  }>;
25
131
  export declare const sitemapSchema: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
26
132
  id: import("@sinclair/typebox").TString;
27
133
  label: import("@sinclair/typebox").TString;
28
134
  path: import("@sinclair/typebox").TString;
29
- tags: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>;
30
- status: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"draft" | "published">>;
31
- sectionsPlan: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
32
- id: import("@sinclair/typebox").TString;
33
- name: import("@sinclair/typebox").TString;
135
+ attributes: import("@sinclair/typebox").TObject<{
136
+ colorPreset: import("@sinclair/typebox").TObject<{
137
+ color: import("@sinclair/typebox").TUnsafe<string>;
138
+ gradientDirection: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"bg-gradient-to-t" | "bg-gradient-to-r" | "bg-gradient-to-b" | "bg-gradient-to-l" | "bg-gradient-to-tl" | "bg-gradient-to-tr" | "bg-gradient-to-br" | "bg-gradient-to-bl">>;
139
+ }>;
140
+ tags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
141
+ path: import("@sinclair/typebox").TString;
142
+ queries: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
143
+ queryId: import("@sinclair/typebox").TString;
144
+ alias: import("@sinclair/typebox").TString;
145
+ params: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
146
+ field: import("@sinclair/typebox").TString;
147
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"eq">, import("@sinclair/typebox").TLiteral<"ne">, import("@sinclair/typebox").TLiteral<"contains">, import("@sinclair/typebox").TLiteral<"notContains">, import("@sinclair/typebox").TLiteral<"startsWith">, import("@sinclair/typebox").TLiteral<"notStartsWith">, import("@sinclair/typebox").TLiteral<"endsWith">, import("@sinclair/typebox").TLiteral<"notEndsWith">]>;
148
+ value: import("@sinclair/typebox").TString;
149
+ }>, import("@sinclair/typebox").TObject<{
150
+ field: import("@sinclair/typebox").TString;
151
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"eq">, import("@sinclair/typebox").TLiteral<"ne">, import("@sinclair/typebox").TLiteral<"lt">, import("@sinclair/typebox").TLiteral<"lte">, import("@sinclair/typebox").TLiteral<"gt">, import("@sinclair/typebox").TLiteral<"gte">]>;
152
+ value: import("@sinclair/typebox").TNumber;
153
+ }>, import("@sinclair/typebox").TObject<{
154
+ field: import("@sinclair/typebox").TString;
155
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"before">, import("@sinclair/typebox").TLiteral<"after">]>;
156
+ value: import("@sinclair/typebox").TString;
157
+ }>, import("@sinclair/typebox").TObject<{
158
+ field: import("@sinclair/typebox").TString;
159
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"beforeNow">, import("@sinclair/typebox").TLiteral<"afterNow">]>;
160
+ value: import("@sinclair/typebox").TNull;
161
+ }>, import("@sinclair/typebox").TObject<{
162
+ field: import("@sinclair/typebox").TString;
163
+ op: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"contains">, import("@sinclair/typebox").TLiteral<"notContains">, import("@sinclair/typebox").TLiteral<"containsAll">, import("@sinclair/typebox").TLiteral<"containsAny">, import("@sinclair/typebox").TLiteral<"notContainsAny">]>;
164
+ value: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>;
165
+ }>, import("@sinclair/typebox").TObject<{
166
+ field: import("@sinclair/typebox").TString;
167
+ op: import("@sinclair/typebox").TLiteral<"eq">;
168
+ value: import("@sinclair/typebox").TBoolean;
169
+ }>]>>>;
170
+ }>>>;
171
+ title: import("@sinclair/typebox").TString;
34
172
  description: import("@sinclair/typebox").TString;
35
- }>>;
173
+ keywords: import("@sinclair/typebox").TString;
174
+ ogImage: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
175
+ src: import("@sinclair/typebox").TString;
176
+ alt: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
177
+ fit: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"object-none">, import("@sinclair/typebox").TLiteral<"object-contain">, import("@sinclair/typebox").TLiteral<"object-cover">, import("@sinclair/typebox").TLiteral<"object-fill">, import("@sinclair/typebox").TLiteral<"object-scale-down">]>>;
178
+ position: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"object-top">, import("@sinclair/typebox").TLiteral<"object-center">, import("@sinclair/typebox").TLiteral<"object-bottom">, import("@sinclair/typebox").TLiteral<"object-left">, import("@sinclair/typebox").TLiteral<"object-right">, import("@sinclair/typebox").TLiteral<"object-top-left">, import("@sinclair/typebox").TLiteral<"object-top-right">, import("@sinclair/typebox").TLiteral<"object-bottom-left">, import("@sinclair/typebox").TLiteral<"object-bottom-right">]>>;
179
+ }>>;
180
+ robotsIndexing: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
181
+ language: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"ar" | "zh" | "cs" | "nl" | "en" | "fr" | "de" | "he" | "hi" | "it" | "ja" | "ko" | "fa" | "pl" | "pt" | "ru" | "es" | "tr" | "vi">>;
182
+ additionalTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
183
+ headTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
184
+ bodyTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
185
+ }>> | import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
186
+ headTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
187
+ bodyTags: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
188
+ }>>;
189
+ lastUpdated: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
190
+ }>;
191
+ status: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnsafe<"draft" | "published">>;
36
192
  }>>;
37
193
  export type Sitemap = Static<typeof sitemapSchema>;
38
194
  //# sourceMappingURL=sitemap.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"sitemap.d.ts","sourceRoot":"","sources":["../../src/shared/sitemap.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAItD,eAAO,MAAM,cAAc;;;;EAAiD,CAAC;AAC7E,MAAM,MAAM,QAAQ,GAAG,MAAM,CAAC,OAAO,cAAc,CAAC,CAAC;AAErD,eAAO,MAAM,kBAAkB;;;;GAqB9B,CAAC;AAEF,eAAO,MAAM,YAAY;;;;;;;;;;;EAyBxB,CAAC;AACF,eAAO,MAAM,aAAa;;;;;;;;;;;GAA2B,CAAC;AAEtD,MAAM,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,aAAa,CAAC,CAAC"}
1
+ {"version":3,"file":"sitemap.d.ts","sourceRoot":"","sources":["../../src/shared/sitemap.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAItD,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAA+D,CAAC;AAC7F,MAAM,MAAM,gBAAgB,GAAG,MAAM,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAE/D,eAAO,MAAM,kBAAkB;;;;GAqB9B,CAAC;AAEF,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAmBxB,CAAC;AACF,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAA2B,CAAC;AAEtD,MAAM,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,aAAa,CAAC,CAAC"}
@@ -1,3 +1,3 @@
1
1
  /*! Upstart.gg - Copyright (C) 2024 Flippable - https://github.com/upstart-gg/upstart/blob/main/LICENSE */
2
2
 
3
- import{a,b,c,d}from"./chunk-C2S243PB.js";import"./chunk-VTBI7WX3.js";import"./chunk-EYPREFMH.js";import"./chunk-TATG6SFZ.js";import"./chunk-NLEWXPVM.js";import"./chunk-L42YBY5I.js";import"./chunk-AQPN5SE2.js";import"./chunk-DQXDGV67.js";import"./chunk-IFEIRRZ2.js";import"./chunk-7DMUDZ4H.js";import"./chunk-LSPN22SI.js";import"./chunk-QSZWDE3D.js";import"./chunk-ETYYRWLK.js";import"./chunk-4TH3C76A.js";import"./chunk-FKNNTHWX.js";import"./chunk-JS4K5JRM.js";import"./chunk-WU6Q4WYD.js";import"./chunk-QISTDGPP.js";import"./chunk-LFQZRGHS.js";import"./chunk-SLRU4CT6.js";import"./chunk-MKIXZXWS.js";import"./chunk-TTTXV7TJ.js";import"./chunk-UHF6IEKV.js";import"./chunk-LGP6GWIY.js";import"./chunk-X43MB5WD.js";import"./chunk-NNI225RG.js";import"./chunk-ZQGNYK5I.js";import"./chunk-KHFNN4P3.js";import"./chunk-3EM3B4DX.js";import"./chunk-BZGNY7LB.js";import"./chunk-IIFTGWFZ.js";import"./chunk-MPBYGS6W.js";import"./chunk-OIOYMECS.js";import"./chunk-VPFCY4DH.js";import"./chunk-TWBY2GOR.js";import"./chunk-CT3EI7YN.js";import"./chunk-6WCGUAQN.js";import"./chunk-T4LMBG2G.js";import"./chunk-C3VGP4CA.js";import"./chunk-ACVLF55Q.js";import"./chunk-6FITVVZX.js";import"./chunk-YIFNKP4J.js";import"./chunk-UU2MSQXY.js";import"./chunk-T3LIA4YB.js";import"./chunk-RGLVKILY.js";import"./chunk-YBGPPF7T.js";import"./chunk-VZPXXFVX.js";import"./chunk-UMHXXXVP.js";import"./chunk-2IYSJYNE.js";import"./chunk-E22E4XWE.js";import"./chunk-EJGNYD4V.js";import"./chunk-5N6MBJJ4.js";import"./chunk-SFKZAUPW.js";import"./chunk-VGRYSAXA.js";import"./chunk-I46VBMLF.js";export{a as pageInfoSchema,b as sectionsPlanSchema,c as sitemapEntry,d as sitemapSchema};
3
+ import{a,b,c,d}from"./chunk-L6WHBSRZ.js";import"./chunk-YFFTZ5T6.js";import"./chunk-EYPREFMH.js";import"./chunk-TATG6SFZ.js";import"./chunk-NLEWXPVM.js";import"./chunk-L42YBY5I.js";import"./chunk-AQPN5SE2.js";import"./chunk-DQXDGV67.js";import"./chunk-IFEIRRZ2.js";import"./chunk-7DMUDZ4H.js";import"./chunk-LSPN22SI.js";import"./chunk-QSZWDE3D.js";import"./chunk-ETYYRWLK.js";import"./chunk-4TH3C76A.js";import"./chunk-FKNNTHWX.js";import"./chunk-JS4K5JRM.js";import"./chunk-WU6Q4WYD.js";import"./chunk-QISTDGPP.js";import"./chunk-LFQZRGHS.js";import"./chunk-SLRU4CT6.js";import"./chunk-MKIXZXWS.js";import"./chunk-TTTXV7TJ.js";import"./chunk-UHF6IEKV.js";import"./chunk-LGP6GWIY.js";import"./chunk-X43MB5WD.js";import"./chunk-NNI225RG.js";import"./chunk-ZQGNYK5I.js";import"./chunk-KHFNN4P3.js";import"./chunk-3EM3B4DX.js";import"./chunk-BZGNY7LB.js";import"./chunk-IIFTGWFZ.js";import"./chunk-MPBYGS6W.js";import"./chunk-OIOYMECS.js";import"./chunk-VPFCY4DH.js";import"./chunk-TWBY2GOR.js";import"./chunk-CT3EI7YN.js";import"./chunk-6WCGUAQN.js";import"./chunk-T4LMBG2G.js";import"./chunk-C3VGP4CA.js";import"./chunk-ACVLF55Q.js";import"./chunk-6FITVVZX.js";import"./chunk-YIFNKP4J.js";import"./chunk-UU2MSQXY.js";import"./chunk-T3LIA4YB.js";import"./chunk-RGLVKILY.js";import"./chunk-YBGPPF7T.js";import"./chunk-VZPXXFVX.js";import"./chunk-UMHXXXVP.js";import"./chunk-2IYSJYNE.js";import"./chunk-E22E4XWE.js";import"./chunk-EJGNYD4V.js";import"./chunk-5N6MBJJ4.js";import"./chunk-SFKZAUPW.js";import"./chunk-VGRYSAXA.js";import"./chunk-I46VBMLF.js";export{b as sectionsPlanSchema,c as sitemapEntry,a as sitemapPageEntry,d as sitemapSchema};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@upstart.gg/sdk",
3
- "version": "0.0.129",
3
+ "version": "0.0.130",
4
4
  "type": "module",
5
5
  "files": [
6
6
  "dist"
@@ -28,6 +28,7 @@
28
28
  },
29
29
  "dependencies": {
30
30
  "@date-fns/utc": "1.2.0",
31
+ "@notionhq/client": "4.0.2",
31
32
  "@radix-ui/themes": "3.2.1",
32
33
  "@rowanmanning/feed-parser": "2.1.0",
33
34
  "@sinclair/typebox": "0.33.7",
@@ -48,7 +49,7 @@
48
49
  "usehooks-ts": "3.1.0",
49
50
  "zundo": "2.3.0",
50
51
  "zustand": "4.5.5",
51
- "@upstart.gg/style-system": "0.0.129"
52
+ "@upstart.gg/style-system": "0.0.130"
52
53
  },
53
54
  "peerDependencies": {
54
55
  "@headlessui/react": "^2.2.1",
@@ -1,8 +0,0 @@
1
- /*! Upstart.gg - Copyright (C) 2024 Flippable - https://github.com/upstart-gg/upstart/blob/main/LICENSE */
2
-
3
- import{a}from"./chunk-VTBI7WX3.js";import{a as t}from"./chunk-SFKZAUPW.js";import{Type as e}from"@sinclair/typebox";var i=e.Pick(a,["id","label","path"]),o=e.Array(e.Object({id:e.String({title:"Section ID (slug format)"}),name:e.String({title:"Section name"}),description:e.String({title:"A long description of the section",description:`You must elaborate a clear and detailled plan that describes:
4
- - The section purpose in the page, in detail.
5
- - The section structure, look & feel, and structural/design organization, in detail
6
- - the types of bricks (e.g. "container", "text", "video", "carousel", etc) that will be used and their purpose, in detail
7
-
8
- IMPORTANT: be very descriptive and precise in your plan. The more details you provide, the better the generated page will be.`})},{additionalProperties:!1}),{title:"Sections plan",description:"A plan for the sections of the page. Used to generate the page content."}),n=e.Composite([i,e.Object({tags:e.Array(e.String(),{default:[],description:"Tags for the page. Use the tag 'main-nav' for pages that should appear in the main navbar"}),status:e.Optional(t(["draft","published"],{title:"Page status",enumNames:["Draft","Published"],description:"The status of the page. Can be draft or published. [AI instructions: Dont generate this.]","ai:instructions":"Do not generate this."})),sectionsPlan:o})],{description:"Pages map. The complete list of site pages, their metadata and their sections summary",additionalProperties:!1}),c=e.Array(n);export{i as a,o as b,n as c,c as d};