@valbuild/shared 0.150.12 → 0.150.16

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 (24) hide show
  1. package/CHANGELOG.md +31 -0
  2. package/client/dist/valbuild-shared-client.cjs.dev.js +2 -1
  3. package/client/dist/valbuild-shared-client.cjs.prod.js +2 -1
  4. package/client/dist/valbuild-shared-client.esm.js +1 -1
  5. package/dist/declarations/src/client/index.d.ts +1 -0
  6. package/dist/declarations/src/internal/ApiRoutes.d.ts +375 -94
  7. package/dist/declarations/src/internal/aiTools/toolNames.d.ts +1 -1
  8. package/dist/declarations/src/internal/index.d.ts +3 -0
  9. package/dist/declarations/src/internal/localeAt.d.ts +86 -1
  10. package/dist/declarations/src/internal/localeRelocation.d.ts +46 -0
  11. package/dist/declarations/src/internal/pageScreenshot.d.ts +40 -0
  12. package/dist/declarations/src/internal/server/types.d.ts +3 -3
  13. package/dist/declarations/src/internal/sketchpad/sketchFormat.d.ts +118 -0
  14. package/dist/declarations/src/internal/valCanvasProtocol.d.ts +21 -0
  15. package/dist/declarations/src/internal/zod/History.d.ts +7 -7
  16. package/dist/declarations/src/internal/zod/Patch.d.ts +1 -0
  17. package/dist/declarations/src/internal/zod/SerializedSchema.d.ts +20 -2
  18. package/dist/{getSitemapTree-97b3166f.esm.js → getSitemapTree-7c848c94.esm.js} +137 -2
  19. package/dist/{getSitemapTree-5354ce90.cjs.prod.js → getSitemapTree-97713490.cjs.prod.js} +155 -1
  20. package/dist/{getSitemapTree-d934ff9c.cjs.dev.js → getSitemapTree-98642b57.cjs.dev.js} +155 -1
  21. package/internal/dist/valbuild-shared-internal.cjs.dev.js +837 -15
  22. package/internal/dist/valbuild-shared-internal.cjs.prod.js +837 -15
  23. package/internal/dist/valbuild-shared-internal.esm.js +821 -17
  24. package/package.json +2 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,36 @@
1
1
  # @valbuild/shared
2
2
 
