@umbraco-cms/backoffice 14.3.0-rc → 14.3.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/dist-cms/custom-elements.json +44 -0
  2. package/dist-cms/packages/block/block/workspace/block-element-manager.d.ts +2 -2
  3. package/dist-cms/packages/block/block/workspace/block-element-manager.js +2 -2
  4. package/dist-cms/packages/block/block/workspace/views/edit/block-workspace-view-edit-properties.element.d.ts +1 -0
  5. package/dist-cms/packages/block/block/workspace/views/edit/block-workspace-view-edit-properties.element.js +5 -0
  6. package/dist-cms/packages/block/block-grid/property-editors/block-grid-editor/property-editor-ui-block-grid.element.js +1 -1
  7. package/dist-cms/packages/block/block-list/property-editors/block-list-editor/property-editor-ui-block-list.element.js +1 -1
  8. package/dist-cms/packages/core/components/code-block/code-block.element.js +1 -1
  9. package/dist-cms/packages/core/content-type/components/property-type-based-property/property-type-based-property.element.d.ts +6 -0
  10. package/dist-cms/packages/core/content-type/components/property-type-based-property/property-type-based-property.element.js +32 -0
  11. package/dist-cms/packages/core/property/index.d.ts +1 -0
  12. package/dist-cms/packages/core/property/index.js +1 -0
  13. package/dist-cms/packages/core/property/types/index.d.ts +1 -0
  14. package/dist-cms/packages/core/property/types/index.js +1 -0
  15. package/dist-cms/packages/core/property/types/unsupported-properties.type.d.ts +1 -0
  16. package/dist-cms/packages/core/property/types/unsupported-properties.type.js +1 -0
  17. package/dist-cms/packages/core/property/unsupported-property/index.d.ts +2 -0
  18. package/dist-cms/packages/core/property/unsupported-property/index.js +2 -0
  19. package/dist-cms/packages/core/property/unsupported-property/unsupported-property.element.d.ts +15 -0
  20. package/dist-cms/packages/core/property/unsupported-property/unsupported-property.element.js +50 -0
  21. package/dist-cms/packages/core/property/unsupported-property/utils.d.ts +2 -0
  22. package/dist-cms/packages/core/property/unsupported-property/utils.js +3 -0
  23. package/dist-cms/packages/core/property-type/workspace/property-type-workspace.context.js +1 -1
  24. package/dist-cms/packages/core/validation/context/index.d.ts +2 -0
  25. package/dist-cms/packages/core/validation/context/index.js +2 -0
  26. package/dist-cms/packages/core/validation/{controllers → context}/server-model-validator.context.js +1 -1
  27. package/dist-cms/packages/core/validation/context/validation.context-token.d.ts +2 -2
  28. package/dist-cms/packages/core/validation/context/validation.context.d.ts +6 -77
  29. package/dist-cms/packages/core/validation/context/validation.context.js +7 -243
  30. package/dist-cms/packages/core/validation/controllers/index.d.ts +1 -2
  31. package/dist-cms/packages/core/validation/controllers/index.js +1 -2
  32. package/dist-cms/packages/core/validation/controllers/validation.controller.d.ts +84 -0
  33. package/dist-cms/packages/core/validation/controllers/validation.controller.js +252 -0
  34. package/dist-cms/packages/core/workspace/contexts/submittable-workspace-context-base.d.ts +2 -2
  35. package/dist-cms/packages/data-type/workspace/data-type-workspace.context.js +1 -1
  36. package/dist-cms/packages/documents/document-types/workspace/document-type-workspace.context.js +1 -1
  37. package/dist-cms/packages/documents/documents/entity-actions/create/document-create-options-modal.element.js +28 -13
  38. package/dist-cms/packages/documents/documents/workspace/document-workspace.context.js +1 -1
  39. package/dist-cms/packages/sysinfo/components/sysinfo.element.js +1 -1
  40. package/dist-cms/tsconfig.build.tsbuildinfo +1 -1
  41. package/dist-cms/umbraco-package.json +1 -1
  42. package/dist-cms/vscode-html-custom-data.json +21 -2
  43. package/package.json +1 -1
  44. /package/dist-cms/packages/core/validation/{controllers → context}/server-model-validator.context-token.d.ts +0 -0
  45. /package/dist-cms/packages/core/validation/{controllers → context}/server-model-validator.context-token.js +0 -0
  46. /package/dist-cms/packages/core/validation/{controllers → context}/server-model-validator.context.d.ts +0 -0
