Merge remote-tracking branch 'origin/main' into v14/bugfix/correct-settings-data-depending-on-config
This commit is contained in:
50
src/Umbraco.Web.UI.Client/package-lock.json
generated
50
src/Umbraco.Web.UI.Client/package-lock.json
generated
@@ -49,7 +49,7 @@
|
||||
"@typescript-eslint/parser": "^7.1.0",
|
||||
"@web/dev-server-esbuild": "^1.0.2",
|
||||
"@web/dev-server-import-maps": "^0.2.0",
|
||||
"@web/dev-server-rollup": "^0.6.1",
|
||||
"@web/dev-server-rollup": "^0.6.3",
|
||||
"@web/test-runner": "^0.18.1",
|
||||
"@web/test-runner-playwright": "^0.11.0",
|
||||
"babel-loader": "^9.1.3",
|
||||
@@ -57,7 +57,7 @@
|
||||
"eslint-config-prettier": "^9.1.0",
|
||||
"eslint-import-resolver-typescript": "^3.6.1",
|
||||
"eslint-plugin-import": "^2.29.1",
|
||||
"eslint-plugin-lit": "^1.11.0",
|
||||
"eslint-plugin-lit": "^1.14.0",
|
||||
"eslint-plugin-lit-a11y": "^4.1.1",
|
||||
"eslint-plugin-local-rules": "^2.0.1",
|
||||
"eslint-plugin-storybook": "^0.6.15",
|
||||
@@ -74,15 +74,15 @@
|
||||
"rollup-plugin-esbuild": "^6.1.1",
|
||||
"rollup-plugin-import-css": "^3.5.0",
|
||||
"rollup-plugin-web-worker-loader": "^1.6.1",
|
||||
"simple-icons": "^11.15.0",
|
||||
"simple-icons": "^12.0.0",
|
||||
"storybook": "^7.6.17",
|
||||
"tiny-glob": "^0.2.9",
|
||||
"tsc-alias": "^1.8.8",
|
||||
"typedoc": "^0.25.10",
|
||||
"typedoc": "^0.25.13",
|
||||
"typescript": "^5.4.5",
|
||||
"typescript-json-schema": "^0.63.0",
|
||||
"vite": "^5.2.9",
|
||||
"vite-plugin-static-copy": "^1.0.2",
|
||||
"vite-plugin-static-copy": "^1.0.5",
|
||||
"vite-tsconfig-paths": "^4.3.2",
|
||||
"web-component-analyzer": "^2.0.0"
|
||||
},
|
||||
@@ -7669,9 +7669,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/@web/dev-server-core": {
|
||||
"version": "0.7.1",
|
||||
"resolved": "https://registry.npmjs.org/@web/dev-server-core/-/dev-server-core-0.7.1.tgz",
|
||||
"integrity": "sha512-alHd2j0f4e1ekqYDR8lWScrzR7D5gfsUZq3BP3De9bkFWM3AELINCmqqlVKmCtlkAdEc9VyQvNiEqrxraOdc2A==",
|
||||
"version": "0.7.2",
|
||||
"resolved": "https://registry.npmjs.org/@web/dev-server-core/-/dev-server-core-0.7.2.tgz",
|
||||
"integrity": "sha512-Q/0jpF13Ipk+qGGQ+Yx/FW1TQBYazpkfgYHHo96HBE7qv4V4KKHqHglZcSUxti/zd4bToxX1cFTz8dmbTlb8JA==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"@types/koa": "^2.11.6",
|
||||
@@ -8158,13 +8158,13 @@
|
||||
}
|
||||
},
|
||||
"node_modules/@web/dev-server-rollup": {
|
||||
"version": "0.6.1",
|
||||
"resolved": "https://registry.npmjs.org/@web/dev-server-rollup/-/dev-server-rollup-0.6.1.tgz",
|
||||
"integrity": "sha512-vhtsQ8qu1pBHailOBOYJwZnYDc1Lmx6ZAd2j+y5PD2ck0R1LmVsZ7dZK8hDCpkvpvlu2ndURjL9tbzdcsBRJmg==",
|
||||
"version": "0.6.3",
|
||||
"resolved": "https://registry.npmjs.org/@web/dev-server-rollup/-/dev-server-rollup-0.6.3.tgz",
|
||||
"integrity": "sha512-dzMwQRBk9Rhpfoo7vvQGvRP18sDELejJCwxsMdt509aLouIB6fviv0i87DJQWbXH24hBeq6+jSILI3JTtVaPZQ==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"@rollup/plugin-node-resolve": "^15.0.1",
|
||||
"@web/dev-server-core": "^0.7.0",
|
||||
"@web/dev-server-core": "^0.7.2",
|
||||
"nanocolors": "^0.2.1",
|
||||
"parse5": "^6.0.1",
|
||||
"rollup": "^4.4.0",
|
||||
@@ -11233,9 +11233,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/eslint-plugin-lit": {
|
||||
"version": "1.11.0",
|
||||
"resolved": "https://registry.npmjs.org/eslint-plugin-lit/-/eslint-plugin-lit-1.11.0.tgz",
|
||||
"integrity": "sha512-jVqy2juQTAtOzj1ILf+ZW5GpDobXlSw0kvpP2zu2r8ZbW7KISt7ikj1Gw9DhNeirEU1UlSJR0VIWpdr4lzjayw==",
|
||||
"version": "1.14.0",
|
||||
"resolved": "https://registry.npmjs.org/eslint-plugin-lit/-/eslint-plugin-lit-1.14.0.tgz",
|
||||
"integrity": "sha512-J4w+CgO31621GreLFCdTUbTr5yeV2/RJ/M0myw0dykD5p9FGGIRLityQiNa6SG+JpVbmeQTQPJy4pNFmiurJ/w==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"parse5": "^6.0.1",
|
||||
@@ -18468,9 +18468,9 @@
|
||||
"dev": true
|
||||
},
|
||||
"node_modules/simple-icons": {
|
||||
"version": "11.15.0",
|
||||
"resolved": "https://registry.npmjs.org/simple-icons/-/simple-icons-11.15.0.tgz",
|
||||
"integrity": "sha512-uDAdtIGc56YJiGpdzImENY4E+5qtHEorW11KoXiwDj4u4YSY74G+q/a9idlY8iEqrjghHGkZ/ras0jRT7JpDTQ==",
|
||||
"version": "12.0.0",
|
||||
"resolved": "https://registry.npmjs.org/simple-icons/-/simple-icons-12.0.0.tgz",
|
||||
"integrity": "sha512-KsqyGTRS1c9hp1oGEspCdp8qbqljjH199pUZZWR3DeStg2RBjzB3EJT9kLZ8tPlIrWOyktjj+TIgDQphYHq7XQ==",
|
||||
"dev": true,
|
||||
"engines": {
|
||||
"node": ">=0.12.18"
|
||||
@@ -19630,9 +19630,9 @@
|
||||
"dev": true
|
||||
},
|
||||
"node_modules/typedoc": {
|
||||
"version": "0.25.10",
|
||||
"resolved": "https://registry.npmjs.org/typedoc/-/typedoc-0.25.10.tgz",
|
||||
"integrity": "sha512-v10rtOFojrjW9og3T+6wAKeJaGMuojU87DXGZ33sfs+554wgPTRG+s07Ag1BjPZI85Y5QPVouPI63JQ6fcQM5w==",
|
||||
"version": "0.25.13",
|
||||
"resolved": "https://registry.npmjs.org/typedoc/-/typedoc-0.25.13.tgz",
|
||||
"integrity": "sha512-pQqiwiJ+Z4pigfOnnysObszLiU3mVLWAExSPf+Mu06G/qsc3wzbuM56SZQvONhHLncLUhYzOVkjFFpFfL5AzhQ==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"lunr": "^2.3.9",
|
||||
@@ -19647,7 +19647,7 @@
|
||||
"node": ">= 16"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"typescript": "4.6.x || 4.7.x || 4.8.x || 4.9.x || 5.0.x || 5.1.x || 5.2.x || 5.3.x"
|
||||
"typescript": "4.6.x || 4.7.x || 4.8.x || 4.9.x || 5.0.x || 5.1.x || 5.2.x || 5.3.x || 5.4.x"
|
||||
}
|
||||
},
|
||||
"node_modules/typedoc/node_modules/marked": {
|
||||
@@ -20319,9 +20319,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/vite-plugin-static-copy": {
|
||||
"version": "1.0.2",
|
||||
"resolved": "https://registry.npmjs.org/vite-plugin-static-copy/-/vite-plugin-static-copy-1.0.2.tgz",
|
||||
"integrity": "sha512-AfmEF+a/mfjsUsrgjbCkhzUCeIUF4EKQXXt3Ie1cour9MBpy6f6GphbdW2td28oYfOrwCyRzFCksgLkpk58q6Q==",
|
||||
"version": "1.0.5",
|
||||
"resolved": "https://registry.npmjs.org/vite-plugin-static-copy/-/vite-plugin-static-copy-1.0.5.tgz",
|
||||
"integrity": "sha512-02k0Rox+buYdEOfeilKZSgs1gXfPf9RjVztZEIYZgVIxjsVZi6AXssjzdi+qW6zYt00d3bq+tpP2voVXN2fKLw==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"chokidar": "^3.5.3",
|
||||
|
||||
@@ -211,7 +211,7 @@
|
||||
"@typescript-eslint/parser": "^7.1.0",
|
||||
"@web/dev-server-esbuild": "^1.0.2",
|
||||
"@web/dev-server-import-maps": "^0.2.0",
|
||||
"@web/dev-server-rollup": "^0.6.1",
|
||||
"@web/dev-server-rollup": "^0.6.3",
|
||||
"@web/test-runner": "^0.18.1",
|
||||
"@web/test-runner-playwright": "^0.11.0",
|
||||
"babel-loader": "^9.1.3",
|
||||
@@ -219,7 +219,7 @@
|
||||
"eslint-config-prettier": "^9.1.0",
|
||||
"eslint-import-resolver-typescript": "^3.6.1",
|
||||
"eslint-plugin-import": "^2.29.1",
|
||||
"eslint-plugin-lit": "^1.11.0",
|
||||
"eslint-plugin-lit": "^1.14.0",
|
||||
"eslint-plugin-lit-a11y": "^4.1.1",
|
||||
"eslint-plugin-local-rules": "^2.0.1",
|
||||
"eslint-plugin-storybook": "^0.6.15",
|
||||
@@ -236,15 +236,15 @@
|
||||
"rollup-plugin-esbuild": "^6.1.1",
|
||||
"rollup-plugin-import-css": "^3.5.0",
|
||||
"rollup-plugin-web-worker-loader": "^1.6.1",
|
||||
"simple-icons": "^11.15.0",
|
||||
"simple-icons": "^12.0.0",
|
||||
"storybook": "^7.6.17",
|
||||
"tiny-glob": "^0.2.9",
|
||||
"tsc-alias": "^1.8.8",
|
||||
"typedoc": "^0.25.10",
|
||||
"typedoc": "^0.25.13",
|
||||
"typescript": "^5.4.5",
|
||||
"typescript-json-schema": "^0.63.0",
|
||||
"vite": "^5.2.9",
|
||||
"vite-plugin-static-copy": "^1.0.2",
|
||||
"vite-plugin-static-copy": "^1.0.5",
|
||||
"vite-tsconfig-paths": "^4.3.2",
|
||||
"web-component-analyzer": "^2.0.0"
|
||||
},
|
||||
|
||||
@@ -60,7 +60,7 @@ export default {
|
||||
sendToTranslate: 'Send To Translation',
|
||||
setGroup: 'Set group',
|
||||
setPermissions: 'Set permissions',
|
||||
sort: 'Sort children of',
|
||||
sort: 'Sort children',
|
||||
toInTheTreeStructureBelow: 'to in the tree structure below',
|
||||
translate: 'Translate',
|
||||
trash: 'Trash',
|
||||
|
||||
@@ -59,7 +59,7 @@ export default {
|
||||
sendToTranslate: 'Send To Translation',
|
||||
setGroup: 'Set group',
|
||||
setPermissions: 'Set permissions',
|
||||
sort: 'Sort children of',
|
||||
sort: 'Sort children',
|
||||
toInTheTreeStructureBelow: 'to in the tree structure below',
|
||||
translate: 'Translate',
|
||||
trash: 'Trash',
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -122,6 +122,7 @@ export interface MetaEntityActionDuplicateToKind extends MetaEntityActionDefault
|
||||
duplicateRepositoryAlias: string;
|
||||
treeRepositoryAlias: string;
|
||||
treeAlias: string;
|
||||
foldersOnly?: boolean;
|
||||
}
|
||||
|
||||
// MOVE TO
|
||||
|
||||
@@ -30,6 +30,8 @@ export class UmbSectionSidebarElement extends UmbLitElement {
|
||||
flex-direction: column;
|
||||
z-index: 10;
|
||||
position: relative;
|
||||
padding-bottom: var(--uui-size-4);
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
#scroll-container {
|
||||
|
||||
@@ -17,6 +17,7 @@ export class UmbDuplicateToEntityAction extends UmbEntityActionBase<MetaEntityAc
|
||||
unique: this.args.unique,
|
||||
entityType: this.args.entityType,
|
||||
treeAlias: this.args.meta.treeAlias,
|
||||
foldersOnly: this.args.meta.foldersOnly,
|
||||
},
|
||||
});
|
||||
|
||||
|
||||
@@ -22,7 +22,12 @@ export class UmbDuplicateToModalElement extends UmbModalBaseElement<UmbDuplicate
|
||||
return html`
|
||||
<umb-body-layout headline="Duplicate">
|
||||
<uui-box>
|
||||
<umb-tree alias=${this.data.treeAlias} @selection-change=${this.#onTreeSelectionChange}></umb-tree>
|
||||
<umb-tree
|
||||
alias=${this.data.treeAlias}
|
||||
.props=${{
|
||||
foldersOnly: this.data?.foldersOnly,
|
||||
}}
|
||||
@selection-change=${this.#onTreeSelectionChange}></umb-tree>
|
||||
</uui-box>
|
||||
|
||||
${this.#renderActions()}
|
||||
|
||||
@@ -4,6 +4,7 @@ import { UmbModalToken } from '@umbraco-cms/backoffice/modal';
|
||||
|
||||
export interface UmbDuplicateToModalData extends UmbEntityModel {
|
||||
treeAlias: string;
|
||||
foldersOnly?: boolean;
|
||||
}
|
||||
|
||||
export interface UmbDuplicateToModalValue {
|
||||
|
||||
@@ -4,6 +4,7 @@ import { UmbModalBaseElement } from '@umbraco-cms/backoffice/modal';
|
||||
import type { UmbFolderModel, UmbFolderRepository } from '@umbraco-cms/backoffice/tree';
|
||||
import { UmbExtensionApiInitializer } from '@umbraco-cms/backoffice/extension-api';
|
||||
import { umbExtensionsRegistry } from '@umbraco-cms/backoffice/extension-registry';
|
||||
import { umbFocus } from '@umbraco-cms/backoffice/lit-element';
|
||||
|
||||
export abstract class UmbFolderModalElementBase<
|
||||
FolderModalDataType extends { folderRepositoryAlias: string },
|
||||
@@ -56,26 +57,32 @@ export abstract class UmbFolderModalElementBase<
|
||||
|
||||
render() {
|
||||
return html`
|
||||
<umb-body-layout headline=${this._isNew ? 'Create Folder' : 'Update Folder'}>
|
||||
<umb-body-layout headline=${this.localize.term(this._isNew ? 'actions_folderCreate' : 'actions_folderRename')}>
|
||||
<uui-box>
|
||||
<uui-form>
|
||||
<form id="FolderForm" @submit="${this.#onSubmit}">
|
||||
<uui-form-layout-item>
|
||||
<uui-label id="nameLabel" for="name" slot="label" required>Folder name</uui-label>
|
||||
<uui-label id="nameLabel" for="name" slot="label" required>
|
||||
<umb-localize key="create_enterFolderName">Enter folder name</umb-localize>
|
||||
</uui-label>
|
||||
<uui-input
|
||||
type="text"
|
||||
id="name"
|
||||
name="name"
|
||||
placeholder="Enter folder name..."
|
||||
.label=${this.localize.term('create_enterFolderName')}
|
||||
.value="${this.value?.folder?.name || ''}"
|
||||
required
|
||||
required-message="Folder name is required"></uui-input>
|
||||
${umbFocus()}></uui-input>
|
||||
</uui-form-layout-item>
|
||||
</form>
|
||||
</uui-form>
|
||||
</uui-box>
|
||||
|
||||
<uui-button slot="actions" id="cancel" label="Cancel" @click="${this._rejectModal}"></uui-button>
|
||||
<uui-button
|
||||
slot="actions"
|
||||
id="cancel"
|
||||
label=${this.localize.term('buttons_confirmActionCancel')}
|
||||
@click="${this._rejectModal}"></uui-button>
|
||||
<uui-button
|
||||
form="FolderForm"
|
||||
type="submit"
|
||||
@@ -83,7 +90,7 @@ export abstract class UmbFolderModalElementBase<
|
||||
id="confirm"
|
||||
color="positive"
|
||||
look="primary"
|
||||
label=${this._isNew ? 'Create Folder' : 'Update Folder'}></uui-button>
|
||||
label=${this.localize.term(this._isNew ? 'actions_folderCreate' : 'actions_folderRename')}></uui-button>
|
||||
</umb-body-layout>
|
||||
`;
|
||||
}
|
||||
|
||||
@@ -15,6 +15,7 @@ const entityActions: Array<ManifestTypes> = [
|
||||
duplicateRepositoryAlias: UMB_DUPLICATE_DATA_TYPE_REPOSITORY_ALIAS,
|
||||
treeAlias: UMB_DATA_TYPE_TREE_ALIAS,
|
||||
treeRepositoryAlias: UMB_DATA_TYPE_TREE_REPOSITORY_ALIAS,
|
||||
foldersOnly: true,
|
||||
},
|
||||
},
|
||||
];
|
||||
|
||||
@@ -3,8 +3,8 @@ import { UMB_DOCUMENT_BLUEPRINT_ENTITY_TYPE } from '../../entity.js';
|
||||
import { UmbId } from '@umbraco-cms/backoffice/id';
|
||||
import type { UmbDetailDataSource } from '@umbraco-cms/backoffice/repository';
|
||||
import type {
|
||||
CreateDocumentRequestModel,
|
||||
UpdateDocumentRequestModel,
|
||||
CreateDocumentBlueprintRequestModel,
|
||||
UpdateDocumentBlueprintRequestModel,
|
||||
} from '@umbraco-cms/backoffice/external/backend-api';
|
||||
import { DocumentBlueprintService } from '@umbraco-cms/backoffice/external/backend-api';
|
||||
import type { UmbControllerHost } from '@umbraco-cms/backoffice/controller-api';
|
||||
@@ -129,11 +129,10 @@ export class UmbDocumentBlueprintServerDataSource implements UmbDetailDataSource
|
||||
if (!model.unique) throw new Error('Document unique is missing');
|
||||
|
||||
// TODO: make data mapper to prevent errors
|
||||
const requestBody: CreateDocumentRequestModel = {
|
||||
const requestBody: CreateDocumentBlueprintRequestModel = {
|
||||
id: model.unique,
|
||||
parent: parentUnique ? { id: parentUnique } : null,
|
||||
documentType: { id: model.documentType.unique },
|
||||
|
||||
values: model.values,
|
||||
variants: model.variants,
|
||||
};
|
||||
@@ -162,7 +161,7 @@ export class UmbDocumentBlueprintServerDataSource implements UmbDetailDataSource
|
||||
if (!model.unique) throw new Error('Unique is missing');
|
||||
|
||||
// TODO: make data mapper to prevent errors
|
||||
const requestBody: UpdateDocumentRequestModel = {
|
||||
const requestBody: UpdateDocumentBlueprintRequestModel = {
|
||||
values: model.values,
|
||||
variants: model.variants,
|
||||
};
|
||||
|
||||
@@ -15,6 +15,7 @@ const entityActions: Array<ManifestTypes> = [
|
||||
duplicateRepositoryAlias: UMB_DUPLICATE_DOCUMENT_TYPE_REPOSITORY_ALIAS,
|
||||
treeAlias: UMB_DOCUMENT_TYPE_TREE_ALIAS,
|
||||
treeRepositoryAlias: UMB_DOCUMENT_TYPE_TREE_REPOSITORY_ALIAS,
|
||||
foldersOnly: true,
|
||||
},
|
||||
},
|
||||
];
|
||||
|
||||
@@ -15,6 +15,7 @@ const entityActions: Array<ManifestTypes> = [
|
||||
treeRepositoryAlias: UMB_DOCUMENT_TYPE_TREE_REPOSITORY_ALIAS,
|
||||
moveRepositoryAlias: UMB_MOVE_DOCUMENT_TYPE_REPOSITORY_ALIAS,
|
||||
treeAlias: UMB_DOCUMENT_TYPE_TREE_ALIAS,
|
||||
foldersOnly: true,
|
||||
},
|
||||
},
|
||||
];
|
||||
|
||||
@@ -41,15 +41,24 @@ export class UmbDocumentTypeTreeServerDataSource extends UmbTreeServerDataSource
|
||||
|
||||
const getRootItems = (args: UmbTreeRootItemsRequestArgs) =>
|
||||
// eslint-disable-next-line local-rules/no-direct-api-import
|
||||
DocumentTypeService.getTreeDocumentTypeRoot({ skip: args.skip, take: args.take });
|
||||
DocumentTypeService.getTreeDocumentTypeRoot({
|
||||
foldersOnly: args.foldersOnly,
|
||||
skip: args.skip,
|
||||
take: args.take,
|
||||
});
|
||||
|
||||
const getChildrenOf = (args: UmbTreeChildrenOfRequestArgs) => {
|
||||
if (args.parent.unique === null) {
|
||||
return getRootItems({ skip: args.skip, take: args.take });
|
||||
return getRootItems({
|
||||
foldersOnly: args.foldersOnly,
|
||||
skip: args.skip,
|
||||
take: args.take,
|
||||
});
|
||||
} else {
|
||||
// eslint-disable-next-line local-rules/no-direct-api-import
|
||||
return DocumentTypeService.getTreeDocumentTypeChildren({
|
||||
parentId: args.parent.unique,
|
||||
foldersOnly: args.foldersOnly,
|
||||
skip: args.skip,
|
||||
take: args.take,
|
||||
});
|
||||
|
||||
@@ -15,6 +15,7 @@ const entityActions: Array<ManifestTypes> = [
|
||||
duplicateRepositoryAlias: UMB_DUPLICATE_MEDIA_TYPE_REPOSITORY_ALIAS,
|
||||
treeAlias: UMB_MEDIA_TYPE_TREE_ALIAS,
|
||||
treeRepositoryAlias: UMB_MEDIA_TYPE_TREE_REPOSITORY_ALIAS,
|
||||
foldersOnly: true,
|
||||
},
|
||||
},
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user