@cratis/scene.model 4.12.0 → 4.13.0

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 (46) hide show
  1. package/descriptors/PackageDesignTimeMetadata.ts +7 -1
  2. package/dist/cjs/descriptors/PackageDesignTimeMetadata.js +2 -1
  3. package/dist/cjs/descriptors/PackageDesignTimeMetadata.js.map +1 -1
  4. package/dist/cjs/index.js +4 -0
  5. package/dist/cjs/index.js.map +1 -1
  6. package/dist/cjs/screens/Outlet.js +2 -1
  7. package/dist/cjs/screens/Outlet.js.map +1 -1
  8. package/dist/cjs/screens/TemplateAttribution.js +14 -0
  9. package/dist/cjs/screens/TemplateAttribution.js.map +1 -0
  10. package/dist/cjs/screens/TemplateCompatibility.js +11 -0
  11. package/dist/cjs/screens/TemplateCompatibility.js.map +1 -0
  12. package/dist/cjs/screens/TemplateMetadata.js +5 -1
  13. package/dist/cjs/screens/TemplateMetadata.js.map +1 -1
  14. package/dist/esm/descriptors/PackageDesignTimeMetadata.d.ts +1 -0
  15. package/dist/esm/descriptors/PackageDesignTimeMetadata.d.ts.map +1 -1
  16. package/dist/esm/descriptors/PackageDesignTimeMetadata.js +2 -1
  17. package/dist/esm/descriptors/PackageDesignTimeMetadata.js.map +1 -1
  18. package/dist/esm/index.js +2 -0
  19. package/dist/esm/index.js.map +1 -1
  20. package/dist/esm/screens/Outlet.d.ts +1 -0
  21. package/dist/esm/screens/Outlet.d.ts.map +1 -1
  22. package/dist/esm/screens/Outlet.js +2 -1
  23. package/dist/esm/screens/Outlet.js.map +1 -1
  24. package/dist/esm/screens/TemplateAttribution.d.ts +7 -0
  25. package/dist/esm/screens/TemplateAttribution.d.ts.map +1 -0
  26. package/dist/esm/screens/TemplateAttribution.js +12 -0
  27. package/dist/esm/screens/TemplateAttribution.js.map +1 -0
  28. package/dist/esm/screens/TemplateCompatibility.d.ts +7 -0
  29. package/dist/esm/screens/TemplateCompatibility.d.ts.map +1 -0
  30. package/dist/esm/screens/TemplateCompatibility.js +9 -0
  31. package/dist/esm/screens/TemplateCompatibility.js.map +1 -0
  32. package/dist/esm/screens/TemplateMetadata.d.ts +6 -0
  33. package/dist/esm/screens/TemplateMetadata.d.ts.map +1 -1
  34. package/dist/esm/screens/TemplateMetadata.js +5 -1
  35. package/dist/esm/screens/TemplateMetadata.js.map +1 -1
  36. package/dist/esm/screens/index.d.ts +2 -0
  37. package/dist/esm/screens/index.d.ts.map +1 -1
  38. package/dist/esm/screens/index.js +2 -0
  39. package/dist/esm/screens/index.js.map +1 -1
  40. package/dist/esm/tsconfig.tsbuildinfo +1 -1
  41. package/package.json +1 -1
  42. package/screens/Outlet.ts +8 -1
  43. package/screens/TemplateAttribution.ts +18 -0
  44. package/screens/TemplateCompatibility.ts +21 -0
  45. package/screens/TemplateMetadata.ts +14 -1
  46. package/screens/index.ts +2 -0
@@ -19,8 +19,14 @@ export interface PackageDesignTimeMetadata {
19
19
 
20
20
  /** Named design-time action handlers available in the package's design-time bundle. */
21
21
  actions: string[];
22
+
23
+ /**
24
+ * The design-time extension contract version (`major.minor`) the bundle was written against. Hosts load
25
+ * contributions only when the major version matches the one they implement; absent means `1.0`.
26
+ */
27
+ contractVersion?: string;
22
28
  }
23
29
 
24
30
  export const PackageDesignTimeMetadataPropertyNames: (keyof PackageDesignTimeMetadata)[] = [
25
- 'previews', 'designers', 'propertyEditors', 'propertyDisplays', 'actions',
31
+ 'previews', 'designers', 'propertyEditors', 'propertyDisplays', 'actions', 'contractVersion',
26
32
  ];
@@ -9,7 +9,8 @@
9
9
  'designers',
10
10
  'propertyEditors',
11
11
  'propertyDisplays',
12
- 'actions'
12
+ 'actions',
13
+ 'contractVersion'
13
14
  ];
14
15
 
15
16
  exports.PackageDesignTimeMetadataPropertyNames = PackageDesignTimeMetadataPropertyNames;
