update imports

This commit is contained in:
Mads Rasmussen
2024-09-13 20:51:14 +02:00
parent 337166b9f3
commit acd0c15d4c
3 changed files with 84 additions and 129 deletions

View File

@@ -5,51 +5,36 @@ import {
UMB_DATA_TYPE_TREE_REPOSITORY_ALIAS,
UMB_DATA_TYPE_TREE_STORE_ALIAS,
} from './constants.js';
import type {
ManifestRepository,
ManifestTree,
ManifestTreeItem,
ManifestTreeStore,
ManifestTypes,
} from '@umbraco-cms/backoffice/extension-registry';
const treeRepository: ManifestRepository = {
type: 'repository',
alias: UMB_DATA_TYPE_TREE_REPOSITORY_ALIAS,
name: 'Data Type Tree Repository',
api: () => import('./data-type-tree.repository.js'),
};
const treeStore: ManifestTreeStore = {
type: 'treeStore',
alias: UMB_DATA_TYPE_TREE_STORE_ALIAS,
name: 'Data Type Tree Store',
api: () => import('./data-type-tree.store.js'),
};
const tree: ManifestTree = {
type: 'tree',
kind: 'default',
alias: UMB_DATA_TYPE_TREE_ALIAS,
name: 'Data Types Tree',
meta: {
repositoryAlias: UMB_DATA_TYPE_TREE_REPOSITORY_ALIAS,
export const manifests: Array<UmbExtensionManifest> = [
{
type: 'repository',
alias: UMB_DATA_TYPE_TREE_REPOSITORY_ALIAS,
name: 'Data Type Tree Repository',
api: () => import('./data-type-tree.repository.js'),
},
{
type: 'treeStore',
alias: UMB_DATA_TYPE_TREE_STORE_ALIAS,
name: 'Data Type Tree Store',
api: () => import('./data-type-tree.store.js'),
},
{
type: 'tree',
kind: 'default',
alias: UMB_DATA_TYPE_TREE_ALIAS,
name: 'Data Types Tree',
meta: {
repositoryAlias: UMB_DATA_TYPE_TREE_REPOSITORY_ALIAS,
},
},
{
type: 'treeItem',
kind: 'default',
alias: 'Umb.TreeItem.DataType',
name: 'Data Type Tree Item',
forEntityTypes: ['data-type-root', 'data-type', 'data-type-folder'],
},
};
const treeItem: ManifestTreeItem = {
type: 'treeItem',
kind: 'default',
alias: 'Umb.TreeItem.DataType',
name: 'Data Type Tree Item',
forEntityTypes: ['data-type-root', 'data-type', 'data-type-folder'],
};
export const manifests: Array<ManifestTypes> = [
treeRepository,
treeStore,
tree,
treeItem,
...folderManifests,
...reloadManifests,
];

View File

@@ -5,50 +5,35 @@ import {
UMB_DICTIONARY_TREE_STORE_ALIAS,
} from './constants.js';
import { manifests as reloadTreeItemChildrenManifests } from './reload-tree-item-children/manifests.js';
import type {
ManifestRepository,
ManifestTree,
ManifestTreeItem,
ManifestTreeStore,
ManifestTypes,
} from '@umbraco-cms/backoffice/extension-registry';
const treeRepository: ManifestRepository = {
type: 'repository',
alias: UMB_DICTIONARY_TREE_REPOSITORY_ALIAS,
name: 'Dictionary Tree Repository',
api: () => import('./dictionary-tree.repository.js'),
};
const treeStore: ManifestTreeStore = {
type: 'treeStore',
alias: UMB_DICTIONARY_TREE_STORE_ALIAS,
name: 'Dictionary Tree Store',
api: () => import('./dictionary-tree.store.js'),
};
const tree: ManifestTree = {
type: 'tree',
kind: 'default',
alias: UMB_DICTIONARY_TREE_ALIAS,
name: 'Dictionary Tree',
meta: {
repositoryAlias: UMB_DICTIONARY_TREE_REPOSITORY_ALIAS,
export const manifests: Array<UmbExtensionManifest> = [
{
type: 'repository',
alias: UMB_DICTIONARY_TREE_REPOSITORY_ALIAS,
name: 'Dictionary Tree Repository',
api: () => import('./dictionary-tree.repository.js'),
},
{
type: 'treeStore',
alias: UMB_DICTIONARY_TREE_STORE_ALIAS,
name: 'Dictionary Tree Store',
api: () => import('./dictionary-tree.store.js'),
},
{
type: 'tree',
kind: 'default',
alias: UMB_DICTIONARY_TREE_ALIAS,
name: 'Dictionary Tree',
meta: {
repositoryAlias: UMB_DICTIONARY_TREE_REPOSITORY_ALIAS,
},
},
{
type: 'treeItem',
kind: 'default',
alias: 'Umb.TreeItem.Dictionary',
name: 'Dictionary Tree Item',
forEntityTypes: [UMB_DICTIONARY_ROOT_ENTITY_TYPE, UMB_DICTIONARY_ENTITY_TYPE],
},
};
const treeItem: ManifestTreeItem = {
type: 'treeItem',
kind: 'default',
alias: 'Umb.TreeItem.Dictionary',
name: 'Dictionary Tree Item',
forEntityTypes: [UMB_DICTIONARY_ROOT_ENTITY_TYPE, UMB_DICTIONARY_ENTITY_TYPE],
};
export const manifests: Array<ManifestTypes> = [
treeRepository,
treeStore,
tree,
treeItem,
...reloadTreeItemChildrenManifests,
];

View File

@@ -5,50 +5,35 @@ import {
UMB_MEDIA_RECYCLE_BIN_TREE_STORE_ALIAS,
} from './constants.js';
import { manifests as reloadTreeItemChildrenManifests } from './reload-tree-item-children/manifests.js';
import type {
ManifestRepository,
ManifestTree,
ManifestTreeItem,
ManifestTreeStore,
ManifestTypes,
} from '@umbraco-cms/backoffice/extension-registry';
const treeRepository: ManifestRepository = {
type: 'repository',
alias: UMB_MEDIA_RECYCLE_BIN_TREE_REPOSITORY_ALIAS,
name: 'Media Recycle Bin Tree Repository',
api: () => import('./media-recycle-bin-tree.repository.js'),
};
const treeStore: ManifestTreeStore = {
type: 'treeStore',
alias: UMB_MEDIA_RECYCLE_BIN_TREE_STORE_ALIAS,
name: 'Media Recycle Bin Tree Store',
api: () => import('./media-recycle-bin-tree.store.js'),
};
const tree: ManifestTree = {
type: 'tree',
kind: 'default',
alias: UMB_MEDIA_RECYCLE_BIN_TREE_ALIAS,
name: 'Media Recycle Bin Tree',
meta: {
repositoryAlias: UMB_MEDIA_RECYCLE_BIN_TREE_REPOSITORY_ALIAS,
export const manifests: Array<UmbExtensionManifest> = [
{
type: 'repository',
alias: UMB_MEDIA_RECYCLE_BIN_TREE_REPOSITORY_ALIAS,
name: 'Media Recycle Bin Tree Repository',
api: () => import('./media-recycle-bin-tree.repository.js'),
},
{
type: 'treeStore',
alias: UMB_MEDIA_RECYCLE_BIN_TREE_STORE_ALIAS,
name: 'Media Recycle Bin Tree Store',
api: () => import('./media-recycle-bin-tree.store.js'),
},
{
type: 'tree',
kind: 'default',
alias: UMB_MEDIA_RECYCLE_BIN_TREE_ALIAS,
name: 'Media Recycle Bin Tree',
meta: {
repositoryAlias: UMB_MEDIA_RECYCLE_BIN_TREE_REPOSITORY_ALIAS,
},
},
{
type: 'treeItem',
kind: 'default',
alias: 'Umb.TreeItem.Media.RecycleBin',
name: 'Media Recycle Bin Tree Item',
forEntityTypes: [UMB_MEDIA_RECYCLE_BIN_ROOT_ENTITY_TYPE],
},
};
const treeItem: ManifestTreeItem = {
type: 'treeItem',
kind: 'default',
alias: 'Umb.TreeItem.Media.RecycleBin',
name: 'Media Recycle Bin Tree Item',
forEntityTypes: [UMB_MEDIA_RECYCLE_BIN_ROOT_ENTITY_TYPE],
};
export const manifests: Array<ManifestTypes> = [
treeRepository,
treeStore,
tree,
treeItem,
...reloadTreeItemChildrenManifests,
];