alinea 2.0.0-preview.3 → 2.0.0-preview.5

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 (225) hide show
  1. package/dist/.init/content/pages/welcome.json +1 -1
  2. package/dist/.init/src/cms.ts +1 -4
  3. package/dist/LICENSES.md +148 -94
  4. package/dist/adapter/next/DevRemote.js +10 -2
  5. package/dist/adapter/next/cms.js +5 -1
  6. package/dist/adapter/next/handler.js +35 -6
  7. package/dist/adapter/next/previews.js +7 -0
  8. package/dist/adapter/next/syncCheck.d.ts +12 -0
  9. package/dist/adapter/next/syncCheck.js +59 -0
  10. package/dist/adapter/next/with-alinea.d.ts +0 -8
  11. package/dist/adapter/next/with-alinea.js +43 -19
  12. package/dist/adapter/vite/plugin.js +9 -4
  13. package/dist/backend/Handler.js +120 -7
  14. package/dist/backend/api/BasicAuth.d.ts +1 -1
  15. package/dist/backend/api/BasicAuth.js +14 -14
  16. package/dist/backend/api/OAuth2.d.ts +3 -3
  17. package/dist/backend/api/OAuth2.js +7 -4
  18. package/dist/backend/api/ProxyMedia.d.ts +3 -0
  19. package/dist/backend/api/ProxyMedia.js +39 -0
  20. package/dist/backend/api/S3Uploads.d.ts +1 -1
  21. package/dist/backend/router/Router.js +2 -0
  22. package/dist/backend/util/Syncable.js +1 -1
  23. package/dist/bundled.d.ts +260 -95
  24. package/dist/chunks/{chunk-HFBZMKIN.js → chunk-A6M3PNJT.js} +1 -1
  25. package/dist/chunks/{chunk-Y7XOMJOC.js → chunk-CFNRVI3Y.js} +220 -247
  26. package/dist/chunks/chunk-D6UJHBJJ.js +183 -0
  27. package/dist/chunks/chunk-TIJTT5ZI.js +228 -0
  28. package/dist/cli/Generate.js +1 -3
  29. package/dist/cli/Serve.js +3 -2
  30. package/dist/cli/bin.js +1 -1
  31. package/dist/cli/generate/GenerateDashboard.js +1 -0
  32. package/dist/cli/serve/CreateLocalServer.d.ts +1 -1
  33. package/dist/cli/serve/CreateLocalServer.js +42 -34
  34. package/dist/cli/serve/LocalAuth.js +1 -1
  35. package/dist/cli/static/init/cms.js +1 -4
  36. package/dist/cli/util/ContentType.d.ts +1 -0
  37. package/dist/cli/util/ContentType.js +36 -0
  38. package/dist/cloud/AuthResult.d.ts +2 -0
  39. package/dist/cloud/CloudHandshake.d.ts +13 -0
  40. package/dist/cloud/CloudHandshake.js +121 -0
  41. package/dist/cloud/CloudRemote.d.ts +4 -1
  42. package/dist/cloud/CloudRemote.js +40 -9
  43. package/dist/components/Calendar.js +7 -7
  44. package/dist/components/Checkbox.js +2 -2
  45. package/dist/components/ColorSwatchPicker.js +2 -2
  46. package/dist/components/ComboBox.js +12 -12
  47. package/dist/components/DateField.js +4 -4
  48. package/dist/components/DatePicker.js +4 -4
  49. package/dist/components/DateRangePicker.js +8 -8
  50. package/dist/components/Disclosure.js +7 -7
  51. package/dist/components/Label.js +5 -5
  52. package/dist/components/List.d.ts +1 -1
  53. package/dist/components/List.js +29 -28
  54. package/dist/components/Menu.js +2 -2
  55. package/dist/components/MultipleSelect.js +25 -25
  56. package/dist/components/NumberField.js +3 -3
  57. package/dist/components/ProgressCircle.js +4 -4
  58. package/dist/components/SearchField.js +6 -6
  59. package/dist/components/Select.js +7 -7
  60. package/dist/components/Surface.js +3 -3
  61. package/dist/components/Table.js +6 -6
  62. package/dist/components/Tabs.js +2 -2
  63. package/dist/components/TagGroup.js +2 -2
  64. package/dist/components/TextField.js +4 -4
  65. package/dist/components/TimeField.js +1 -1
  66. package/dist/components/Toggle.d.ts +1 -1
  67. package/dist/components/Toolbar.js +1 -1
  68. package/dist/components/Tree.js +7 -7
  69. package/dist/core/Config.d.ts +10 -3
  70. package/dist/core/Config.js +16 -1
  71. package/dist/core/Connection.d.ts +7 -4
  72. package/dist/core/Entry.d.ts +6 -0
  73. package/dist/core/Entry.js +10 -0
  74. package/dist/core/Graph.d.ts +2 -2
  75. package/dist/core/Id.d.ts +1 -0
  76. package/dist/core/Id.js +8 -0
  77. package/dist/core/Role.js +16 -14
  78. package/dist/core/TextDoc.d.ts +2 -0
  79. package/dist/core/TextDoc.js +1 -0
  80. package/dist/core/Workspace.d.ts +6 -5
  81. package/dist/core/db/EntryIndex.d.ts +3 -0
  82. package/dist/core/db/EntryIndex.js +62 -0
  83. package/dist/core/db/EntryTransaction.js +33 -12
  84. package/dist/core/db/EntryUrlConflictError.js +1 -1
  85. package/dist/core/db/LinkResolver.d.ts +8 -2
  86. package/dist/core/db/LinkResolver.js +27 -5
  87. package/dist/core/db/Operation.js +4 -3
  88. package/dist/core/field/RichTextField.js +16 -10
  89. package/dist/core/media/MediaLocation.d.ts +9 -15
  90. package/dist/core/media/MediaLocation.js +29 -19
  91. package/dist/core/media/MediaTypes.js +1 -2
  92. package/dist/dashboard/App.js +30 -16
  93. package/dist/dashboard/StoryProvider.js +2 -2
  94. package/dist/dashboard/app/AccessDenied.js +4 -4
  95. package/dist/dashboard/app/ActivityStatus.js +22 -21
  96. package/dist/dashboard/app/AppShell.js +2 -2
  97. package/dist/dashboard/app/AppearanceToggle.d.ts +1 -0
  98. package/dist/dashboard/app/AppearanceToggle.js +43 -0
  99. package/dist/dashboard/app/AuthView.d.ts +1 -1
  100. package/dist/dashboard/app/AuthView.js +19 -21
  101. package/dist/dashboard/app/CompactField.js +13 -13
  102. package/dist/dashboard/app/DashboardErrorBoundary.js +26 -14
  103. package/dist/dashboard/app/DashboardLayout.js +15 -8
  104. package/dist/dashboard/app/DashboardMeta.d.ts +2 -1
  105. package/dist/dashboard/app/DashboardMeta.js +20 -5
  106. package/dist/dashboard/app/EntryFields.d.ts +3 -1
  107. package/dist/dashboard/app/EntryFields.js +17 -14
  108. package/dist/dashboard/app/EntryHeader.js +134 -102
  109. package/dist/dashboard/app/EntryHeaderActions.d.ts +21 -4
  110. package/dist/dashboard/app/EntryHeaderActions.js +48 -27
  111. package/dist/dashboard/app/EntryReferences.js +16 -16
  112. package/dist/dashboard/app/EntrySidebar.js +24 -24
  113. package/dist/dashboard/app/EntrySidebarPreview.js +16 -15
  114. package/dist/dashboard/app/EntryTranslationBanner.d.ts +3 -1
  115. package/dist/dashboard/app/EntryTranslationBanner.js +24 -21
  116. package/dist/dashboard/app/Explorer.d.ts +4 -2
  117. package/dist/dashboard/app/Explorer.js +70 -66
  118. package/dist/dashboard/app/ExplorerCards.js +49 -49
  119. package/dist/dashboard/app/ExplorerFileCard.js +18 -18
  120. package/dist/dashboard/app/ExplorerList.js +21 -22
  121. package/dist/dashboard/app/ExplorerModal.js +1 -1
  122. package/dist/dashboard/app/ExplorerPickerContent.js +2 -2
  123. package/dist/dashboard/app/ExplorerTable.js +68 -68
  124. package/dist/dashboard/app/ImagePicker.js +7 -7
  125. package/dist/dashboard/app/LinkPicker.js +17 -22
  126. package/dist/dashboard/app/LocaleMenu.d.ts +7 -0
  127. package/dist/dashboard/app/LocaleMenu.js +31 -17
  128. package/dist/dashboard/app/ReadOnlyBadge.d.ts +4 -0
  129. package/dist/dashboard/app/ReadOnlyBadge.js +33 -0
  130. package/dist/dashboard/app/SidebarLayout.js +4 -4
  131. package/dist/dashboard/app/SidebarTree.d.ts +3 -6
  132. package/dist/dashboard/app/SidebarTree.js +66 -61
  133. package/dist/dashboard/app/WorkspaceMenu.d.ts +10 -3
  134. package/dist/dashboard/app/WorkspaceMenu.js +87 -66
  135. package/dist/dashboard/app/WorkspaceMenu.stories.d.ts +2 -0
  136. package/dist/dashboard/app/WorkspaceRoots.d.ts +3 -1
  137. package/dist/dashboard/app/WorkspaceRoots.js +88 -113
  138. package/dist/dashboard/app/editor/FileEditor.d.ts +2 -3
  139. package/dist/dashboard/app/editor/FileEditor.js +35 -38
  140. package/dist/dashboard/app/editor/FilePreview.js +3 -3
  141. package/dist/dashboard/app/editor/MediaAltField.view.js +4 -4
  142. package/dist/dashboard/app/modals/CreateEntry.js +10 -10
  143. package/dist/dashboard/app/pages/EntryPage.js +85 -44
  144. package/dist/dashboard/app/pages/RootPage.js +4 -4
  145. package/dist/dashboard/app/pages/SplashPage.d.ts +3 -0
  146. package/dist/dashboard/app/pages/SplashPage.js +414 -0
  147. package/dist/dashboard/app/pages/UsersPage.js +38 -38
  148. package/dist/dashboard/app/ui/DashboardModal.js +16 -16
  149. package/dist/dashboard/app/ui/Rail.js +2 -2
  150. package/dist/dashboard/app/ui/Sidebar.js +2 -2
  151. package/dist/dashboard/atoms/ReactiveNode.js +1 -1
  152. package/dist/dashboard/atoms/activity.d.ts +0 -1
  153. package/dist/dashboard/atoms/activity.js +3 -5
  154. package/dist/dashboard/atoms/auth.d.ts +2 -0
  155. package/dist/dashboard/atoms/auth.js +6 -2
  156. package/dist/dashboard/atoms/config.js +1 -1
  157. package/dist/dashboard/atoms/core.js +2 -2
  158. package/dist/dashboard/atoms/create.js +1 -1
  159. package/dist/dashboard/atoms/dashboard.js +2 -2
  160. package/dist/dashboard/atoms/editor.d.ts +2 -1
  161. package/dist/dashboard/atoms/editor.js +5 -3
  162. package/dist/dashboard/atoms/entry.d.ts +2 -0
  163. package/dist/dashboard/atoms/entry.js +34 -16
  164. package/dist/dashboard/atoms/explorer.d.ts +5 -6
  165. package/dist/dashboard/atoms/explorer.js +68 -31
  166. package/dist/dashboard/atoms/graph.d.ts +1 -0
  167. package/dist/dashboard/atoms/graph.js +7 -2
  168. package/dist/dashboard/atoms/link.d.ts +1 -1
  169. package/dist/dashboard/atoms/link.js +41 -57
  170. package/dist/dashboard/atoms/nav.d.ts +4 -3
  171. package/dist/dashboard/atoms/nav.js +10 -5
  172. package/dist/dashboard/atoms/preview.js +1 -1
  173. package/dist/dashboard/atoms/root.d.ts +7 -2
  174. package/dist/dashboard/atoms/root.js +53 -18
  175. package/dist/dashboard/atoms/upload.d.ts +1 -0
  176. package/dist/dashboard/atoms/upload.js +3 -2
  177. package/dist/dashboard/atoms/user.d.ts +1 -1
  178. package/dist/dashboard/atoms/user.js +8 -6
  179. package/dist/dashboard/atoms/utils.js +2 -2
  180. package/dist/dashboard/boot/Boot.js +2 -4
  181. package/dist/dashboard/boot/DashboardWorker.js +35 -29
  182. package/dist/dashboard/editor/UseField.js +6 -6
  183. package/dist/dashboard/fixture/cms.d.ts +12 -0
  184. package/dist/dashboard/fixture/cms.js +54 -6
  185. package/dist/dashboard/hook/UseGraph.js +4 -4
  186. package/dist/dashboard/hook/UseRoot.js +4 -4
  187. package/dist/dashboard/hook/UseSaveShortcut.d.ts +1 -0
  188. package/dist/dashboard/hook/UseSaveShortcut.js +24 -0
  189. package/dist/dashboard/hooks.d.ts +1 -1
  190. package/dist/dashboard/hooks.js +28 -19
  191. package/dist/field/code/CodeField.view.js +12 -12
  192. package/dist/field/link/ImageLink.js +1 -3
  193. package/dist/field/link/LinkField.view.js +97 -71
  194. package/dist/field/list/ListField.view.js +23 -23
  195. package/dist/field/localiser/LocalisedField.view.js +76 -5
  196. package/dist/field/metadata/MetadataField.d.ts +3 -3
  197. package/dist/field/metadata/MetadataField.view.js +27 -20
  198. package/dist/field/object/ObjectField.view.js +11 -4
  199. package/dist/field/richtext/PickTextLink.js +11 -8
  200. package/dist/field/richtext/ReferenceLink.d.ts +2 -0
  201. package/dist/field/richtext/ReferenceLink.js +5 -0
  202. package/dist/field/richtext/RichTextBlock.js +6 -6
  203. package/dist/field/richtext/RichTextBlocks.js +1 -1
  204. package/dist/field/richtext/RichTextExtensions.js +22 -22
  205. package/dist/field/richtext/RichTextField.view.js +9 -9
  206. package/dist/field/richtext/RichTextInsertMenu.js +3 -3
  207. package/dist/field/richtext/RichTextState.js +1 -1
  208. package/dist/field/richtext/extensions/Link.d.ts +1 -0
  209. package/dist/field/richtext/extensions/Link.js +1 -0
  210. package/dist/field/text/TextField.view.js +2 -2
  211. package/dist/field/time/TimeField.d.ts +0 -2
  212. package/dist/field/time/TimeField.view.js +1 -1
  213. package/dist/index.css +459 -66
  214. package/dist/next.cjs +96 -19
  215. package/dist/picker/entry/EntryPicker.js +10 -12
  216. package/dist/picker/entry/EntryReference.d.ts +2 -0
  217. package/dist/picker/entry/EntryReference.js +1 -0
  218. package/dist/preview/RegisterPreview.d.ts +1 -1
  219. package/dist/preview/RegisterPreview.js +4 -6
  220. package/dist/preview/react.d.ts +5 -1
  221. package/dist/preview/react.js +12 -9
  222. package/dist/types.d.ts +0 -1
  223. package/package.json +1 -1
  224. package/dist/chunks/chunk-STAJCW4Z.js +0 -322
  225. package/dist/chunks/chunk-U4VOHNR2.js +0 -210