@@ -1 +1 @@
1
- {"version":3,"file":"PackageDesignTimeMetadata.js","sources":["../../../descriptors/PackageDesignTimeMetadata.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n/**\n * Platform-neutral names of optional design-time extension points a package provides.\n */\nexport interface PackageDesignTimeMetadata {\n /** Named component preview renderers available in the package's design-time bundle. */\n previews: string[];\n\n /** Named full-component designers available in the package's design-time bundle. */\n designers: string[];\n\n /** Named property editors available in the package's design-time bundle. */\n propertyEditors: string[];\n\n /** Named property display renderers available in the package's design-time bundle. */\n propertyDisplays: string[];\n\n /** Named design-time action handlers available in the package's design-time bundle. */\n actions: string[];\n}\n\nexport const PackageDesignTimeMetadataPropertyNames: (keyof PackageDesignTimeMetadata)[] = [\n 'previews', 'designers', 'propertyEditors', 'propertyDisplays', 'actions',\n];\n"],"names":["PackageDesignTimeMetadataPropertyNames"],"mappings":";;AAAA;AACA;AAEA;;UAoBaA,sCAAAA,GAA8E;AACvF,IAAA,UAAA;AAAY,IAAA,WAAA;AAAa,IAAA,iBAAA;AAAmB,IAAA,kBAAA;AAAoB,IAAA;;;"}
1
+ {"version":3,"file":"PackageDesignTimeMetadata.js","sources":["../../../descriptors/PackageDesignTimeMetadata.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n/**\n * Platform-neutral names of optional design-time extension points a package provides.\n */\nexport interface PackageDesignTimeMetadata {\n /** Named component preview renderers available in the package's design-time bundle. */\n previews: string[];\n\n /** Named full-component designers available in the package's design-time bundle. */\n designers: string[];\n\n /** Named property editors available in the package's design-time bundle. */\n propertyEditors: string[];\n\n /** Named property display renderers available in the package's design-time bundle. */\n propertyDisplays: string[];\n\n /** Named design-time action handlers available in the package's design-time bundle. */\n actions: string[];\n\n /**\n * The design-time extension contract version (`major.minor`) the bundle was written against. Hosts load\n * contributions only when the major version matches the one they implement; absent means `1.0`.\n */\n contractVersion?: string;\n}\n\nexport const PackageDesignTimeMetadataPropertyNames: (keyof PackageDesignTimeMetadata)[] = [\n 'previews', 'designers', 'propertyEditors', 'propertyDisplays', 'actions', 'contractVersion',\n];\n"],"names":["PackageDesignTimeMetadataPropertyNames"],"mappings":";;AAAA;AACA;AAEA;;UA0BaA,sCAAAA,GAA8E;AACvF,IAAA,UAAA;AAAY,IAAA,WAAA;AAAa,IAAA,iBAAA;AAAmB,IAAA,kBAAA;AAAoB,IAAA,SAAA;AAAW,IAAA;;;"}
package/dist/cjs/index.js CHANGED
@@ -101,6 +101,8 @@ var Outlet = require('./screens/Outlet.js');
101
101
  var Screen = require('./screens/Screen.js');
102
102
  var ScreenTemplate = require('./screens/ScreenTemplate.js');
103
103
  var DialogTemplate = require('./screens/DialogTemplate.js');
104
+ var TemplateAttribution = require('./screens/TemplateAttribution.js');
105
+ var TemplateCompatibility = require('./screens/TemplateCompatibility.js');
104
106
  var TemplateMetadata = require('./screens/TemplateMetadata.js');
105
107
  var UiStarter = require('./starters/UiStarter.js');
106
108
  var QueryResultShape = require('./queries/QueryResultShape.js');
@@ -270,6 +272,8 @@ exports.OutletPropertyNames = Outlet.OutletPropertyNames;
270
272
  exports.ScreenPropertyNames = Screen.ScreenPropertyNames;
271
273
  exports.ScreenTemplatePropertyNames = ScreenTemplate.ScreenTemplatePropertyNames;
272
274
  exports.DialogTemplatePropertyNames = DialogTemplate.DialogTemplatePropertyNames;
275
+ exports.TemplateAttributionPropertyNames = TemplateAttribution.TemplateAttributionPropertyNames;
276
+ exports.TemplateCompatibilityPropertyNames = TemplateCompatibility.TemplateCompatibilityPropertyNames;
273
277
  exports.TemplateMetadataPropertyNames = TemplateMetadata.TemplateMetadataPropertyNames;
274
278
  exports.TemplateScope = TemplateMetadata.TemplateScope;
275
279
  exports.UiStarterPropertyNames = UiStarter.UiStarterPropertyNames;
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -6,7 +6,8 @@
6
6
  * A named replacement surface for routed or nested screen content.
7
7
  */ const OutletPropertyNames = [
8
8
  'name',
9
- 'description'
9
+ 'description',
10
+ 'accepts'
10
11
  ];
11
12
 
12
13
  exports.OutletPropertyNames = OutletPropertyNames;
