add default kind

This commit is contained in:
Mads Rasmussen
2024-10-29 22:02:22 +01:00
committed by Niels Lyngsø
parent db65391d3a
commit 170a813010
5 changed files with 75 additions and 0 deletions

View File

@@ -0,0 +1,18 @@
export const manifests = [
{
type: 'kind',
alias: 'Umb.Kind.EntityCreateOptionAction.Default',
matchKind: 'default',
matchType: 'entityCreateOptionAction',
manifest: {
type: 'entityCreateOptionAction',
kind: 'default',
weight: 1000,
meta: {
icon: '',
label: 'Fill out label',
description: 'Fill out description',
},
},
},
];

View File

@@ -0,0 +1,52 @@
import type {
ManifestEntityCreateOptionAction,
MetaEntityCreateOptionAction,
} from '../entity-create-option-action.extension.js';
export interface ManifestEntityCreateOptionActionDefaultKind
extends ManifestEntityCreateOptionAction<MetaEntityCreateOptionActionDefaultKind> {
type: 'entityCreateOptionAction';
kind: 'default';
}
export interface MetaEntityCreateOptionActionDefaultKind extends MetaEntityCreateOptionAction {
/**
* An icon to represent the action to be performed
* @examples [
* "icon-box",
* "icon-grid"
* ]
*/
icon: string;
/**
* The friendly name of the action to perform
* @examples [
* "Create with Template",
* "Create from Blueprint"
* ]
*/
label: string;
/**
* A description of the action to be performed
* @examples [
* "Create a document type with a template",
* "Create a document from a blueprint"
* ]
*/
description: string;
/**
* The action requires additional input from the user.
* A dialog will prompt the user for more information or to make a choice.
* @type {boolean}
*/
additionalOptions?: boolean;
}
declare global {
interface UmbExtensionManifestMap {
umbDefaultEntityCreateOptionActionKind: ManifestEntityCreateOptionActionDefaultKind;
}
}

View File

@@ -1,3 +1,4 @@
export * from './default/index.js';
export * from './entity-create-option-action-base.js';
export * from './entity-create-option-action.extension.js';
export * from './entity-create-option-action.interface.js';

View File

@@ -0,0 +1,3 @@
import { manifests as defaultManifests } from './default/manifests.js';
export const manifests = [...defaultManifests];