Skip to content

Commit

Permalink
Merge pull request #2363 from umbraco/v15/feature/emm-dashboard
Browse files Browse the repository at this point in the history
Extension Manifest Map: dashboard
  • Loading branch information
nielslyngsoe authored Sep 30, 2024
2 parents 9ead5e4 + 3ed574a commit edee8cf
Show file tree
Hide file tree
Showing 15 changed files with 19 additions and 18 deletions.
2 changes: 1 addition & 1 deletion examples/dashboard-with-property-dataset/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { ManifestDashboard } from '@umbraco-cms/backoffice/extension-registry';
import type { ManifestDashboard } from '@umbraco-cms/backoffice/dashboard';

export const manifests: Array<ManifestDashboard> = [
{
Expand Down
2 changes: 1 addition & 1 deletion examples/manifest-picker/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { ManifestDashboard } from '@umbraco-cms/backoffice/extension-registry';
import type { ManifestDashboard } from '@umbraco-cms/backoffice/dashboard';

export const manifests: Array<ManifestDashboard> = [
{
Expand Down
2 changes: 1 addition & 1 deletion examples/sorter-with-nested-containers/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { ManifestDashboard } from '@umbraco-cms/backoffice/extension-registry';
import type { ManifestDashboard } from '@umbraco-cms/backoffice/dashboard';

export const manifests: Array<ManifestDashboard> = [
{
Expand Down
2 changes: 1 addition & 1 deletion examples/sorter-with-two-containers/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { ManifestDashboard } from '@umbraco-cms/backoffice/extension-registry';
import type { ManifestDashboard } from '@umbraco-cms/backoffice/dashboard';

export const manifests: Array<ManifestDashboard> = [
{
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
"./culture": "./dist-cms/packages/core/culture/index.js",
"./picker": "./dist-cms/packages/core/picker/index.js",
"./current-user": "./dist-cms/packages/user/current-user/index.js",
"./dashboard": "./dist-cms/packages/core/dashboard/index.js",
"./data-type": "./dist-cms/packages/data-type/index.js",
"./debug": "./dist-cms/packages/core/debug/index.js",
"./dictionary": "./dist-cms/packages/dictionary/index.js",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { ManifestDashboard } from '../models/index.js';
import type { ManifestDashboard } from './dashboard.extension.js';

export interface UmbDashboardElement extends HTMLElement {
manifest?: ManifestDashboard;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { UmbDashboardElement } from '../interfaces/index.js';
import type { UmbDashboardElement } from '../extension-registry/interfaces/index.js';
import type { ManifestElement, ManifestWithDynamicConditions } from '@umbraco-cms/backoffice/extension-api';

export interface ManifestDashboard
Expand All @@ -25,8 +25,8 @@ export interface MetaDashboard {
pathname?: string;
}

/*
export interface ConditionsDashboard {
sections: string[];
declare global {
interface UmbExtensionManifestMap {
umbDashboard: ManifestDashboard;
}
}
*/
2 changes: 2 additions & 0 deletions src/packages/core/dashboard/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
export * from './dashboard.extension.js';
export * from './dashboard-element.interface.js';
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { UmbExtensionSlotElement } from './extension-slot.element.js';
import { expect, fixture, html } from '@open-wc/testing';
import { customElement } from '@umbraco-cms/backoffice/external/lit';
import type { ManifestDashboard } from '@umbraco-cms/backoffice/extension-registry';
import type { ManifestDashboard } from '@umbraco-cms/backoffice/dashboard';
import { umbExtensionsRegistry } from '@umbraco-cms/backoffice/extension-registry';
import type { UmbExtensionElementInitializer } from '@umbraco-cms/backoffice/extension-api';

Expand Down
2 changes: 1 addition & 1 deletion src/packages/core/extension-registry/interfaces/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
export * from './dashboard-element.interface.js';
export * from '../../dashboard/dashboard-element.interface.js';
export * from './external-login-provider-element.interface.js';
export * from './file-upload-preview.interface.js';
export * from './menu-item-element.interface.js';
3 changes: 0 additions & 3 deletions src/packages/core/extension-registry/models/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import type { ManifestAuthProvider } from './auth-provider.model.js';
import type { ManifestCurrentUserAction, ManifestCurrentUserActionDefaultKind } from './current-user-action.model.js';
import type { ManifestDashboard } from './dashboard.model.js';
import type { ManifestDynamicRootOrigin, ManifestDynamicRootQueryStep } from './dynamic-root.model.js';
import type { ManifestFileUploadPreview } from './file-upload-preview.model.js';
import type { ManifestExternalLoginProvider } from './external-login-provider.model.js';
Expand All @@ -19,7 +18,6 @@ export type * from '../extensions/app-entry-point.extension.js';
export type * from './auth-provider.model.js';
export type * from '../extensions/backoffice-entry-point.extension.js';
export type * from './current-user-action.model.js';
export type * from './dashboard.model.js';
export type * from './dynamic-root.model.js';
export type * from '../extensions/entity-action.extension.js';
export type * from '../extensions/entity-bulk-action.extension.js';
Expand Down Expand Up @@ -50,7 +48,6 @@ export type ManifestTypes =
| ManifestCondition
| ManifestCurrentUserAction
| ManifestCurrentUserActionDefaultKind
| ManifestDashboard
| ManifestDynamicRootOrigin
| ManifestDynamicRootQueryStep
| ManifestFileUploadPreview
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import type { ManifestSectionView, UmbSectionViewElement } from '../extensions/i
import { UmbTextStyles } from '@umbraco-cms/backoffice/style';
import { css, html, nothing, customElement, property, state } from '@umbraco-cms/backoffice/external/lit';
import type { UmbRoute, UmbRouterSlotChangeEvent, UmbRouterSlotInitEvent } from '@umbraco-cms/backoffice/router';
import type { ManifestDashboard, UmbDashboardElement } from '@umbraco-cms/backoffice/extension-registry';
import type { ManifestDashboard, UmbDashboardElement } from '@umbraco-cms/backoffice/dashboard';
import { umbExtensionsRegistry } from '@umbraco-cms/backoffice/extension-registry';
import { UmbExtensionsManifestInitializer, createExtensionElement } from '@umbraco-cms/backoffice/extension-api';
import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element';
Expand Down
2 changes: 1 addition & 1 deletion src/packages/core/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ export default defineConfig({
'content-type/index': './content-type/index.ts',
'content/index': './content/index.ts',
'culture/index': './culture/index.ts',
'dashboard/index': './dashboard/index.ts',
'debug/index': './debug/index.ts',
'entity-action/index': './entity-action/index.ts',
'entity-bulk-action/index': './entity-bulk-action/index.ts',
Expand Down Expand Up @@ -57,7 +58,6 @@ export default defineConfig({
'validation/index': './validation/index.ts',
'variant/index': './variant/index.ts',
'workspace/index': './workspace/index.ts',
//'settings/index': './settings/index.ts', // currently no index file so it is left out
manifests: 'manifests.ts',
},
}),
Expand Down
2 changes: 1 addition & 1 deletion src/packages/umbraco-news/manifests.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { ManifestDashboard } from '@umbraco-cms/backoffice/extension-registry';
import type { ManifestDashboard } from '@umbraco-cms/backoffice/dashboard';

export const dashboard: ManifestDashboard = {
type: 'dashboard',
Expand Down
1 change: 1 addition & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ DON'T EDIT THIS FILE DIRECTLY. It is generated by /devops/tsconfig/index.js
"@umbraco-cms/backoffice/culture": ["./src/packages/core/culture/index.ts"],
"@umbraco-cms/backoffice/picker": ["./src/packages/core/picker/index.ts"],
"@umbraco-cms/backoffice/current-user": ["./src/packages/user/current-user/index.ts"],
"@umbraco-cms/backoffice/dashboard": ["./src/packages/core/dashboard/index.ts"],
"@umbraco-cms/backoffice/data-type": ["./src/packages/data-type/index.ts"],
"@umbraco-cms/backoffice/debug": ["./src/packages/core/debug/index.ts"],
"@umbraco-cms/backoffice/dictionary": ["./src/packages/dictionary/index.ts"],
Expand Down

0 comments on commit edee8cf

Please sign in to comment.