@@ -1 +1 @@
1
- {"version":3,"file":"Outlet.js","sources":["../../../screens/Outlet.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n/**\n * A named replacement surface for routed or nested screen content.\n */\nexport interface Outlet {\n /** Stable outlet name used by destinations. */\n name: string;\n\n /** Optional description for designers. */\n description?: string;\n}\n\nexport const OutletPropertyNames: (keyof Outlet)[] = ['name', 'description'];\n"],"names":["OutletPropertyNames"],"mappings":";;AAAA;AACA;AAEA;;UAWaA,mBAAAA,GAAwC;AAAC,IAAA,MAAA;AAAQ,IAAA;;;"}
1
+ {"version":3,"file":"Outlet.js","sources":["../../../screens/Outlet.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n/**\n * A named replacement surface for routed or nested screen content.\n */\nexport interface Outlet {\n /** Stable outlet name used by destinations. */\n name: string;\n\n /** Optional description for designers. */\n description?: string;\n\n /**\n * The semantic template types (`TemplateMetadata.type`) a screen must have to be placed in this outlet,\n * such as `Detail` or `Form`. Absent accepts any screen. A destination that places a screen of another\n * type here is diagnosed as an incompatible outlet rather than rendered somewhere it was not designed for.\n */\n accepts?: string[];\n}\n\nexport const OutletPropertyNames: (keyof Outlet)[] = ['name', 'description', 'accepts'];\n"],"names":["OutletPropertyNames"],"mappings":";;AAAA;AACA;AAEA;;UAkBaA,mBAAAA,GAAwC;AAAC,IAAA,MAAA;AAAQ,IAAA,aAAA;AAAe,IAAA;;;"}
@@ -0,0 +1,14 @@
1
+ 'use strict';
2
+
3
+ // Copyright (c) Cratis. All rights reserved.
4
+ // Licensed under the MIT license. See LICENSE file in the project root for full license information.
5
+ /**
6
+ * Who authored a template and what must accompany it when it is reused.
7
+ */ const TemplateAttributionPropertyNames = [
8
+ 'author',
9
+ 'url',
10
+ 'notice'
11
+ ];
12
+
13
+ exports.TemplateAttributionPropertyNames = TemplateAttributionPropertyNames;
14
+ //# sourceMappingURL=TemplateAttribution.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TemplateAttribution.js","sources":["../../../screens/TemplateAttribution.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n/**\n * Who authored a template and what must accompany it when it is reused.\n */\nexport interface TemplateAttribution {\n /** The person or organization that authored the template. */\n author: string;\n\n /** An absolute `https` URL where the template's source or documentation lives. */\n url?: string;\n\n /** An attribution notice a license requires to travel with the template, shown by a template browser. */\n notice?: string;\n}\n\nexport const TemplateAttributionPropertyNames: (keyof TemplateAttribution)[] = ['author', 'url', 'notice'];\n"],"names":["TemplateAttributionPropertyNames"],"mappings":";;AAAA;AACA;AAEA;;UAcaA,gCAAAA,GAAkE;AAAC,IAAA,QAAA;AAAU,IAAA,KAAA;AAAO,IAAA;;;"}
@@ -0,0 +1,11 @@
1
+ 'use strict';
2
+
3
+ // Copyright (c) Cratis. All rights reserved.
4
+ // Licensed under the MIT license. See LICENSE file in the project root for full license information.
5
+ const TemplateCompatibilityPropertyNames = [
6
+ 'scene',
7
+ 'packages'
8
+ ];
9
+
10
+ exports.TemplateCompatibilityPropertyNames = TemplateCompatibilityPropertyNames;
11
+ //# sourceMappingURL=TemplateCompatibility.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TemplateCompatibility.js","sources":["../../../screens/TemplateCompatibility.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { PackageDependency } from '../packages/PackageDependency';\n\n/**\n * Which Scene and package versions a template was authored and verified against.\n *\n * A template names components, slots and bindings that only exist in particular versions of Scene and of\n * the packages that provide them. Declaring the ranges lets a catalog mark a template as incompatible with\n * the active package set before an author picks it, instead of rendering placeholders after they have.\n */\nexport interface TemplateCompatibility {\n /** The Scene model version range the template requires, such as `^4.13.0`. */\n scene: string;\n\n /** The packages, and their version ranges, whose components or layouts the template uses. */\n packages?: PackageDependency[];\n}\n\nexport const TemplateCompatibilityPropertyNames: (keyof TemplateCompatibility)[] = ['scene', 'packages'];\n"],"names":["TemplateCompatibilityPropertyNames"],"mappings":";;AAAA;AACA;MAmBaA,kCAAAA,GAAsE;AAAC,IAAA,OAAA;AAAS,IAAA;;;"}
@@ -13,7 +13,11 @@
13
13
  const TemplateMetadataPropertyNames = [
14
14
  'type',
15
15
  'category',
16
- 'scopes'
16
+ 'scopes',
17
+ 'compatibility',
18
+ 'attribution',
19
+ 'license',
20
+ 'licenseUrl'
17
21
  ];
18
22
 
19
23
  exports.TemplateMetadataPropertyNames = TemplateMetadataPropertyNames;
