Terminal
Terminal/Skill
Explains how to define kinds in Umbraco backoffice, shared preset settings that extensions inherit to keep their structure consistent.
By Umbraco
Works with
npx skills add umbraco/umbraco-cms-backoffice-skills --skill umbraco-kindsA Kind is a preset configuration that extensions inherit for consistency. It reduces redundancy by defining default properties that multiple extensions can share. Kinds ensure standardized structures across extensions and simplify definitions by providing predefined properties that extensions automatically inherit.
Always fetch the latest docs before implementing:
import type { UmbExtensionManifestKind } from '@umbraco-cms/backoffice/extension-api';
export const customButtonKind: UmbExtensionManifestKind = {
type: 'kind',
alias: 'My.Kind.HeaderAppButton',
matchType: 'headerApp',
matchKind: 'button',
manifest: {
elementName: 'umb-header-app-button',
},
};
const manifest = {
type: 'headerApp',
kind: 'button', // Uses the 'button' kind
name: 'My Header App',
alias: 'My.HeaderApp',
meta: {
label: 'My App',
icon: 'icon-heart',
href: '/my-app',
},
};
export const cardKind: UmbExtensionManifestKind = {
type: 'kind',
alias: 'My.Kind.DashboardCard',
matchType: 'dashboard',
matchKind: 'card',
manifest: {
elementName: 'my-dashboard-card',
meta: {
// Default meta properties
size: 'medium',
color: 'default',
},
},
};
// Extension inherits defaults, can override
const dashboard = {
type: 'dashboard',
kind: 'card',
alias: 'My.Dashboard',
name: 'My Dashboard',
meta: {
label: 'Stats',
pathname: 'stats',
// size and color inherited from kind
},
};
That's it! Always fetch fresh docs, keep examples minimal, generate complete working code.