3
+ ## 0.150.16
4
+
5
+ ### Patch Changes
6
+
7
+ - [#940](https://github.com/valbuild/val/pull/940) [`3ac24d4`](https://github.com/valbuild/val/commit/3ac24d46691c646dd5d2789cf2e1d6e2734195d3) Thanks [@freekh](https://github.com/freekh)! - Picking a language in the Studio now scopes the whole Studio to it.
8
+
9
+ - The Pages tree, the Data list, lists inside a field and search show only content in that language, plus content in no language (settings, authors, images), which every language shares. A page is in a language when its route names it (`s.router(router, { locale: … }, item)`) or its content has an `s.locale()` field.
10
+ - Picking a language while you are on something in another one moves you: to the same entry in the new language where Val knows it (a record keyed by `s.locale()`, or a route that differs only in its language segment), otherwise to the nearest parent that is not in another language, otherwise to the Studio's start screen with nothing selected.
11
+ - A link or a reference to something in another language still opens it, and that one item is listed while you are on it.
12
+ - Publish, Discard all and the error count are not filtered: they act on every language.
13
+
14
+ - [#969](https://github.com/valbuild/val/pull/969) [`7db39ef`](https://github.com/valbuild/val/commit/7db39ef722b4f743e6974effd5fedfadc76e6544) Thanks [@freekh](https://github.com/freekh)! - **Sketchpad**: work out a page's content and rough layout with the assistant before anyone builds it.
15
+
16
+ A sketchpad is a document of headings, text, boxes and columns, where you edit the text in place. A box can show an image or a video from a link: paste one, or drag an image in from a web page. The assistant sees the same sketch as text in one strict format, so what it reads is what is on screen. It has tools to list, create, read and write sketchpads, and **Send to AI** asks it to read the one you are on.
17
+
18
+ - Sketchpads live on the server, apart from any chat or page. They outlast the chat they started in, and the page a sketchpad is about can be changed. A sketchpad can be archived and reopened.
19
+ - Open one from a page's menu (**Sketch changes**), from the top bar, or when the assistant offers one.
20
+ - On a desktop the page, the sketchpad and the chat sit side by side, the chat docked beside them. On a phone a sketchpad can go full screen, with the page one tap away and the buttons at the bottom.
21
+ - In local development sketchpads are stored in `.val/sketchpads/`. A hosted project needs the content host's sketchpad API; without it the Studio does not offer sketchpads.
22
+
23
+ ## 0.150.13
24
+
25
+ ### Patch Changes
26
+
27
+ - [#985](https://github.com/valbuild/val/pull/985) [`0cd38eb`](https://github.com/valbuild/val/commit/0cd38eb62c80e2b3989aa45a6c9c75b02fc27cd1) Thanks [@freekh](https://github.com/freekh)! - The design tab's assistant can check its work two more ways.
28
+
29
+ - **`lint`** runs Val's own eslint rules -- the ones `@valbuild/eslint-plugin` runs in an editor -- over the proposal's files: a `c.define` path that is not the file's own, a module missing from `val.modules.ts`, `c.define` content that is a variable (which validates, then fails at publish), an import a `.val` file may not make. With `fix: true` it stages the fixes the rules can make themselves.
30
+ - **`screenshot_page`** shows the assistant a picture of the page in the preview, at desktop, tablet or phone width, on screen or the whole page. The page draws itself, through the canvas bridge in `@valbuild/next` and `@valbuild/tanstack`, so a site needs those packages at this version for it. The picture is drawn from the page's HTML and CSS: images from other sites, videos, canvases and embeds may come out blank.
31
+
32
+ `@valbuild/eslint-plugin` has a new entry, `@valbuild/eslint-plugin/rules`, with the same rules over a project that is not on a disk (`createRules(host)`). The plugin itself behaves as before.
33
+
3
34
  ## 0.150.12
4
35
 
5
36
  ### Patch Changes
@@ -2,7 +2,7 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var getSitemapTree = require('../../dist/getSitemapTree-d934ff9c.cjs.dev.js');
5
+ var getSitemapTree = require('../../dist/getSitemapTree-98642b57.cjs.dev.js');
6
6
  require('../../dist/createForOfIteratorHelper-f2d7ac6d.cjs.dev.js');
7
7
  require('@valbuild/core');
8
8
 
@@ -42,6 +42,7 @@ exports.parseRoutePattern = getSitemapTree.parseRoutePattern;
42
42
  exports.quickPreviewSiteOrigin = getSitemapTree.quickPreviewSiteOrigin;
43
43
  exports.readPageSnapshot = getSitemapTree.readPageSnapshot;
44
44
  exports.restoreScroll = getSitemapTree.restoreScroll;
45
+ exports.screenshotPage = getSitemapTree.screenshotPage;
45
46
  exports.startElementPicking = getSitemapTree.startElementPicking;
46
47
  exports.storeQuickPreview = getSitemapTree.storeQuickPreview;
47
48
  exports.watchPageLocation = getSitemapTree.watchPageLocation;
@@ -2,7 +2,7 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var getSitemapTree = require('../../dist/getSitemapTree-5354ce90.cjs.prod.js');
5
+ var getSitemapTree = require('../../dist/getSitemapTree-97713490.cjs.prod.js');
6
6
  require('../../dist/createForOfIteratorHelper-9ca2078d.cjs.prod.js');
7
7
  require('@valbuild/core');
8
8
 
@@ -42,6 +42,7 @@ exports.parseRoutePattern = getSitemapTree.parseRoutePattern;
42
42
  exports.quickPreviewSiteOrigin = getSitemapTree.quickPreviewSiteOrigin;
43
43
  exports.readPageSnapshot = getSitemapTree.readPageSnapshot;
44
44
  exports.restoreScroll = getSitemapTree.restoreScroll;
45
+ exports.screenshotPage = getSitemapTree.screenshotPage;
45
46
  exports.startElementPicking = getSitemapTree.startElementPicking;
46
47
  exports.storeQuickPreview = getSitemapTree.storeQuickPreview;
47
48
  exports.watchPageLocation = getSitemapTree.watchPageLocation;
@@ -1,3 +1,3 @@
1
- export { D as DEFAULT_CANVAS_SELECTION, e as DEFAULT_CANVAS_SELECTION_SOFT, Q as QUICK_PREVIEW_PARAM, t as QUICK_PREVIEW_SERVICE_WORKER_PATH, x as QUICK_PREVIEW_SERVICE_WORKER_SOURCE, u as QUICK_PREVIEW_STORE_MESSAGE, b as VAL_AI_SESSION_STORAGE_KEY, d as VAL_CANVAS_MESSAGE, c as VAL_CANVAS_PARAM, V as VAL_CONFIG_SESSION_STORAGE_KEY, a as VAL_THEME_SESSION_STORAGE_KEY, j as attachElementPicker, k as createPickerOverlay, h as describeElement, l as elementLabel, q as findBySelector, E as formatRoutePattern, F as getNextAppRouterSourceFolder, J as getPageRouterSitemapTree, H as getPageRouterSourceFolder, K as getPatternFromModuleFilePath, G as getTanStackRouterSourceFolder, B as isDesignTabOrigin, v as isQuickPreviewFiles, I as isTanStackRoutesFolder, g as isValCanvasFrame, i as isValCanvasPageMessage, f as isValCanvasStudioMessage, m as modifierLabel, p as pageLocationOf, C as parseRoutePattern, A as quickPreviewSiteOrigin, o as readPageSnapshot, r as restoreScroll, s as startElementPicking, y as storeQuickPreview, n as watchPageLocation, z as withQuickPreviewParam, w as withValCanvasParam } from '../../dist/getSitemapTree-97b3166f.esm.js';
1
+ export { D as DEFAULT_CANVAS_SELECTION, e as DEFAULT_CANVAS_SELECTION_SOFT, Q as QUICK_PREVIEW_PARAM, u as QUICK_PREVIEW_SERVICE_WORKER_PATH, y as QUICK_PREVIEW_SERVICE_WORKER_SOURCE, v as QUICK_PREVIEW_STORE_MESSAGE, b as VAL_AI_SESSION_STORAGE_KEY, d as VAL_CANVAS_MESSAGE, c as VAL_CANVAS_PARAM, V as VAL_CONFIG_SESSION_STORAGE_KEY, a as VAL_THEME_SESSION_STORAGE_KEY, j as attachElementPicker, k as createPickerOverlay, h as describeElement, l as elementLabel, q as findBySelector, F as formatRoutePattern, G as getNextAppRouterSourceFolder, K as getPageRouterSitemapTree, I as getPageRouterSourceFolder, L as getPatternFromModuleFilePath, H as getTanStackRouterSourceFolder, C as isDesignTabOrigin, x as isQuickPreviewFiles, J as isTanStackRoutesFolder, g as isValCanvasFrame, i as isValCanvasPageMessage, f as isValCanvasStudioMessage, m as modifierLabel, p as pageLocationOf, E as parseRoutePattern, B as quickPreviewSiteOrigin, o as readPageSnapshot, r as restoreScroll, t as screenshotPage, s as startElementPicking, z as storeQuickPreview, n as watchPageLocation, A as withQuickPreviewParam, w as withValCanvasParam } from '../../dist/getSitemapTree-7c848c94.esm.js';
2
2
  import '../../dist/createForOfIteratorHelper-9b80f1a2.esm.js';
3
3
  import '@valbuild/core';
@@ -18,6 +18,7 @@ export * from "../internal/sessionStorage.js";
18
18
  export * from "../internal/valCanvasProtocol.js";
19
19
  export * from "../internal/elementPicker.js";
20
20
  export * from "../internal/pageInspection.js";
21
+ export * from "../internal/pageScreenshot.js";
21
22
  export * from "../internal/quickPreview.js";
22
23
  export * from "../internal/parseRoutePattern.js";
23
24
  export * from "../internal/getNextAppRouterSourceFolder.js";