@@ -1 +1 @@
1
- {"version":3,"file":"TemplateMetadata.js","sources":["../../../screens/TemplateMetadata.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n/** The application hierarchy at which a reusable template is selected. */\nexport enum TemplateScope {\n Application = 'Application',\n Module = 'Module',\n Feature = 'Feature',\n Subfeature = 'Subfeature',\n Slice = 'Slice',\n}\n\n/**\n * Optional semantic and browsing metadata. Type and category are open strings so packages can\n * introduce their own vocabulary without a Scene release. Category never determines applicability.\n */\nexport interface TemplateMetadata {\n /** Semantic role; built-in roles are ApplicationShell, Workspace, List, Detail, Form and Dialog. */\n type?: string;\n /** A package-defined browse category, preserved even when the host does not recognize it. */\n category?: string;\n /** Explicit scope restriction. Absent uses the structural role; an empty list allows no scope. */\n scopes?: TemplateScope[];\n}\n\nexport const TemplateMetadataPropertyNames: (keyof TemplateMetadata)[] = ['type', 'category', 'scopes'];\n"],"names":["TemplateScope","TemplateMetadataPropertyNames"],"mappings":";;AAAA;AACA;AAEA,2EACO,IAAKA,aAAAA,iBAAAA,SAAAA,aAAAA,EAAAA;;;;;;AAAAA,IAAAA,OAAAA,aAAAA;AAMX,CAAA,CAAA,EAAA;MAeYC,6BAAAA,GAA4D;AAAC,IAAA,MAAA;AAAQ,IAAA,UAAA;AAAY,IAAA;;;;"}
1
+ {"version":3,"file":"TemplateMetadata.js","sources":["../../../screens/TemplateMetadata.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { TemplateAttribution } from './TemplateAttribution';\nimport { TemplateCompatibility } from './TemplateCompatibility';\n\n/** The application hierarchy at which a reusable template is selected. */\nexport enum TemplateScope {\n Application = 'Application',\n Module = 'Module',\n Feature = 'Feature',\n Subfeature = 'Subfeature',\n Slice = 'Slice',\n}\n\n/**\n * Optional semantic and browsing metadata. Type and category are open strings so packages can\n * introduce their own vocabulary without a Scene release. Category never determines applicability.\n */\nexport interface TemplateMetadata {\n /** Semantic role; built-in roles are ApplicationShell, Workspace, List, Detail, Form and Dialog. */\n type?: string;\n /** A package-defined browse category, preserved even when the host does not recognize it. */\n category?: string;\n /** Explicit scope restriction. Absent uses the structural role; an empty list allows no scope. */\n scopes?: TemplateScope[];\n /** The Scene and package versions the template requires. Required for every shipped template. */\n compatibility?: TemplateCompatibility;\n /** Who authored the template. Required for every shipped template. */\n attribution?: TemplateAttribution;\n /** The SPDX license identifier the template is available under, such as `MIT`. Required for every shipped template. */\n license?: string;\n /** An absolute `https` URL to the license terms. */\n licenseUrl?: string;\n}\n\nexport const TemplateMetadataPropertyNames: (keyof TemplateMetadata)[] = [\n 'type', 'category', 'scopes', 'compatibility', 'attribution', 'license', 'licenseUrl',\n];\n"],"names":["TemplateScope","TemplateMetadataPropertyNames"],"mappings":";;AAAA;AACA;AAKA,2EACO,IAAKA,aAAAA,iBAAAA,SAAAA,aAAAA,EAAAA;;;;;;AAAAA,IAAAA,OAAAA,aAAAA;AAMX,CAAA,CAAA,EAAA;MAuBYC,6BAAAA,GAA4D;AACrE,IAAA,MAAA;AAAQ,IAAA,UAAA;AAAY,IAAA,QAAA;AAAU,IAAA,eAAA;AAAiB,IAAA,aAAA;AAAe,IAAA,SAAA;AAAW,IAAA;;;;"}
@@ -4,6 +4,7 @@ export interface PackageDesignTimeMetadata {
4
4
  propertyEditors: string[];
5
5
  propertyDisplays: string[];
6
6
  actions: string[];
7
+ contractVersion?: string;
7
8
  }
8
9
  export declare const PackageDesignTimeMetadataPropertyNames: (keyof PackageDesignTimeMetadata)[];
9
10
  //# sourceMappingURL=PackageDesignTimeMetadata.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"PackageDesignTimeMetadata.d.ts","sourceRoot":"","sources":["../../../descriptors/PackageDesignTimeMetadata.ts"],"names":[],"mappings":"AAMA,MAAM,WAAW,yBAAyB;IAEtC,QAAQ,EAAE,MAAM,EAAE,CAAC;IAGnB,SAAS,EAAE,MAAM,EAAE,CAAC;IAGpB,eAAe,EAAE,MAAM,EAAE,CAAC;IAG1B,gBAAgB,EAAE,MAAM,EAAE,CAAC;IAG3B,OAAO,EAAE,MAAM,EAAE,CAAC;CACrB;AAED,eAAO,MAAM,sCAAsC,EAAE,CAAC,MAAM,yBAAyB,CAAC,EAErF,CAAC"}
1
+ {"version":3,"file":"PackageDesignTimeMetadata.d.ts","sourceRoot":"","sources":["../../../descriptors/PackageDesignTimeMetadata.ts"],"names":[],"mappings":"AAMA,MAAM,WAAW,yBAAyB;IAEtC,QAAQ,EAAE,MAAM,EAAE,CAAC;IAGnB,SAAS,EAAE,MAAM,EAAE,CAAC;IAGpB,eAAe,EAAE,MAAM,EAAE,CAAC;IAG1B,gBAAgB,EAAE,MAAM,EAAE,CAAC;IAG3B,OAAO,EAAE,MAAM,EAAE,CAAC;IAMlB,eAAe,CAAC,EAAE,MAAM,CAAC;CAC5B;AAED,eAAO,MAAM,sCAAsC,EAAE,CAAC,MAAM,yBAAyB,CAAC,EAErF,CAAC"}
@@ -7,7 +7,8 @@
7
7
  'designers',