@@ -96,22 +96,37 @@ let UmbDocumentCreateOptionsModalElement = class UmbDocumentCreateOptionsModalEl
96
96
  </umb-body-layout>
97
97
  `;
98
98
  }
99
+ #renderNoDocumentTypes() {
100
+ if (this.data?.documentType?.unique) {
101
+ return html `
102
+ <umb-localize key="create_noDocumentTypes">
103
+ There are no allowed Document Types available for creating content here. You must enable these in
104
+ <strong>Document Types</strong> within the <strong>Settings</strong> section, by editing the
105
+ <strong>Allowed child node types</strong> under <strong>Structure</strong>.
106
+ </umb-localize>
107
+ <br />
108
+ <uui-button
109
+ id="edit-permissions"
110
+ look="secondary"
111
+ href=${`/section/settings/workspace/document-type/edit/${this.data?.documentType?.unique}/view/structure`}
112
+ label=${this.localize.term('create_noDocumentTypesEditPermissions')}
113
+ @click=${() => this._rejectModal()}></uui-button>
114
+ `;
115
+ }
116
+ else {
117
+ return html `
118
+ <umb-localize key="create_noDocumentTypesAllowedAtRoot">
119
+ There are no allowed Document Types available for creating content here. You must enable these in
120
+ <strong>Document Types</strong> within the <strong>Settings</strong> section, by changing the
121
+ <strong>Allow as root</strong> option under <strong>Structure</strong>.
122
+ </umb-localize>
123
+ `;
124
+ }
125
+ }
99
126
  #renderDocumentTypes() {
100
127
  return html `
101
128
  <uui-box .headline=${this._headline}>
102
- ${when(this._allowedDocumentTypes.length === 0, () => html `
103
- <umb-localize key="create_noDocumentTypes">
104
- There are no allowed Document Types available for creating content here. You must enable these in
105
- <strong>Document Types</strong> within the <strong>Settings</strong> section, by editing the
106
- <strong>Allowed child node types</strong> under <strong>Permissions</strong>.<br />
107
- </umb-localize>
108
- <uui-button
109
- id="edit-permissions"
110
- look="secondary"
111
- href=${`/section/settings/workspace/document-type/edit/${this.data?.documentType?.unique}/view/structure`}
112
- label=${this.localize.term('create_noDocumentTypesEditPermissions')}
113
- @click=${() => this._rejectModal()}></uui-button>
114
- `, () => repeat(this._allowedDocumentTypes, (documentType) => documentType.unique, (documentType) => html `
129
+ ${when(this._allowedDocumentTypes.length === 0, () => this.#renderNoDocumentTypes(), () => repeat(this._allowedDocumentTypes, (documentType) => documentType.unique, (documentType) => html `
115
130
  <uui-ref-node-document-type
116
131
  data-id=${ifDefined(documentType.unique)}
117
132
  .name=${this.localize.string(documentType.name)}
@@ -124,7 +124,7 @@ export class UmbDocumentWorkspaceContext extends UmbSubmittableWorkspaceContextB
124
124
  const readOnlyCultures = this.readOnlyState.getStates().map((s) => s.variantId.culture);
125
125
  return readOnlyCultures.includes(option.culture) === false;
126
126
  };
127
- this.addValidationContext(new UmbValidationContext(this).provide());
127
+ this.addValidationContext(new UmbValidationContext(this));
128
128
  new UmbVariantValuesValidationPathTranslator(this);
129
129
  new UmbVariantsValidationPathTranslator(this);
130
130
  this.observe(this.contentTypeUnique, (unique) => this.structure.loadType(unique));
@@ -57,7 +57,7 @@ let UmbSysinfoElement = class UmbSysinfoElement extends UmbModalBaseElement {
57
57
  return html `
58
58
  <uui-dialog>
59
59
  <uui-dialog-layout headline="System information">
60
- ${when(this._loading, () => html `<uui-loader-bar></uui-loader-bar>`, () => html ` <umb-code-block id="codeblock"> ${this._systemInformation} </umb-code-block> `)}
60
+ ${when(this._loading, () => html `<uui-loader-bar></uui-loader-bar>`, () => html ` <umb-code-block id="codeblock">${this._systemInformation}</umb-code-block> `)}
61
61
 
62
62
  <uui-button
63
63
  @click=${this._submitModal}