package/dist/bundled.d.ts CHANGED
@@ -133,17 +133,26 @@ declare module 'alinea/adapter/next/previews.spec' {
133
133
 
134
134
  }
135
135
 
136
+ declare module 'alinea/adapter/next/syncCheck' {
137
+
138
+ import type { Client } from 'alinea/core/Client';
139
+ import type { LocalDB } from 'alinea/core/db/LocalDB';
140
+ export const CONTENT_SHA_TAG = "alinea-content-sha";
141
+ export function revalidateContentSha(): Promise<void>;
142
+ /**
143
+ * Sync the isolate-local db only when it is behind the shared content sha.
144
+ * Returns true when the freshness question is settled here (synced, forced,
145
+ * or explicitly disabled) and the caller can skip its throttled sync.
146
+ * Returns false when the sha could not be determined, so the caller falls
147
+ * back to its existing throttle behavior.
148
+ */
149
+ export function syncIfStale(db: LocalDB, client: Client, syncInterval?: number): Promise<boolean>;
150
+
151
+ }
152
+
136
153
  declare module 'alinea/adapter/next/with-alinea' {
137
154
 
138
155
  import type { NextConfig } from 'next/dist/types.js';
139
- export interface WithAlineaOptions {
140
- /**
141
- * Base path where the dashboard is mounted.
142
- *
143
- * @default '/admin'
144
- */
145
- adminPath?: string;
146
- }
147
156
  export function createCMS(): void;
148
157
  export function withAlinea(config?: NextConfig): NextConfig;
149
158
 
@@ -187,7 +196,7 @@ declare module 'alinea/backend/api/BasicAuth' {
187
196
  export class BasicAuth implements AuthApi {
188
197
  #private;
189
198
  constructor(context: RequestContext, verify: Verifier);
190
- authenticate(request: Request, options?: AuthOptions): Promise<Response>;
199
+ authenticate(request: Request, options: AuthOptions): Promise<Response>;
191
200
  verify(request: Request): Promise<AuthedContext>;
192
201
  }
193
202
 
@@ -331,20 +340,28 @@ declare module 'alinea/backend/api/OAuth2' {
331
340
  */
332
341
  revocationEndpoint?: string;
333
342
  /**
334
- * Extra claims to validate, such as `iss` or `aud`,
343
+ * Validate provider-specific claims, including `iss` and `aud`.
335
344
  * If the claims are invalid, an error should be thrown.
336
345
  */
337
- validateClaims?(claims: JWTPayload): void;
346
+ validateClaims(claims: JWTPayload): void | Promise<void>;
338
347
  }
339
348
  export class OAuth2 implements AuthApi {
340
349
  #private;
341
350
  constructor(context: RequestContext, config: Config, options: OAuth2Options);
342
- authenticate(request: Request, options?: AuthOptions): Promise<Response>;
351
+ authenticate(request: Request, options: AuthOptions): Promise<Response>;
343
352
  verify(request: Request): Promise<AuthedContext>;
344
353
  }
345
354
 
346
355
  }
347
356
 
357
+ declare module 'alinea/backend/api/ProxyMedia' {
358
+
359
+ import { type Request, Response } from '@alinea/iso';
360
+ export function proxyMediaUrl(request: Request, source: URL, isAllowed?: (url: URL) => boolean): Promise<Response>;
361
+ export function isRedirectStatus(status: number): boolean;
362
+
363
+ }
364
+
348
365
  declare module 'alinea/backend/api/S3Uploads' {
349
366
 
350
367
  import type { UploadMetadata, UploadResponse, UploadsApi } from 'alinea/core/Connection';
@@ -362,7 +379,7 @@ declare module 'alinea/backend/api/S3Uploads' {
362
379
  previewExpiresIn?: number;
363
380
  }
364
381
  interface S3PresignOptions {
365
- method: 'GET' | 'PUT';
382
+ method: 'GET' | 'HEAD' | 'PUT';
366
383
  url: URL;
367
384
  region: string;
368
385
  accessKeyId: string;
@@ -957,7 +974,7 @@ declare module 'alinea/cli/serve/CreateLocalServer' {
957
974
  import type { Handler } from 'alinea/backend/Handler';
958
975
  import type { CMS } from 'alinea/core/CMS';
959
976
  import type { User } from 'alinea/core/User';
960
- import { type Request, Response } from '@alinea/iso';
977
+ import { Request, Response } from '@alinea/iso';
961
978
  import type { ServeContext } from 'alinea/cli/serve/ServeContext';
962
979
  export function createLocalServer({ cmd, configLocation, rootDir, staticDir, alineaDev, buildOptions, production, liveReload, buildId, apiKey }: ServeContext, cms: CMS, handleApi: Handler, user: User): {
963
980
  close(): void;
@@ -1100,6 +1117,12 @@ declare module 'alinea/cli/util/CommitSha' {
1100
1117
 
1101
1118
  }
1102
1119
 
1120
+ declare module 'alinea/cli/util/ContentType' {
1121
+
1122
+ export function contentType(extension: string): string;
1123
+
1124
+ }
1125
+
1103
1126
  declare module 'alinea/cli/util/Dirname' {
1104
1127
 
1105
1128
  export function dirname(url?: string): string;
@@ -1225,6 +1248,7 @@ declare module 'alinea/cli/util/Watcher' {
1225
1248
 
1226
1249
  declare module 'alinea/cloud/AuthResult' {
1227
1250
 
1251
+ import type { BackendCapabilities } from 'alinea/core/Connection';
1228
1252
  import type { User } from 'alinea/core/User';
1229
1253
  export enum AuthResultType {
1230
1254
  Authenticated = 0,
@@ -1235,6 +1259,7 @@ declare module 'alinea/cloud/AuthResult' {
1235
1259
  export type AuthResult = {
1236
1260
  type: AuthResultType.Authenticated;
1237
1261
  user: User;
1262
+ capabilities?: BackendCapabilities;
1238
1263
  } | {
1239
1264
  type: AuthResultType.UnAuthenticated;
1240
1265
  redirect: string;
@@ -1270,6 +1295,24 @@ declare module 'alinea/cloud/CloudConfig' {
1270
1295
 
1271
1296
  }
1272
1297
 
1298
+ declare module 'alinea/cloud/CloudHandshake' {
1299
+
1300
+ interface VerifyCloudHandshakeOptions {
1301
+ clientId: string;
1302
+ handshakeId: string;
1303
+ origin: string;
1304
+ }
1305
+ export class CloudHandshakeError extends Error {
1306
+ name: string;
1307
+ }
1308
+ export class CloudHandshakeServiceError extends Error {
1309
+ name: string;
1310
+ }
1311
+ export function verifyCloudHandshake(token: string, options: VerifyCloudHandshakeOptions): Promise<void>;
1312
+ export {};
1313
+
1314
+ }
1315
+
1273
1316
  declare module 'alinea/cloud/CloudRemote' {
1274
1317
 
1275
1318
  import { OAuth2 } from 'alinea/backend/api/OAuth2';
@@ -1284,12 +1327,15 @@ declare module 'alinea/cloud/CloudRemote' {
1284
1327
  export class CloudRemote extends OAuth2 implements RemoteConnection {
1285
1328
  #private;
1286
1329
  constructor(context: RequestContext, config: Config);
1330
+ capabilities(): Promise<{
1331
+ users: boolean;
1332
+ }>;
1287
1333
  getTreeIfDifferent(sha: string): Promise<ReadonlyTree | undefined>;
1288
1334
  getBlobs(shas: ReadonlyArray<string>, options?: GetBlobsOptions): AsyncGenerator<[sha: string, blob: Uint8Array]>;
1289
1335
  write(request: CommitRequest): Promise<{
1290
1336
  sha: string;
1291
1337
  }>;
1292
- authenticate(request: Request, options?: AuthOptions): Promise<globalThis.Response>;
1338
+ authenticate(request: Request, options: AuthOptions): Promise<globalThis.Response>;
1293
1339
  prepareUpload(file: string, metadata?: UploadMetadata): Promise<{
1294
1340
  entryId: string;
1295
1341
  location: string;
@@ -1631,7 +1677,7 @@ declare module 'alinea/components/List' {
1631
1677
  description?: ReactNode;
1632
1678
  inline?: boolean;
1633
1679
  }
1634
- export function ListLabel({ children, expanded, hasRows, shared, showFold, className, description, inline, ...props }: ListLabelProps): import("react").JSX.Element;
1680
+ export function ListLabel({ children, expanded, hasRows, shared, showFold, className, description, inline, ...props }: ListLabelProps): import("react").JSX.Element | null;
1635
1681
  export interface ListErrorProps extends ComponentPropsWithoutRef<'div'> {
1636
1682
  }
1637
1683
  export function ListError({ className, ...props }: ListErrorProps): import("react").JSX.Element;
@@ -1945,7 +1991,7 @@ declare module 'alinea/components/Toggle' {
1945
1991
 
1946
1992
  import { type ToggleButtonGroupProps as ToggleButtonGroupPrimitiveProps, type ToggleButtonProps as ToggleButtonPrimitiveProps } from 'react-aria-components';
1947
1993
  export interface ToggleButtonGroupProps extends ToggleButtonGroupPrimitiveProps {
1948
- variant?: 'compact' | 'enclosed';
1994
+ variant?: 'compact' | 'enclosed' | 'icon-small';
1949
1995
  }
1950
1996
  export function ToggleButtonGroup({ variant, className, ...props }: ToggleButtonGroupProps): import("react").JSX.Element;
1951
1997
  export interface ToggleButtonProps extends ToggleButtonPrimitiveProps {
@@ -2155,7 +2201,7 @@ declare module 'alinea/core/Config' {
2155
2201
  preview?: Preview;
2156
2202
  /** Every edit will pass through a draft status before being published */
2157
2203
  enableDrafts?: boolean;
2158
- /** The interval in seconds at which the frontend will poll for updates */
2204
+ /** Fallback interval in seconds for polling content updates (freshness is primarily sha-driven) */
2159
2205
  syncInterval?: number;
2160
2206
  /** Maximum file upload size in bytes */
2161
2207
  maxUploadSize?: number;
@@ -2166,9 +2212,14 @@ declare module 'alinea/core/Config' {
2166
2212
  };
2167
2213
  /** The url of the handler endpoint */
2168
2214
  handlerUrl?: string;
2169
- /** The folder where public assets are stored, defaults to /public */
2215
+ /** The public path where Alinea is mounted, defaults to /admin */
2216
+ adminPath?: string;
2217
+ /** The folder where public assets are stored, defaults to /public. */
2170
2218
  publicDir?: string;
2171
- /** Filename of the generated dashboard, defaults to admin.html */
2219
+ /**
2220
+ * Filename of the generated dashboard, defaults to admin.html.
2221
+ * @deprecated Use adminPath instead.
2222
+ */
2172
2223
  dashboardFile?: string;
2173
2224
  /** Optional application-owned instrumentation for Alinea operations. */
2174
2225
  tracer?: Tracer;
@@ -2178,6 +2229,8 @@ declare module 'alinea/core/Config' {
2178
2229
  function baseUrl(config: Config, env?: string): string | undefined;
2179
2230
  function handlerUrl(config: Config): string;
2180
2231
  function adminPath(config: Config): string;
2232
+ function filePathname(config: Config, file: string): string;
2233
+ function dashboardFile(config: Config): string;
2181
2234
  function mainWorkspace(config: Config): WorkspaceInternal;
2182
2235
  function type(config: Config, name: string): Type | undefined;
2183
2236
  function rootContains(config: Config, root: Root, childType: Type): boolean;
@@ -2206,11 +2259,15 @@ declare module 'alinea/core/Connection' {
2206
2259
  import type { ReadonlyTree } from 'alinea/core/source/Tree';
2207
2260
  import type { User, UserInput } from 'alinea/core/User';
2208
2261
  export interface AuthApi {
2209
- authenticate(request: Request, options?: AuthOptions): Promise<Response>;
2262
+ authenticate(request: Request, options: AuthOptions): Promise<Response>;
2210
2263
  verify(request: Request): Promise<AuthedContext>;
2211
2264
  }
2212
2265
  export interface AuthOptions {
2213
- enrichUser?(user: User): Promise<User>;
2266
+ authenticated(user: User): Promise<AuthenticatedUser>;
2267
+ }
2268
+ export interface AuthenticatedUser {
2269
+ user: User;
2270
+ capabilities: BackendCapabilities;
2214
2271
  }
2215
2272
  export interface UserApi {
2216
2273
  enrichUser(user: User): Promise<User>;
@@ -2223,7 +2280,7 @@ declare module 'alinea/core/Connection' {
2223
2280
  users: boolean;
2224
2281
  }
2225
2282
  export interface CapabilitiesApi {
2226
- capabilities?(): Promise<BackendCapabilities>;
2283
+ capabilities(): Promise<BackendCapabilities>;
2227
2284
  }
2228
2285
  export interface RemoteConnection extends Connection, AuthApi, CapabilitiesApi {
2229
2286
  }
@@ -2231,7 +2288,6 @@ declare module 'alinea/core/Connection' {
2231
2288
  logout?(): Promise<void>;
2232
2289
  }
2233
2290
  export interface LocalConnection extends Connection, CapabilitiesApi {
2234
- capabilities(): Promise<BackendCapabilities>;
2235
2291
  mutate(mutations: Array<Mutation>): Promise<{
2236
2292
  sha: string;
2237
2293
  }>;
@@ -2467,6 +2523,8 @@ declare module 'alinea/core/db/EntryIndex' {
2467
2523
  constructor(config: Config, versionData: Map<string, EntryVersionData>, seeds: Map<string, Seed>);
2468
2524
  byId(id: string): EntryNode | undefined;
2469
2525
  candidateNodes(query: EntryNodeQuery): Array<EntryNode> | undefined;
2526
+ byUrl(url: string): Iterable<Entry>;
2527
+ byAlias(alias: string): Iterable<Entry>;
2470
2528
  get config(): Config;
2471
2529
  byDir(dir: string): EntryNode | undefined;
2472
2530
  entryByFilePath(filePath: string): Entry | undefined;
@@ -2484,6 +2542,7 @@ declare module 'alinea/core/db/EntryIndex' {
2484
2542
  filter(filter: EntryCondition): Iterable<Entry>;
2485
2543
  findFirst<T extends Record<string, unknown>>(filter: (entry: Entry) => boolean): Entry<T> | undefined;
2486
2544
  findMany(filter: (entry: Entry) => boolean): Iterable<Entry>;
2545
+ findByUrl(url: string, filter: (entry: Entry) => boolean): Entry | undefined;
2487
2546
  referencesTo(query: EntryReferenceQuery): Promise<EntryReferenceResult>;
2488
2547
  referencesFrom(sourceId: string): Promise<import("alinea/core/db/EntryReference").EntryReference[]>;
2489
2548
  get references(): Promise<EntryReferenceIndex>;
@@ -2734,13 +2793,19 @@ declare module 'alinea/core/db/LinkResolver' {
2734
2793
 
2735
2794
  import type { InferProjection, Projection } from 'alinea/core/Graph';
2736
2795
  import type { EntryResolver, ResolveContext } from 'alinea/core/db/EntryResolver';
2796
+ export interface LinkTarget {
2797
+ entryId: string;
2798
+ locale?: string;
2799
+ }
2737
2800
  export class LinkResolver {
2738
2801
  resolver: EntryResolver;
2739
2802
  private ctx;
2740
2803
  locale: string | null;
2741
2804
  constructor(resolver: EntryResolver, ctx: ResolveContext, locale: string | null);
2742
- includedAtBuild(filePath: string): boolean;
2743
- resolveLinks<P extends Projection>(projection: P, entryIds: ReadonlyArray<string>): Promise<Array<InferProjection<P>>>;
2805
+ resolveLinks<P extends Projection>(projection: P, entryIds: ReadonlyArray<string>, locale?: string | null | undefined): Promise<Array<InferProjection<P>>>;
2806
+ resolveTargets<P extends Projection & {
2807
+ id: unknown;
2808
+ }>(projection: P, targets: ReadonlyArray<LinkTarget>): Promise<Array<InferProjection<P> | undefined>>;
2744
2809
  }
2745
2810
 
2746
2811
  }
@@ -3135,6 +3200,10 @@ declare module 'alinea/core/Entry' {
3135
3200
  export interface EntryAlias {
3136
3201
  url: string;
3137
3202
  }
3203
+ export interface EntryAuditUser {
3204
+ email: string;
3205
+ name: string;
3206
+ }
3138
3207
  export const Entry: {
3139
3208
  id: Expr<string>;
3140
3209
  status: Expr<EntryStatus>;
@@ -3159,7 +3228,9 @@ declare module 'alinea/core/Entry' {
3159
3228
  url: Expr<string>;
3160
3229
  aliases: Expr<EntryAlias[]>;
3161
3230
  createdAt: Expr<number | null>;
3231
+ createdBy: Expr<EntryAuditUser | null>;
3162
3232
  updatedAt: Expr<number | null>;
3233
+ updatedBy: Expr<EntryAuditUser | null>;
3163
3234
  data: Expr<Record<string, any>>;
3164
3235
  searchableText: Expr<string>;
3165
3236
  };
@@ -3693,9 +3764,9 @@ declare module 'alinea/core/Graph' {
3693
3764
  filter?: Filter<EntryFields>;
3694
3765
  /** Filter by search terms */
3695
3766
  search?: string | Array<string>;
3696
- /** The time in seconds to poll for updates to content */
3767
+ /** Fallback interval in seconds for polling content updates (freshness is primarily sha-driven) */
3697
3768
  syncInterval?: number;
3698
- /** Disable polling for updates to content */
3769
+ /** Disable syncing content updates */
3699
3770
  disableSync?: boolean;
3700
3771
  /** Skip the first N results */
3701
3772
  skip?: number;
@@ -3785,6 +3856,7 @@ declare module 'alinea/core/HttpError' {
3785
3856
  declare module 'alinea/core/Id' {
3786
3857
 
3787
3858
  export function validateId(id: string): boolean;
3859
+ export function timestampFromId(id: string): number | undefined;
3788
3860
  export function createId(): string;
3789
3861
 
3790
3862
  }
@@ -3950,35 +4022,25 @@ declare module 'alinea/core/media/MediaAltField' {
3950
4022
 
3951
4023
  declare module 'alinea/core/media/MediaLocation' {
3952
4024
 
3953
- import type { Config } from 'alinea/core/Config';
4025
+ import { Config } from 'alinea/core/Config';
3954
4026
  export const MEDIA_LOCATION = "@alinea.location";
3955
- export interface MediaUrlMeta {
4027
+ export interface MediaPublicUrlMeta {
3956
4028
  /** The media entry path without its extension. */
3957
4029
  path: string;
3958
4030
  /** The paths of parent media directories. */
3959
4031
  parentPaths: Array<string>;
3960
4032
  /** The file extension, including its leading dot. */
3961
4033
  extension: string;
3962
- /** The location stored in the media entry, excluding mediaDir. */
3963
- location: string;
4034
+ /** The workspace holding the media entry. */
3964
4035
  workspace: string;
3965
- root: string;
3966
- }
3967
- export interface MediaUrlResolver {
3968
- (meta: MediaUrlMeta): string;
3969
- }
3970
- export interface MediaPublicUrlMeta extends Omit<MediaUrlMeta, 'parentPaths'> {
3971
- /** @deprecated Pass parentPaths directly when available. */
3972
- entryUrl?: string;
3973
- parentPaths?: Array<string>;
3974
4036
  }
3975
4037
  export interface MediaEntryUrlMeta {
3976
4038
  defaultUrl: string;
3977
4039
  parentPaths: Array<string>;
3978
4040
  path: string;
3979
- workspace: string;
3980
- root: string;
3981
4041
  data: Record<string, unknown>;
4042
+ /** The workspace holding the media entry. */
4043
+ workspace: string;
3982
4044
  }
3983
4045
  /** Maps media entry locations between storage and public URLs. */
3984
4046
  export namespace MediaLocation {
@@ -3988,8 +4050,12 @@ declare module 'alinea/core/media/MediaLocation' {
3988
4050
  function storagePath(config: Config, workspace: string, location: string): string;
3989
4051
  /** Remove the workspace storage directory from a prepared upload location. */
3990
4052
  function entryLocation(config: Config, workspace: string, location: string): string;
4053
+ /** Resolve the deployed public location of a stored media file. */
4054
+ function sourceUrl(config: Config, workspace: string, location: string): string | undefined;
3991
4055
  /** Resolve the public URL used to serve a media entry. */
3992
4056
  function publicUrl(config: Config, meta: MediaPublicUrlMeta): string;
4057
+ /** Add an immutable media version without changing its canonical path. */
4058
+ function versionedUrl(url: string, version: string | undefined): string;
3993
4059
  /** Resolve a media entry URL, falling back to its regular entry URL. */
3994
4060
  function entryUrl(config: Config, meta: MediaEntryUrlMeta): string;
3995
4061
  }
@@ -4997,6 +5063,7 @@ declare module 'alinea/core/TextDoc' {
4997
5063
  _id: string;
4998
5064
  _link: 'entry' | 'file' | 'url';
4999
5065
  _entry?: string;
5066
+ _locale?: string;
5000
5067
  _anchor?: string;
5001
5068
  _suffix?: string;
5002
5069
  }
@@ -5004,6 +5071,7 @@ declare module 'alinea/core/TextDoc' {
5004
5071
  const id = "_id";
5005
5072
  const link = "_link";
5006
5073
  const entry = "_entry";
5074
+ const locale = "_locale";
5007
5075
  const anchor = "_anchor";
5008
5076
  const suffix = "_suffix";
5009
5077
  }
@@ -5830,23 +5898,23 @@ declare module 'alinea/core/Workspace' {
5830
5898
 
5831
5899
  import type { Preview } from 'alinea/core/Preview';
5832
5900
  import type { ComponentType } from 'react';
5833
- import type { MediaUrlResolver } from 'alinea/core/media/MediaLocation';
5834
5901
  import { type HasWorkspace } from 'alinea/core/Internal';
5835
5902
  import { Root } from 'alinea/core/Root';
5836
5903
  import type { Schema } from 'alinea/core/Schema';
5837
5904
  export interface WorkspaceMeta {
5838
5905
  /** A directory which contains the json entry files */
5839
5906
  source: string;
5840
- /** The directory where media files are placed in case a file backend is used */
5907
+ /**
5908
+ * The directory where media files are placed
5909
+ */
5841
5910
  mediaDir?: string;
5842
- /** Prepare the public URL used when querying media files */
5843
- mediaUrl?: string | MediaUrlResolver;
5911
+ /** The public URL prefix used when querying media files */
5912
+ mediaUrl?: string;
5844
5913
  /** The main theme color used in the dashboard */
5845
5914
  color?: string;
5846
5915
  icon?: ComponentType;
5847
5916
  preview?: Preview;
5848
5917
  }
5849
- export type { MediaUrlMeta, MediaUrlResolver } from 'alinea/core/media/MediaLocation';
5850
5918
  type Roots = Record<string, Root>;
5851
5919
  export interface RootsDefinition {
5852
5920
  [key: string]: Root;
@@ -5874,6 +5942,7 @@ declare module 'alinea/core/Workspace' {
5874
5942
  export function workspace<Roots extends RootsDefinition>(
5875
5943
  /** The name of the workspace */
5876
5944
  label: string, config: WorkspaceConfig<Roots>): Workspace<Roots>;
5945
+ export {};
5877
5946
 
5878
5947
  }
5879
5948
 
@@ -5954,6 +6023,12 @@ declare module 'alinea/dashboard/app/AlineaLogo' {
5954
6023
 
5955
6024
  }
5956
6025
 
6026
+ declare module 'alinea/dashboard/app/AppearanceToggle' {
6027
+
6028
+ export function AppearanceToggle(): import("react").JSX.Element;
6029
+
6030
+ }
6031
+
5957
6032
  declare module 'alinea/dashboard/app/AppShell' {
5958
6033
 
5959
6034
  import { HTMLProps } from 'react';
@@ -5972,7 +6047,7 @@ declare module 'alinea/dashboard/app/AuthView' {
5972
6047
  action?: DashboardAuthAction
5973
6048
  ], unknown>;
5974
6049
  }
5975
- export function AuthView({ auth: authState }: AuthViewProps): import("react").JSX.Element | null;
6050
+ export function AuthView({ auth: authState }: AuthViewProps): import("react").JSX.Element;
5976
6051
 
5977
6052
  }
5978
6053
 
@@ -6044,20 +6119,20 @@ declare module 'alinea/dashboard/app/DashboardMeta' {
6044
6119
  export interface DashboardMetaProps {
6045
6120
  color: string;
6046
6121
  icon?: ComponentType;
6122
+ plain?: boolean;
6047
6123
  title: string;
6048
6124
  }
6049
- export function DashboardMeta({ color, icon, title }: DashboardMetaProps): import("react").JSX.Element;
6125
+ export function DashboardMeta({ color, icon, plain, title }: DashboardMetaProps): import("react").JSX.Element;
6050
6126
 
6051
6127
  }
6052
6128
 
6053
6129
  declare module 'alinea/dashboard/app/editor/FileEditor' {
6054
6130
 
6055
- import type { Entry } from 'alinea/core/Entry';
6056
6131
  export interface FileEditorProps {
6057
- entry: Pick<Entry, 'root' | 'url' | 'workspace'>;
6058
6132
  parentPaths: Array<string>;
6133
+ workspace: string;
6059
6134
  }
6060
- export function FileEditor({ entry, parentPaths }: FileEditorProps): import("react").JSX.Element;
6135
+ export function FileEditor({ parentPaths, workspace }: FileEditorProps): import("react").JSX.Element;
6061
6136
 
6062
6137
  }
6063
6138
 
@@ -6108,9 +6183,10 @@ declare module 'alinea/dashboard/app/EntryFields' {
6108
6183
  import type { EditorNode } from 'alinea/dashboard/atoms/editor';
6109
6184
  interface NodeEditorProps extends PropsWithChildren {
6110
6185
  node: EditorNode;
6186
+ readOnly?: boolean;
6111
6187
  type: Type;
6112
6188
  }
6113
- export function NodeEditor({ children, node, type }: NodeEditorProps): import("react").JSX.Element;
6189
+ export function NodeEditor({ children, node, readOnly, type }: NodeEditorProps): import("react").JSX.Element;
6114
6190
  export function FieldsEditor(): import("react").JSX.Element[];
6115
6191
  export function EntryFields(): import("react").JSX.Element[];
6116
6192
  export interface EditFieldsProps {
@@ -6121,6 +6197,7 @@ declare module 'alinea/dashboard/app/EntryFields' {
6121
6197
  field: Field;
6122
6198
  }
6123
6199
  export const EditField: import("react").MemoExoticComponent<({ field }: EditFieldProps) => import("react").JSX.Element | null>;
6200
+ export function fieldWidth(width?: number): string;
6124
6201
  export {};
6125
6202
 
6126
6203
  }
@@ -6148,8 +6225,6 @@ declare module 'alinea/dashboard/app/EntryHeader' {
6148
6225
  declare module 'alinea/dashboard/app/EntryHeaderActions' {
6149
6226
 
6150
6227
  import type { EntryStatus } from 'alinea/core/Entry';
6151
- export type EntryHeaderActionId = 'remove-draft' | 'replace' | 'unpublish' | 'archive' | 'publish' | 'delete';
6152
- export type EntryHeaderPrimaryActionId = 'create-draft' | 'save-translation' | 'discard-changes' | 'publish-edits' | 'save-draft' | 'publish-draft';
6153
6228
  interface EntryHeaderAccess {
6154
6229
  archive: boolean;
6155
6230
  delete: boolean;
@@ -6181,8 +6256,27 @@ declare module 'alinea/dashboard/app/EntryHeaderActions' {
6181
6256
  parentNeedsTranslation: boolean;
6182
6257
  untranslated: boolean;
6183
6258
  }
6184
- export function entryHeaderPrimaryActionIds({ access, activeStatus, canPublishParents, canSaveDraft, isDirty, isRevision, parentNeedsTranslation, untranslated }: EntryHeaderPrimaryActionState): Array<EntryHeaderPrimaryActionId>;
6185
- export function entryHeaderActionIds({ access, activeStatus, canDelete, canPublishParents, draftsEnabled, isDirty, isMediaFile, isMediaLibrary, isParentUnpublished, isRevision, isUnpublished, untranslated }: EntryHeaderActionState): Array<EntryHeaderActionId>;
6259
+ export interface EntryDirtyActions {
6260
+ publish: boolean;
6261
+ saveDraft: boolean;
6262
+ }
6263
+ export interface EntryHeaderPrimaryActions {
6264
+ createDraft: boolean;
6265
+ dirty: EntryDirtyActions | undefined;
6266
+ publishDraft: boolean;
6267
+ saveTranslation: boolean;
6268
+ }
6269
+ export interface EntryHeaderActions {
6270
+ archive: boolean;
6271
+ delete: boolean;
6272
+ publish: boolean;
6273
+ removeDraft: boolean;
6274
+ replace: boolean;
6275
+ unpublish: boolean;
6276
+ }
6277
+ export function entryDirtyActions(canPublish: boolean, canSaveDraft: boolean): EntryDirtyActions;
6278
+ export function entryHeaderPrimaryActions({ access, activeStatus, canPublishParents, canSaveDraft, isDirty, isRevision, parentNeedsTranslation, untranslated }: EntryHeaderPrimaryActionState): EntryHeaderPrimaryActions;
6279
+ export function entryHeaderActions({ access, activeStatus, canDelete, canPublishParents, draftsEnabled, isDirty, isMediaFile, isMediaLibrary, isParentUnpublished, isRevision, isUnpublished, untranslated }: EntryHeaderActionState): EntryHeaderActions;
6186
6280
  export {};
6187
6281
 
6188
6282
  }
@@ -6274,12 +6368,14 @@ declare module 'alinea/dashboard/app/EntrySidebarToggle' {
6274
6368
  declare module 'alinea/dashboard/app/EntryTranslationBanner' {
6275
6369
 
6276
6370
  export interface EntryTranslationBannerProps {
6371
+ copyFromSource: boolean;
6277
6372
  parentNeedsTranslation: boolean;
6278
6373
  sourceLocale: string | null;
6279
6374
  sourceLocales: ReadonlyArray<string>;
6375
+ onCopyFromSourceChange: (copyFromSource: boolean) => void;
6280
6376
  onSourceLocaleChange: (locale: string) => void;
6281
6377
  }
6282
- export const EntryTranslationBanner: import("react").MemoExoticComponent<({ parentNeedsTranslation, sourceLocale, sourceLocales, onSourceLocaleChange }: EntryTranslationBannerProps) => import("react").JSX.Element>;
6378
+ export const EntryTranslationBanner: import("react").MemoExoticComponent<({ copyFromSource, parentNeedsTranslation, sourceLocale, sourceLocales, onCopyFromSourceChange, onSourceLocaleChange }: EntryTranslationBannerProps) => import("react").JSX.Element>;
6283
6379
 
6284
6380
  }
6285
6381
 
@@ -6293,6 +6389,7 @@ declare module 'alinea/dashboard/app/Explorer' {
6293
6389
  explorer: DashboardExplorer;
6294
6390
  headerEntry?: ExplorerHeaderEntry;
6295
6391
  page: ExplorerReadyPage;
6392
+ readOnly?: boolean;
6296
6393
  titleControls?: ReactNode;
6297
6394
  }
6298
6395
  export interface ExplorerHeaderEntry {
@@ -6308,6 +6405,7 @@ declare module 'alinea/dashboard/app/Explorer' {
6308
6405
  headerEntry?: ExplorerHeaderEntry;
6309
6406
  navigate?: boolean;
6310
6407
  page: ExplorerReadyPage;
6408
+ readOnly?: boolean;
6311
6409
  titleControls?: ReactNode;
6312
6410
  }
6313
6411
  export interface ExplorerBodyProps {
@@ -6323,9 +6421,9 @@ declare module 'alinea/dashboard/app/Explorer' {
6323
6421
  page: ExplorerReadyPage;
6324
6422
  }
6325
6423
  export function ExplorerSearch({ autoFocus, explorer, onEntryAction, page }: ExplorerSearchProps): import("react").JSX.Element;
6326
- export function ExplorerHeader({ canBrowse, autoFocusSearch, controls, explorer, headerEntry, navigate, page, titleControls }: ExplorerHeaderProps): import("react").JSX.Element;
6424
+ export function ExplorerHeader({ canBrowse, autoFocusSearch, controls, explorer, headerEntry, navigate, page, readOnly, titleControls }: ExplorerHeaderProps): import("react").JSX.Element;
6327
6425
  export function ExplorerBody({ compactTable, explorer, onSelectionChange, page }: ExplorerBodyProps): import("react").JSX.Element;
6328
- export function Explorer({ controls, explorer, headerEntry, page: loadedPage, titleControls }: ExplorerProps): import("react").JSX.Element;
6426
+ export function Explorer({ controls, explorer, headerEntry, page: loadedPage, readOnly, titleControls }: ExplorerProps): import("react").JSX.Element;
6329
6427
  export {};
6330
6428
 
6331
6429
  }
@@ -6484,7 +6582,14 @@ declare module 'alinea/dashboard/app/LocaleMenu' {
6484
6582
  locale: string | null;
6485
6583
  onLocaleChange(locale: string): void;
6486
6584
  }
6585
+ export interface LocaleMenuSelectProps {
6586
+ ariaLabel?: string;
6587
+ locale: string | null;
6588
+ locales: ReadonlyArray<string>;
6589
+ onLocaleChange(locale: string): void;
6590
+ }
6487
6591
  export function LocaleMenu({ root, locale, onLocaleChange }: LocaleMenuProps): import("react").JSX.Element | null;
6592
+ export function LocaleMenuSelect({ ariaLabel, locale, locales, onLocaleChange }: LocaleMenuSelectProps): import("react").JSX.Element | null;
6488
6593
  export {};
6489
6594
 
6490
6595
  }
@@ -6538,6 +6643,14 @@ declare module 'alinea/dashboard/app/pages/RootPage' {
6538
6643
 
6539
6644
  }
6540
6645
 
6646
+ declare module 'alinea/dashboard/app/pages/SplashPage' {
6647
+
6648
+ import { type Getter } from 'jotai';
6649
+ import type { ReactNode } from 'react';
6650
+ export function splashPage(get: Getter): Promise<ReactNode>;
6651
+
6652
+ }
6653
+
6541
6654
  declare module 'alinea/dashboard/app/pages/UsersPage' {
6542
6655
 
6543
6656
  import { Page } from 'alinea/dashboard/atoms/nav';
@@ -6550,6 +6663,15 @@ declare module 'alinea/dashboard/app/pages/UsersPage' {
6550
6663
 
6551
6664
  }
6552
6665
 
6666
+ declare module 'alinea/dashboard/app/ReadOnlyBadge' {
6667
+
6668
+ import type { ComponentPropsWithoutRef } from 'react';
6669
+ export interface ReadOnlyBadgeProps extends ComponentPropsWithoutRef<'span'> {
6670
+ }
6671
+ export function ReadOnlyBadge(props: ReadOnlyBadgeProps): import("react").JSX.Element;
6672
+
6673
+ }
6674
+
6553
6675
  declare module 'alinea/dashboard/app/SidebarLayout' {
6554
6676
 
6555
6677
  import { type ReactNode } from 'react';
@@ -6567,7 +6689,7 @@ declare module 'alinea/dashboard/app/SidebarTree' {
6567
6689
 
6568
6690
  import { type Page } from 'alinea/dashboard/atoms/nav';
6569
6691
  import type { RootAtoms, RootTreeItem, RootTreeNode, TreeAtoms } from 'alinea/dashboard/atoms/root';
6570
- import { type Atom, type WritableAtom } from 'jotai';
6692
+ import { type WritableAtom } from 'jotai';
6571
6693
  import { type ReactNode } from 'react';
6572
6694
  import { type Selection } from 'react-aria-components';
6573
6695
  export interface SidebarTreeProps {
@@ -6586,16 +6708,13 @@ declare module 'alinea/dashboard/app/SidebarTree' {
6586
6708
  }
6587
6709
  interface SidebarTreeItemProps {
6588
6710
  children?: ReactNode;
6711
+ data: RootTreeItem;
6589
6712
  entryLink?: (entry: RootTreeItem) => SidebarTreeLink;
6590
6713
  item: RootTreeNode;
6591
6714
  locale: string | null;
6592
6715
  selectedItem?: RootTreeItem;
6593
- tree: SidebarTreeItemSource;
6594
- }
6595
- interface SidebarTreeItemSource {
6596
- item(id: string): Atom<RootTreeItem>;
6597
6716
  }
6598
- export const SidebarTreeItem: import("react").MemoExoticComponent<({ children, entryLink, item, locale, selectedItem, tree }: SidebarTreeItemProps) => import("react").JSX.Element>;
6717
+ export const SidebarTreeItem: import("react").MemoExoticComponent<({ children, data, entryLink, item, locale, selectedItem }: SidebarTreeItemProps) => import("react").JSX.Element>;
6599
6718
  interface SidebarTreeLink {
6600
6719
  href: string;
6601
6720
  }
@@ -6715,7 +6834,7 @@ declare module 'alinea/dashboard/app/WorkspaceMenu' {
6715
6834
  import type { WorkspaceInternal } from 'alinea/core/Workspace';
6716
6835
  import type { Page } from 'alinea/dashboard/atoms/nav';
6717
6836
  import type { RootAtoms } from 'alinea/dashboard/atoms/root';
6718
- import { type ComponentType } from 'react';
6837
+ import { type ComponentType, type ReactNode } from 'react';
6719
6838
  interface WorkspaceMenuProps {
6720
6839
  canManageMembers: boolean;
6721
6840
  page: Page;
@@ -6727,14 +6846,21 @@ declare module 'alinea/dashboard/app/WorkspaceMenu' {
6727
6846
  interface WorkspaceAvatarProps {
6728
6847
  color: string;
6729
6848
  icon?: ComponentType;
6730
- size?: 'default' | 'small';
6849
+ size?: 'default' | 'large' | 'small';
6731
6850
  }
6732
6851
  function WorkspaceAvatar({ color, icon, size }: WorkspaceAvatarProps): import("react").JSX.Element;
6733
6852
  export { WorkspaceAvatar };
6734
6853
  interface WorkspaceAvatarMenuProps {
6735
6854
  page: Page;
6855
+ root: RootAtoms;
6736
6856
  }
6737
- export function WorkspaceAvatarMenu({ page }: WorkspaceAvatarMenuProps): import("react").JSX.Element;
6857
+ export function WorkspaceAvatarMenu({ page, root }: WorkspaceAvatarMenuProps): import("react").JSX.Element;
6858
+ interface GlobalSearchProps {
6859
+ children: ReactNode;
6860
+ initialSearchScope?: 'everything' | 'workspace';
6861
+ root: RootAtoms;
6862
+ }
6863
+ export function GlobalSearch({ children, initialSearchScope, root }: GlobalSearchProps): import("react").JSX.Element;
6738
6864
  export function WorkspaceMenu({ canManageMembers, page, root, workspace }: WorkspaceMenuProps): import("react").JSX.Element;
6739
6865
 
6740
6866
  }
@@ -6748,6 +6874,8 @@ declare module 'alinea/dashboard/app/WorkspaceMenu.spec' {
6748
6874
  declare module 'alinea/dashboard/app/WorkspaceMenu.stories' {
6749
6875
 
6750
6876
  export function GlobalSearchStory(): import("react").JSX.Element;
6877
+ export function SingleWorkspaceAvatarStory(): import("react").JSX.Element;
6878
+ export function LocalizedGlobalSearchStory(): import("react").JSX.Element;
6751
6879
  const _default: {
6752
6880
  title: string;
6753
6881
  };
@@ -6758,11 +6886,13 @@ declare module 'alinea/dashboard/app/WorkspaceMenu.stories' {
6758
6886
  declare module 'alinea/dashboard/app/WorkspaceRoots' {
6759
6887
 
6760
6888
  import type { Page } from 'alinea/dashboard/atoms/nav';
6889
+ import { type RootAtoms } from 'alinea/dashboard/atoms/root';
6761
6890
  export interface WorkspaceRootsProps {
6762
6891
  canManageMembers: boolean;
6763
6892
  page: Page;
6893
+ root: RootAtoms;
6764
6894
  }
6765
- export function WorkspaceRoots({ canManageMembers, page }: WorkspaceRootsProps): import("react").JSX.Element;
6895
+ export function WorkspaceRoots({ canManageMembers, page, root: currentRoot }: WorkspaceRootsProps): import("react").JSX.Element;
6766
6896
 
6767
6897
  }
6768
6898
 
@@ -6775,7 +6905,6 @@ declare module 'alinea/dashboard/atoms/activity' {
6775
6905
  isFetchingUpdates: boolean;
6776
6906
  isMutating: boolean;
6777
6907
  hasFailed: boolean;
6778
- hasFailedMutations: boolean;
6779
6908
  hasBlocked: boolean;
6780
6909
  canRetry: boolean;
6781
6910
  canDiscard: boolean;
@@ -6821,6 +6950,7 @@ declare module 'alinea/dashboard/atoms/activity' {
6821
6950
 
6822
6951
  declare module 'alinea/dashboard/atoms/auth' {
6823
6952
 
6953
+ import type { BackendCapabilities } from 'alinea/core/Connection';
6824
6954
  import { User } from 'alinea/core/User';
6825
6955
  export const authRequiredAtom: import("jotai").Atom<boolean>;
6826
6956
  export interface DashboardAuthLoading {
@@ -6843,6 +6973,7 @@ declare module 'alinea/dashboard/atoms/auth' {
6843
6973
  export interface DashboardAuthAuthenticated {
6844
6974
  status: 'authenticated';
6845
6975
  user: User;
6976
+ capabilities?: BackendCapabilities;
6846
6977
  }
6847
6978
  export type DashboardAuthState = DashboardAuthLoading | DashboardAuthMissingHandler | DashboardAuthMissingApiKey | DashboardAuthRedirecting | DashboardAuthError | DashboardAuthAuthenticated;
6848
6979
  interface DashboardAuthCheck {
@@ -7014,9 +7145,10 @@ declare module 'alinea/dashboard/atoms/editor' {
7014
7145
  policy?: Policy | undefined;
7015
7146
  resolvedImages: ReadonlyMap<string, ResolvedEditorImage>;
7016
7147
  anchors: Atom<Array<EntryAnchorTarget>>;
7148
+ readonly readOnly: boolean;
7017
7149
  value: Atom<object>;
7018
7150
  sections: Array<EntryEditorSection>;
7019
- constructor(type: Type, node: EditorNode, parent?: EntryEditor | undefined, resource?: Resource | undefined, policy?: Policy | undefined, resolvedImages?: ReadonlyMap<string, ResolvedEditorImage>);
7151
+ constructor(type: Type, node: EditorNode, parent?: EntryEditor | undefined, resource?: Resource | undefined, policy?: Policy | undefined, resolvedImages?: ReadonlyMap<string, ResolvedEditorImage>, readOnly?: boolean);
7020
7152
  field: (key: string) => EntryEditorField | undefined;
7021
7153
  get(field: Field): EntryEditorField | undefined;
7022
7154
  }
@@ -7111,6 +7243,7 @@ declare module 'alinea/dashboard/atoms/entry' {
7111
7243
  init: ReactiveNode<object> | undefined;
7112
7244
  };
7113
7245
  untranslated: Atom<boolean>;
7246
+ copyTranslationSource: import("jotai").WritableAtom<boolean, [next: boolean], void>;
7114
7247
  translationSourceLocale: import("jotai").WritableAtom<string, [next: string], void>;
7115
7248
  parentNeedsTranslation: Atom<Promise<boolean>>;
7116
7249
  selectedVersion: import("jotai").PrimitiveAtom<SelectedVersion | null> & {
@@ -7118,6 +7251,7 @@ declare module 'alinea/dashboard/atoms/entry' {
7118
7251
  };
7119
7252
  versions: Atom<Map<EntryStatus, Entry<Record<string, unknown>>>>;
7120
7253
  availableStatuses: Atom<EntryStatus[]>;
7254
+ preferredEntry: Atom<Entry<Record<string, unknown>>>;
7121
7255
  selectedEntry: Atom<Promise<Entry<Record<string, unknown>>>>;
7122
7256
  historyReady: Atom<Promise<import("alinea/core/Connection").Revision[]>>;
7123
7257
  history: Atom<import("alinea/core/Connection").Revision[]>;
@@ -7362,7 +7496,6 @@ declare module 'alinea/dashboard/atoms/explorer' {
7362
7496
  condition?: Filter<EntryFields>;
7363
7497
  defaultOrderBy?: Atom<OrderBy | Array<OrderBy> | undefined>;
7364
7498
  enableNavigation?: boolean;
7365
- hideResultsUntilSearch?: boolean;
7366
7499
  initialView?: ExplorerView;
7367
7500
  initialResultMode?: ExplorerResultMode;
7368
7501
  initialSearchScope?: 'workspace' | 'everything';
@@ -7384,7 +7517,7 @@ declare module 'alinea/dashboard/atoms/explorer' {
7384
7517
  initialSelection?: Array<string>;
7385
7518
  searchDepth?: 'current' | 'all';
7386
7519
  onAction?: (entry: ExplorerEntry) => void;
7387
- onConfirm?: (selection: Array<string>) => void;
7520
+ onConfirm?: (selection: Array<string>, locale: string | null) => void;
7388
7521
  preselect?: boolean;
7389
7522
  }
7390
7523
  export interface ExplorerTreeItem {
@@ -7396,12 +7529,14 @@ declare module 'alinea/dashboard/atoms/explorer' {
7396
7529
  }
7397
7530
  export type ExplorerResultMode = 'browse' | 'matches';
7398
7531
  export interface ExplorerReadyPage {
7532
+ canUpload: boolean;
7399
7533
  isMedia: boolean;
7400
7534
  items: Array<ExplorerEntry>;
7401
7535
  locale: string | null;
7402
7536
  location: ExplorerLocation;
7403
7537
  root: ExplorerRootData;
7404
7538
  resultMode: ExplorerResultMode;
7539
+ search: string;
7405
7540
  searchScope: 'workspace' | 'everything';
7406
7541
  searchesEverything: boolean;
7407
7542
  view: ExplorerView;
@@ -7511,7 +7646,6 @@ declare module 'alinea/dashboard/atoms/explorer' {
7511
7646
  readonly hasRowAction: boolean;
7512
7647
  readonly mode: 'browse' | 'search';
7513
7648
  readonly hasSelection: boolean;
7514
- readonly hideResultsUntilSearch: boolean;
7515
7649
  readonly linkedKeys: ReadonlySet<Key>;
7516
7650
  readonly searchDepth: "all" | "current";
7517
7651
  readonly supportsInlineExpansion: boolean;
@@ -7543,7 +7677,6 @@ declare module 'alinea/dashboard/atoms/explorer' {
7543
7677
  constructor(location: WritableAtom<ExplorerLocation, [
7544
7678
  SetStateAction<ExplorerLocation>
7545
7679
  ], void>, options: ExplorerOptions, initialLocation: ExplorerLocation);
7546
- showResults: Atom<boolean>;
7547
7680
  isMedia: Atom<boolean>;
7548
7681
  view: WritableAtom<ExplorerView, [view: ExplorerView], void>;
7549
7682
  sort: WritableAtom<ExplorerSort, [sortBy: ExplorerSortBy], void>;
@@ -7551,7 +7684,7 @@ declare module 'alinea/dashboard/atoms/explorer' {
7551
7684
  get limitLocations(): ExplorerLimitLocation[] | undefined;
7552
7685
  canUpload: Atom<boolean>;
7553
7686
  uploadsInCurrentFolder: Atom<import("alinea/dashboard/boot/ActivityEvent").Activity[]>;
7554
- upload: WritableAtom<null, [files: ArrayLike<File> | Iterable<File>], void> & {
7687
+ upload: WritableAtom<null, [files: ArrayLike<File> | Iterable<File>], Promise<void>> & {
7555
7688
  init: null;
7556
7689
  };
7557
7690
  getItems: WritableAtom<null, [keys: Set<Key>], DragItem[]> & {
@@ -7569,7 +7702,7 @@ declare module 'alinea/dashboard/atoms/explorer' {
7569
7702
  openLocation: WritableAtom<null, [entry: ExplorerEntry], void> & {
7570
7703
  init: null;
7571
7704
  };
7572
- onConfirm: WritableAtom<null, [], void> & {
7705
+ onConfirm: WritableAtom<null, [locale?: string | null | undefined], void> & {
7573
7706
  init: null;
7574
7707
  };
7575
7708
  isExpanded: (entry: ExplorerEntry) => Atom<boolean>;
@@ -7592,6 +7725,7 @@ declare module 'alinea/dashboard/atoms/graph' {
7592
7725
  export const syncAtom: import("jotai").WritableAtom<null, [], Promise<string | undefined>> & {
7593
7726
  init: null;
7594
7727
  };
7728
+ export const graphReadyAtom: import("jotai").Atom<Promise<void>>;
7595
7729
 
7596
7730
  }
7597
7731
 
@@ -7620,7 +7754,7 @@ declare module 'alinea/dashboard/atoms/link' {
7620
7754
  state: 'hasError';
7621
7755
  error: Error;
7622
7756
  };
7623
- export const linkEntryAtoms: (id: string) => import("jotai").Atom<LinkEntryState>;
7757
+ export const linkEntryAtoms: (id: string, locale?: string | undefined) => import("jotai").Atom<LinkEntryState>;
7624
7758
 
7625
7759
  }
7626
7760
 
@@ -7639,7 +7773,7 @@ declare module 'alinea/dashboard/atoms/nav' {
7639
7773
  init: RouteBlock | null;
7640
7774
  };
7641
7775
  export interface DashboardRoute {
7642
- page?: 'entry' | 'users';
7776
+ page?: 'splash' | 'entry' | 'users';
7643
7777
  workspace?: string;
7644
7778
  root?: string;
7645
7779
  entry?: string;
@@ -7647,9 +7781,10 @@ declare module 'alinea/dashboard/atoms/nav' {
7647
7781
  view?: EntryDefaultView;
7648
7782
  }
7649
7783
  interface ResolvedDashboardRoute extends DashboardRoute {
7650
- page: 'entry' | 'users';
7784
+ page: 'splash' | 'entry' | 'users';
7651
7785
  }
7652
7786
  export const nav: {
7787
+ splash(): string;
7653
7788
  users(): string;
7654
7789
  entry(workspace?: string, root?: string, entryId?: string, locale?: string | null, view?: EntryDefaultView): string;
7655
7790
  };
@@ -7662,7 +7797,7 @@ declare module 'alinea/dashboard/atoms/nav' {
7662
7797
  onMount(navigate: (request: NavigationRequest) => void): (() => void) | undefined;
7663
7798
  };
7664
7799
  export interface Page {
7665
- type: 'users' | 'entry';
7800
+ type: 'splash' | 'users' | 'entry';
7666
7801
  workspace: string | undefined;
7667
7802
  root: string | undefined;
7668
7803
  requestedRoot?: string;
@@ -7743,7 +7878,7 @@ declare module 'alinea/dashboard/atoms/root' {
7743
7878
  import { type Atom, type PrimitiveAtom } from 'jotai';
7744
7879
  import type { ComponentType } from 'react';
7745
7880
  import type { DroppableCollectionInsertDropEvent, DroppableCollectionOnItemDropEvent, DroppableCollectionReorderEvent, Key } from 'react-aria-components';
7746
- import { LucideFile } from 'alinea/dashboard/icons';
7881
+ import { IcOutlineDescription } from 'alinea/dashboard/icons';
7747
7882
  import { type TreeEntryAtoms } from 'alinea/dashboard/atoms/entry';
7748
7883
  export interface RootViewProps {
7749
7884
  root: RootData;
@@ -7769,6 +7904,10 @@ declare module 'alinea/dashboard/atoms/root' {
7769
7904
  items: Array<RootTreeNode>;
7770
7905
  selectedKeys: Set<string>;
7771
7906
  }
7907
+ export interface TreeView {
7908
+ entries: Map<string, RootTreeItem>;
7909
+ snapshot: TreeSnapshot;
7910
+ }
7772
7911
  interface TreeCollapseState {
7773
7912
  selectedId: string | undefined;
7774
7913
  keys: Set<string>;
@@ -7782,6 +7921,7 @@ declare module 'alinea/dashboard/atoms/root' {
7782
7921
  expandedKeys: PrimitiveAtom<Set<string>>;
7783
7922
  collapsedKeys: PrimitiveAtom<TreeCollapseState>;
7784
7923
  constructor(root: RootAtoms, locale: string | null, selectedKeys: Atom<Set<Key>>, viewState?: TreeViewState);
7924
+ view: Atom<TreeView>;
7785
7925
  snapshot: Atom<TreeSnapshot>;
7786
7926
  items: Atom<RootTreeItem[]>;
7787
7927
  children: (id: string) => Atom<Promise<TreeEntryAtoms[]>>;
@@ -7805,7 +7945,7 @@ declare module 'alinea/dashboard/atoms/root' {
7805
7945
  treeEntries: (locale: string | null) => Atom<Promise<TreeEntryAtoms[]>>;
7806
7946
  children: (parentId: string | null) => ExplorerAtoms;
7807
7947
  label: Atom<string>;
7808
- icon: Atom<typeof LucideFile | ComponentType>;
7948
+ icon: Atom<typeof IcOutlineDescription | ComponentType>;
7809
7949
  i18n: Atom<RootI18n | undefined>;
7810
7950
  isMedia: Atom<boolean>;
7811
7951
  canCreate: Atom<boolean>;
@@ -7837,6 +7977,7 @@ declare module 'alinea/dashboard/atoms/upload' {
7837
7977
  workspace: string;
7838
7978
  root: string;
7839
7979
  parentId?: string;
7980
+ parents?: Array<string>;
7840
7981
  }
7841
7982
  export const uploadFilesAtom: import("jotai").WritableAtom<null, [request: UploadFilesRequest], Promise<void>> & {
7842
7983
  init: null;
@@ -7853,7 +7994,7 @@ declare module 'alinea/dashboard/atoms/user' {
7853
7994
  export const preloadUserPolicyAtom: import("jotai").WritableAtom<null, [user: User, policy: Policy], void> & {
7854
7995
  init: null;
7855
7996
  };
7856
- export const authReady: import("jotai").Atom<Promise<void>>;
7997
+ export const userPolicyReadyAtom: import("jotai").Atom<Promise<void>>;
7857
7998
  export const canManageMembersAtom: import("jotai").Atom<Promise<boolean>>;
7858
7999
 
7859
8000
  }
@@ -8179,6 +8320,18 @@ declare module 'alinea/dashboard/fixture/cms' {
8179
8320
  pages: import("alinea").Root<import("alinea/core/Root").ChildrenDefinition>;
8180
8321
  media: import("alinea/core/media/MediaRoot").MediaRoot<import("alinea/core/Root").ChildrenDefinition>;
8181
8322
  }>;
8323
+ manyRoots: import("alinea").Workspace<{
8324
+ pages: import("alinea").Root<import("alinea/core/Root").ChildrenDefinition>;
8325
+ articles: import("alinea").Root<import("alinea/core/Root").ChildrenDefinition>;
8326
+ documentation: import("alinea").Root<import("alinea/core/Root").ChildrenDefinition>;
8327
+ campaigns: import("alinea").Root<import("alinea/core/Root").ChildrenDefinition>;
8328
+ translations: import("alinea").Root<import("alinea/core/Root").ChildrenDefinition>;
8329
+ archive: import("alinea").Root<import("alinea/core/Root").ChildrenDefinition>;
8330
+ settings: import("alinea").Root<import("alinea/core/Root").ChildrenDefinition>;
8331
+ brandAssets: import("alinea").Root<import("alinea/core/Root").ChildrenDefinition>;
8332
+ nestedContent: import("alinea").Root<import("alinea/core/Root").ChildrenDefinition>;
8333
+ media: import("alinea/core/media/MediaRoot").MediaRoot<import("alinea/core/Root").ChildrenDefinition>;
8334
+ }>;
8182
8335
  };
8183
8336
  }>;
8184
8337
 
@@ -8247,6 +8400,12 @@ declare module 'alinea/dashboard/hook/UseRoot' {
8247
8400
 
8248
8401
  }
8249
8402
 
8403
+ declare module 'alinea/dashboard/hook/UseSaveShortcut' {
8404
+
8405
+ export function useSaveShortcut(action: (() => void) | undefined, disabled: boolean): void;
8406
+
8407
+ }
8408
+
8250
8409
  declare module 'alinea/dashboard/hook/UseWorkspace' {
8251
8410
 
8252
8411
  import type { WorkspaceInternal } from 'alinea/core/Workspace';
@@ -8362,7 +8521,7 @@ declare module 'alinea/dashboard/hooks' {
8362
8521
  /**
8363
8522
  * Creates an editor for a nested reactive node.
8364
8523
  */
8365
- export function useNodeEditor(node: EditorNode, type: Type): EntryEditor;
8524
+ export function useNodeEditor(node: EditorNode, type: Type, readOnly?: boolean): EntryEditor;
8366
8525
  /**
8367
8526
  * Returns the reactive node backing a field in the active editor.
8368
8527
  */
@@ -9488,10 +9647,10 @@ declare module 'alinea/field/metadata/MetadataField' {
9488
9647
  updatedAt: number | null;
9489
9648
  updatedBy: MetadataAuditUser;
9490
9649
  }
9491
- export class MetadataField extends RecordField<Metadata, {
9492
- label: string;
9650
+ export interface MetadataOptions extends FieldOptions<Metadata> {
9493
9651
  fields: Type<MetadataFields>;
9494
- }> {
9652
+ }
9653
+ export class MetadataField extends RecordField<Metadata, MetadataOptions> {
9495
9654
  }
9496
9655
  export interface MetadataField extends MetadataFields {
9497
9656
  }
@@ -9700,6 +9859,7 @@ declare module 'alinea/field/richtext/extensions/Link' {
9700
9859
  interface LinkAttributes {
9701
9860
  'data-id'?: string;
9702
9861
  'data-entry'?: string;
9862
+ 'data-locale'?: string;
9703
9863
  'data-anchor'?: string;
9704
9864
  'data-link'?: string;
9705
9865
  'data-suffix'?: string;
@@ -9813,9 +9973,11 @@ declare module 'alinea/field/richtext/ReferenceLink' {
9813
9973
  interface Anchor extends HTMLProps<HTMLAnchorElement> {
9814
9974
  _id?: string;
9815
9975
  _entry?: string;
9976
+ _locale?: string;
9816
9977
  _link?: 'entry' | 'file' | 'image' | 'url';
9817
9978
  'data-id'?: string;
9818
9979
  'data-entry'?: string;
9980
+ 'data-locale'?: string;
9819
9981
  'data-anchor'?: string;
9820
9982
  'data-link'?: 'entry' | 'file' | 'image' | 'url';
9821
9983
  'data-suffix'?: string;
@@ -10519,8 +10681,6 @@ declare module 'alinea/field/time/TimeField' {
10519
10681
  minValue?: string;
10520
10682
  /** A maximum value */
10521
10683
  maxValue?: string;
10522
- /** Specifies the legal time intervals */
10523
- step?: number;
10524
10684
  }
10525
10685
  /** Internal representation of a date field */
10526
10686
  export class TimeField extends ScalarField<string, TimeOptions> {
@@ -10669,11 +10829,13 @@ declare module 'alinea/picker/entry/EntryReference' {
10669
10829
  export interface EntryReference extends Reference {
10670
10830
  _type: 'entry' | 'image' | 'file';
10671
10831
  _entry: string;
10832
+ _locale?: string;
10672
10833
  _anchor?: string;
10673
10834
  _suffix?: string;
10674
10835
  }
10675
10836
  export namespace EntryReference {
10676
10837
  const entry = "_entry";
10838
+ const locale = "_locale";
10677
10839
  const anchor = "_anchor";
10678
10840
  const suffix = "_suffix";
10679
10841
  function isEntryReference(value: any): value is EntryReference;
@@ -10782,7 +10944,11 @@ declare module 'alinea/preview/PreviewPayload' {
10782
10944
  declare module 'alinea/preview/react' {
10783
10945
 
10784
10946
  import { type PreviewApi } from 'alinea/preview/RegisterPreview';
10785
- export function usePreview(api: Omit<PreviewApi, 'setIsPreviewing'>): {
10947
+ export interface UsePreviewOptions {
10948
+ hostOrigin: string;
10949
+ preview: PreviewApi['preview'];
10950
+ }
10951
+ export function usePreview(options: UsePreviewOptions): {
10786
10952
  isPreviewing: boolean;
10787
10953
  };
10788
10954
 
@@ -10795,7 +10961,7 @@ declare module 'alinea/preview/RegisterPreview' {
10795
10961
  preview(update: PreviewPayload): Promise<void>;
10796
10962
  setIsPreviewing(isPreviewing: boolean): void;
10797
10963
  }
10798
- export function registerPreview(api: PreviewApi): (() => void) | undefined;
10964
+ export function registerPreview(api: PreviewApi, hostOrigin: string): (() => void) | undefined;
10799
10965
 
10800
10966
  }
10801
10967
 
@@ -11081,7 +11247,6 @@ declare module 'alinea/types' {
11081
11247
  export type { Schema } from 'alinea/core/Schema';
11082
11248
  export type { TextDoc } from 'alinea/core/TextDoc';
11083
11249
  export type { Type } from 'alinea/core/Type';
11084
- export type { MediaUrlMeta, MediaUrlResolver } from 'alinea/core/media/MediaLocation';
11085
11250
  export type { Workspace } from 'alinea/core/Workspace';
11086
11251
  export type { EntryLink } from 'alinea/field/link/EntryLink';
11087
11252
  export type { FileLink } from 'alinea/field/link/FileLink';