8
8
  'propertyEditors',
9
9
  'propertyDisplays',
10
- 'actions'
10
+ 'actions',
11
+ 'contractVersion'
11
12
  ];
12
13
 
13
14
  export { PackageDesignTimeMetadataPropertyNames };
@@ -1 +1 @@
1
- {"version":3,"file":"PackageDesignTimeMetadata.js","sources":["../../../descriptors/PackageDesignTimeMetadata.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n/**\n * Platform-neutral names of optional design-time extension points a package provides.\n */\nexport interface PackageDesignTimeMetadata {\n /** Named component preview renderers available in the package's design-time bundle. */\n previews: string[];\n\n /** Named full-component designers available in the package's design-time bundle. */\n designers: string[];\n\n /** Named property editors available in the package's design-time bundle. */\n propertyEditors: string[];\n\n /** Named property display renderers available in the package's design-time bundle. */\n propertyDisplays: string[];\n\n /** Named design-time action handlers available in the package's design-time bundle. */\n actions: string[];\n}\n\nexport const PackageDesignTimeMetadataPropertyNames: (keyof PackageDesignTimeMetadata)[] = [\n 'previews', 'designers', 'propertyEditors', 'propertyDisplays', 'actions',\n];\n"],"names":["PackageDesignTimeMetadataPropertyNames"],"mappings":"AAAA;AACA;AAEA;;UAoBaA,sCAAAA,GAA8E;AACvF,IAAA,UAAA;AAAY,IAAA,WAAA;AAAa,IAAA,iBAAA;AAAmB,IAAA,kBAAA;AAAoB,IAAA;;;"}
1
+ {"version":3,"file":"PackageDesignTimeMetadata.js","sources":["../../../descriptors/PackageDesignTimeMetadata.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n/**\n * Platform-neutral names of optional design-time extension points a package provides.\n */\nexport interface PackageDesignTimeMetadata {\n /** Named component preview renderers available in the package's design-time bundle. */\n previews: string[];\n\n /** Named full-component designers available in the package's design-time bundle. */\n designers: string[];\n\n /** Named property editors available in the package's design-time bundle. */\n propertyEditors: string[];\n\n /** Named property display renderers available in the package's design-time bundle. */\n propertyDisplays: string[];\n\n /** Named design-time action handlers available in the package's design-time bundle. */\n actions: string[];\n\n /**\n * The design-time extension contract version (`major.minor`) the bundle was written against. Hosts load\n * contributions only when the major version matches the one they implement; absent means `1.0`.\n */\n contractVersion?: string;\n}\n\nexport const PackageDesignTimeMetadataPropertyNames: (keyof PackageDesignTimeMetadata)[] = [\n 'previews', 'designers', 'propertyEditors', 'propertyDisplays', 'actions', 'contractVersion',\n];\n"],"names":["PackageDesignTimeMetadataPropertyNames"],"mappings":"AAAA;AACA;AAEA;;UA0BaA,sCAAAA,GAA8E;AACvF,IAAA,UAAA;AAAY,IAAA,WAAA;AAAa,IAAA,iBAAA;AAAmB,IAAA,kBAAA;AAAoB,IAAA,SAAA;AAAW,IAAA;;;"}
package/dist/esm/index.js CHANGED
@@ -99,6 +99,8 @@ export { OutletPropertyNames } from './screens/Outlet.js';
99
99
  export { ScreenPropertyNames } from './screens/Screen.js';
100
100
  export { ScreenTemplatePropertyNames } from './screens/ScreenTemplate.js';
101
101
  export { DialogTemplatePropertyNames } from './screens/DialogTemplate.js';
102
+ export { TemplateAttributionPropertyNames } from './screens/TemplateAttribution.js';
103
+ export { TemplateCompatibilityPropertyNames } from './screens/TemplateCompatibility.js';
102
104
  export { TemplateMetadataPropertyNames, TemplateScope } from './screens/TemplateMetadata.js';
103
105
  export { UiStarterPropertyNames } from './starters/UiStarter.js';
104
106
  export { QueryResultShape } from './queries/QueryResultShape.js';
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,6 +1,7 @@
1
1
  export interface Outlet {
2
2
  name: string;
3
3
  description?: string;
4
+ accepts?: string[];
4
5
  }
5
6
  export declare const OutletPropertyNames: (keyof Outlet)[];
6
7
  //# sourceMappingURL=Outlet.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Outlet.d.ts","sourceRoot":"","sources":["../../../screens/Outlet.ts"],"names":[],"mappings":"AAMA,MAAM,WAAW,MAAM;IAEnB,IAAI,EAAE,MAAM,CAAC;IAGb,WAAW,CAAC,EAAE,MAAM,CAAC;CACxB;AAED,eAAO,MAAM,mBAAmB,EAAE,CAAC,MAAM,MAAM,CAAC,EAA4B,CAAC"}
