@mccaskie-labs/workbench-site 0.14.0 → 0.14.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @mccaskie-labs/workbench-site
2
2
 
3
+ ## 0.14.1
4
+
5
+ ### Patch Changes
6
+
7
+ - `siteSettings` takes a project's `workbench/site.json` import as it is, so the generated `src/pages/owner-words.ts` typechecks once the project has a Settings page.
8
+
3
9
  ## 0.14.0
4
10
 
5
11
  ### Minor Changes
@@ -1,5 +1,4 @@
1
1
  import type { Recipe } from "./recipe.ts";
2
- import type { SiteRecord } from "./builder.ts";
3
2
  export { MAX_OWNER_LINE, MAX_OWNER_WORD, ownerWordKey } from "./recipe.ts";
4
3
  interface OwnerWordSetting {
5
4
  key: string;
@@ -19,6 +18,13 @@ interface OwnerWordSetting {
19
18
  taglish: string;
20
19
  };
21
20
  }
21
+ /** What siteSettings reads from workbench/site.json: typed loosely, so a project's JSON import passes as it is. */
22
+ type SitePages = {
23
+ readonly pages: readonly {
24
+ readonly recipe: string;
25
+ readonly state?: string;
26
+ }[];
27
+ };
22
28
  /** The Settings page's section for the owner's words on these pages, as workbench-settings takes it (a ToolSettings). */
23
29
  export interface SiteOwnerSettings {
24
30
  format: 1;
@@ -44,7 +50,7 @@ export declare const SITE_SETTINGS: SiteOwnerSettings;
44
50
  * be on it. With more than one language, each word's help says it is shown
45
51
  * in every language (one owner's word per word for now).
46
52
  */
47
- export declare function siteSettings(site: SiteRecord | readonly string[], catalogue?: readonly Recipe[], languages?: number): SiteOwnerSettings | null;
53
+ export declare function siteSettings(site: SitePages | readonly string[], catalogue?: readonly Recipe[], languages?: number): SiteOwnerSettings | null;
48
54
  /**
49
55
  * The words the pages were built with, as the Settings page's answers
50
56
  * (`createSettings({ answers })`), so each shows "set when the app was built"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mccaskie-labs/workbench-site",
3
- "version": "0.14.0",
3
+ "version": "0.14.1",
4
4
  "description": "A Workbench project's standard pages: page recipes, the builder that turns them into thin page files calling Workbench's tools, and the page frames and sections they are drawn with (wb-site-*, restylable, on the project's theme tokens).",
5
5
  "license": "UNLICENSED",
6
6
  "type": "module",