1
+ {"version":3,"file":"Outlet.d.ts","sourceRoot":"","sources":["../../../screens/Outlet.ts"],"names":[],"mappings":"AAMA,MAAM,WAAW,MAAM;IAEnB,IAAI,EAAE,MAAM,CAAC;IAGb,WAAW,CAAC,EAAE,MAAM,CAAC;IAOrB,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;CACtB;AAED,eAAO,MAAM,mBAAmB,EAAE,CAAC,MAAM,MAAM,CAAC,EAAuC,CAAC"}
@@ -4,7 +4,8 @@
4
4
  * A named replacement surface for routed or nested screen content.
5
5
  */ const OutletPropertyNames = [
6
6
  'name',
7
- 'description'
7
+ 'description',
8
+ 'accepts'
8
9
  ];
9
10
 
10
11
  export { OutletPropertyNames };
@@ -1 +1 @@
1
- {"version":3,"file":"Outlet.js","sources":["../../../screens/Outlet.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n/**\n * A named replacement surface for routed or nested screen content.\n */\nexport interface Outlet {\n /** Stable outlet name used by destinations. */\n name: string;\n\n /** Optional description for designers. */\n description?: string;\n}\n\nexport const OutletPropertyNames: (keyof Outlet)[] = ['name', 'description'];\n"],"names":["OutletPropertyNames"],"mappings":"AAAA;AACA;AAEA;;UAWaA,mBAAAA,GAAwC;AAAC,IAAA,MAAA;AAAQ,IAAA;;;"}
1
+ {"version":3,"file":"Outlet.js","sources":["../../../screens/Outlet.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n/**\n * A named replacement surface for routed or nested screen content.\n */\nexport interface Outlet {\n /** Stable outlet name used by destinations. */\n name: string;\n\n /** Optional description for designers. */\n description?: string;\n\n /**\n * The semantic template types (`TemplateMetadata.type`) a screen must have to be placed in this outlet,\n * such as `Detail` or `Form`. Absent accepts any screen. A destination that places a screen of another\n * type here is diagnosed as an incompatible outlet rather than rendered somewhere it was not designed for.\n */\n accepts?: string[];\n}\n\nexport const OutletPropertyNames: (keyof Outlet)[] = ['name', 'description', 'accepts'];\n"],"names":["OutletPropertyNames"],"mappings":"AAAA;AACA;AAEA;;UAkBaA,mBAAAA,GAAwC;AAAC,IAAA,MAAA;AAAQ,IAAA,aAAA;AAAe,IAAA;;;"}
@@ -0,0 +1,7 @@
1
+ export interface TemplateAttribution {
2
+ author: string;
3
+ url?: string;
4
+ notice?: string;
5
+ }
6
+ export declare const TemplateAttributionPropertyNames: (keyof TemplateAttribution)[];
7
+ //# sourceMappingURL=TemplateAttribution.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TemplateAttribution.d.ts","sourceRoot":"","sources":["../../../screens/TemplateAttribution.ts"],"names":[],"mappings":"AAMA,MAAM,WAAW,mBAAmB;IAEhC,MAAM,EAAE,MAAM,CAAC;IAGf,GAAG,CAAC,EAAE,MAAM,CAAC;IAGb,MAAM,CAAC,EAAE,MAAM,CAAC;CACnB;AAED,eAAO,MAAM,gCAAgC,EAAE,CAAC,MAAM,mBAAmB,CAAC,EAAgC,CAAC"}
@@ -0,0 +1,12 @@
1
+ // Copyright (c) Cratis. All rights reserved.
2
+ // Licensed under the MIT license. See LICENSE file in the project root for full license information.
3
+ /**
4
+ * Who authored a template and what must accompany it when it is reused.
5
+ */ const TemplateAttributionPropertyNames = [
6
+ 'author',
7
+ 'url',
8
+ 'notice'
9
+ ];
10
+
11
+ export { TemplateAttributionPropertyNames };
12
+ //# sourceMappingURL=TemplateAttribution.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TemplateAttribution.js","sources":["../../../screens/TemplateAttribution.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n/**\n * Who authored a template and what must accompany it when it is reused.\n */\nexport interface TemplateAttribution {\n /** The person or organization that authored the template. */\n author: string;\n\n /** An absolute `https` URL where the template's source or documentation lives. */\n url?: string;\n\n /** An attribution notice a license requires to travel with the template, shown by a template browser. */\n notice?: string;\n}\n\nexport const TemplateAttributionPropertyNames: (keyof TemplateAttribution)[] = ['author', 'url', 'notice'];\n"],"names":["TemplateAttributionPropertyNames"],"mappings":"AAAA;AACA;AAEA;;UAcaA,gCAAAA,GAAkE;AAAC,IAAA,QAAA;AAAU,IAAA,KAAA;AAAO,IAAA;;;"}
@@ -0,0 +1,7 @@
1
+ import { PackageDependency } from '../packages/PackageDependency';
2
+ export interface TemplateCompatibility {
3
+ scene: string;
4
+ packages?: PackageDependency[];
5
+ }
6
+ export declare const TemplateCompatibilityPropertyNames: (keyof TemplateCompatibility)[];
7
+ //# sourceMappingURL=TemplateCompatibility.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TemplateCompatibility.d.ts","sourceRoot":"","sources":["../../../screens/TemplateCompatibility.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,iBAAiB,EAAE,MAAM,+BAA+B,CAAC;AASlE,MAAM,WAAW,qBAAqB;IAElC,KAAK,EAAE,MAAM,CAAC;IAGd,QAAQ,CAAC,EAAE,iBAAiB,EAAE,CAAC;CAClC;AAED,eAAO,MAAM,kCAAkC,EAAE,CAAC,MAAM,qBAAqB,CAAC,EAA0B,CAAC"}
@@ -0,0 +1,9 @@
1
+ // Copyright (c) Cratis. All rights reserved.
2
+ // Licensed under the MIT license. See LICENSE file in the project root for full license information.
3
+ const TemplateCompatibilityPropertyNames = [
4
+ 'scene',
5
+ 'packages'
6
+ ];
7
+
8
+ export { TemplateCompatibilityPropertyNames };
9
+ //# sourceMappingURL=TemplateCompatibility.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TemplateCompatibility.js","sources":["../../../screens/TemplateCompatibility.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { PackageDependency } from '../packages/PackageDependency';\n\n/**\n * Which Scene and package versions a template was authored and verified against.\n *\n * A template names components, slots and bindings that only exist in particular versions of Scene and of\n * the packages that provide them. Declaring the ranges lets a catalog mark a template as incompatible with\n * the active package set before an author picks it, instead of rendering placeholders after they have.\n */\nexport interface TemplateCompatibility {\n /** The Scene model version range the template requires, such as `^4.13.0`. */\n scene: string;\n\n /** The packages, and their version ranges, whose components or layouts the template uses. */\n packages?: PackageDependency[];\n}\n\nexport const TemplateCompatibilityPropertyNames: (keyof TemplateCompatibility)[] = ['scene', 'packages'];\n"],"names":["TemplateCompatibilityPropertyNames"],"mappings":"AAAA;AACA;MAmBaA,kCAAAA,GAAsE;AAAC,IAAA,OAAA;AAAS,IAAA;;;"}
@@ -1,3 +1,5 @@
1
+ import { TemplateAttribution } from './TemplateAttribution';
2
+ import { TemplateCompatibility } from './TemplateCompatibility';
1
3
  export declare enum TemplateScope {
2
4
  Application = "Application",
3
5
  Module = "Module",
@@ -9,6 +11,10 @@ export interface TemplateMetadata {
9
11
  type?: string;
10
12
  category?: string;
11
13
  scopes?: TemplateScope[];
14
+ compatibility?: TemplateCompatibility;
15
+ attribution?: TemplateAttribution;
16
+ license?: string;
17
+ licenseUrl?: string;
12
18
  }
13
19
  export declare const TemplateMetadataPropertyNames: (keyof TemplateMetadata)[];
14
20
  //# sourceMappingURL=TemplateMetadata.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"TemplateMetadata.d.ts","sourceRoot":"","sources":["../../../screens/TemplateMetadata.ts"],"names":[],"mappings":"AAIA,oBAAY,aAAa;IACrB,WAAW,gBAAgB;IAC3B,MAAM,WAAW;IACjB,OAAO,YAAY;IACnB,UAAU,eAAe;IACzB,KAAK,UAAU;CAClB;AAMD,MAAM,WAAW,gBAAgB;IAE7B,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB,MAAM,CAAC,EAAE,aAAa,EAAE,CAAC;CAC5B;AAED,eAAO,MAAM,6BAA6B,EAAE,CAAC,MAAM,gBAAgB,CAAC,EAAmC,CAAC"}
1
+ {"version":3,"file":"TemplateMetadata.d.ts","sourceRoot":"","sources":["../../../screens/TemplateMetadata.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC5D,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAGhE,oBAAY,aAAa;IACrB,WAAW,gBAAgB;IAC3B,MAAM,WAAW;IACjB,OAAO,YAAY;IACnB,UAAU,eAAe;IACzB,KAAK,UAAU;CAClB;AAMD,MAAM,WAAW,gBAAgB;IAE7B,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB,MAAM,CAAC,EAAE,aAAa,EAAE,CAAC;IAEzB,aAAa,CAAC,EAAE,qBAAqB,CAAC;IAEtC,WAAW,CAAC,EAAE,mBAAmB,CAAC;IAElC,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB,UAAU,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,eAAO,MAAM,6BAA6B,EAAE,CAAC,MAAM,gBAAgB,CAAC,EAEnE,CAAC"}
@@ -11,7 +11,11 @@
11
11
  const TemplateMetadataPropertyNames = [
12
12
  'type',
13
13
  'category',
14
- 'scopes'
14
+ 'scopes',
15
+ 'compatibility',
16
+ 'attribution',
17
+ 'license',
18
+ 'licenseUrl'
15
19
  ];
16
20
 
17
21
  export { TemplateMetadataPropertyNames, TemplateScope };
@@ -1 +1 @@
1
- {"version":3,"file":"TemplateMetadata.js","sources":["../../../screens/TemplateMetadata.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n/** The application hierarchy at which a reusable template is selected. */\nexport enum TemplateScope {\n Application = 'Application',\n Module = 'Module',\n Feature = 'Feature',\n Subfeature = 'Subfeature',\n Slice = 'Slice',\n}\n\n/**\n * Optional semantic and browsing metadata. Type and category are open strings so packages can\n * introduce their own vocabulary without a Scene release. Category never determines applicability.\n */\nexport interface TemplateMetadata {\n /** Semantic role; built-in roles are ApplicationShell, Workspace, List, Detail, Form and Dialog. */\n type?: string;\n /** A package-defined browse category, preserved even when the host does not recognize it. */\n category?: string;\n /** Explicit scope restriction. Absent uses the structural role; an empty list allows no scope. */\n scopes?: TemplateScope[];\n}\n\nexport const TemplateMetadataPropertyNames: (keyof TemplateMetadata)[] = ['type', 'category', 'scopes'];\n"],"names":["TemplateScope","TemplateMetadataPropertyNames"],"mappings":"AAAA;AACA;AAEA,2EACO,IAAKA,aAAAA,iBAAAA,SAAAA,aAAAA,EAAAA;;;;;;AAAAA,IAAAA,OAAAA,aAAAA;AAMX,CAAA,CAAA,EAAA;MAeYC,6BAAAA,GAA4D;AAAC,IAAA,MAAA;AAAQ,IAAA,UAAA;AAAY,IAAA;;;"}
1
+ {"version":3,"file":"TemplateMetadata.js","sources":["../../../screens/TemplateMetadata.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { TemplateAttribution } from './TemplateAttribution';\nimport { TemplateCompatibility } from './TemplateCompatibility';\n\n/** The application hierarchy at which a reusable template is selected. */\nexport enum TemplateScope {\n Application = 'Application',\n Module = 'Module',\n Feature = 'Feature',\n Subfeature = 'Subfeature',\n Slice = 'Slice',\n}\n\n/**\n * Optional semantic and browsing metadata. Type and category are open strings so packages can\n * introduce their own vocabulary without a Scene release. Category never determines applicability.\n */\nexport interface TemplateMetadata {\n /** Semantic role; built-in roles are ApplicationShell, Workspace, List, Detail, Form and Dialog. */\n type?: string;\n /** A package-defined browse category, preserved even when the host does not recognize it. */\n category?: string;\n /** Explicit scope restriction. Absent uses the structural role; an empty list allows no scope. */\n scopes?: TemplateScope[];\n /** The Scene and package versions the template requires. Required for every shipped template. */\n compatibility?: TemplateCompatibility;\n /** Who authored the template. Required for every shipped template. */\n attribution?: TemplateAttribution;\n /** The SPDX license identifier the template is available under, such as `MIT`. Required for every shipped template. */\n license?: string;\n /** An absolute `https` URL to the license terms. */\n licenseUrl?: string;\n}\n\nexport const TemplateMetadataPropertyNames: (keyof TemplateMetadata)[] = [\n 'type', 'category', 'scopes', 'compatibility', 'attribution', 'license', 'licenseUrl',\n];\n"],"names":["TemplateScope","TemplateMetadataPropertyNames"],"mappings":"AAAA;AACA;AAKA,2EACO,IAAKA,aAAAA,iBAAAA,SAAAA,aAAAA,EAAAA;;;;;;AAAAA,IAAAA,OAAAA,aAAAA;AAMX,CAAA,CAAA,EAAA;MAuBYC,6BAAAA,GAA4D;AACrE,IAAA,MAAA;AAAQ,IAAA,UAAA;AAAY,IAAA,QAAA;AAAU,IAAA,eAAA;AAAiB,IAAA,aAAA;AAAe,IAAA,SAAA;AAAW,IAAA;;;"}
@@ -2,5 +2,7 @@ export * from './Outlet';
2
2
  export * from './Screen';
3
3
  export * from './ScreenTemplate';
4
4
  export * from './DialogTemplate';
5
+ export * from './TemplateAttribution';
6
+ export * from './TemplateCompatibility';
5
7
  export * from './TemplateMetadata';
6
8
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../screens/index.ts"],"names":[],"mappings":"AAGA,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,oBAAoB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../screens/index.ts"],"names":[],"mappings":"AAGA,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,uBAAuB,CAAC;AACtC,cAAc,yBAAyB,CAAC;AACxC,cAAc,oBAAoB,CAAC"}
@@ -2,5 +2,7 @@ export * from './Outlet';
2
2
  export * from './Screen';
3
3
  export * from './ScreenTemplate';
4
4
  export * from './DialogTemplate';
5
+ export * from './TemplateAttribution';
6
+ export * from './TemplateCompatibility';
5
7
  export * from './TemplateMetadata';
6
8
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../screens/index.ts"],"names":[],"mappings":"AAGA,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,oBAAoB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../screens/index.ts"],"names":[],"mappings":"AAGA,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,uBAAuB,CAAC;AACtC,cAAc,yBAAyB,CAAC;AACxC,cAAc,oBAAoB,CAAC"}