Creates and configures admin dashboard widgets in Orchard Core, covering DashboardPart, widget content types, recipes, permissions, and template customization.
Ships in orchardcore. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
You are an Orchard Core expert. Generate admin dashboard widgets, content types, and template configurations for Orchard Core.
OrchardCore.AdminDashboard for admin dashboard widget support. It replaces the default /admin landing page with the widget dashboard.DashboardWidget stereotype, so they can be edited, secured, versioned, and localized like any other content.HtmlDashboardWidget (an HtmlBodyPart body for links or notes), ContentsMetadata, and ContentsTags. The module also ships a dashboard-widgets-samples recipe.DashboardWidget.DashboardPart is added automatically to every DashboardWidget type and stores Position, Width, and Height.Position, Width, and Height are double values (defaults 0, 1.0, 1.0). The grid has 6 columns on large screens (3 on tablets, 1 on phones), so a Width of 1 is one sixth and 6 is the full width; use whole numbers from 1 to 6 for Width and Height.Position and resize it to change Width and Height; both the latest and published versions are updated.ManageAdminDashboard permission is required to manage (add/edit/arrange/remove) widgets; it implies AccessAdminDashboard.AccessAdminDashboard permission is required for users without ManageAdminDashboard to view the dashboard. By default it is granted to Editor, Moderator, Author, and Contributor; Administrator has both.AccessAdminDashboard also need ViewContent or the applicable per-content-type view permission to see a widget.DashboardWidget-{ContentType}.DetailAdmin.cshtml.{
"steps": [
{
"name": "Feature",
"enable": [
"OrchardCore.AdminDashboard"
],
"disable": []
}
]
}
| Property | Type | Range | Description |
|---|---|---|---|
Position | Numeric | Any | Controls the widget's order on the page. Lower values appear first. |
Width | Double | 1 to 6 | Grid-column span; 1 is one sixth of a large screen, 6 the full width. Default 1.0. Not validated server-side. |
Height | Double | 1 to 6 | Grid-row span. Default 1.0. Not validated server-side. |
{
"steps": [
{
"name": "ContentDefinition",
"ContentTypes": [
{
"Name": "{{WidgetTypeName}}",
"DisplayName": "{{WidgetDisplayName}}",
"Settings": {
"ContentTypeSettings": {
"Stereotype": "DashboardWidget",
"Creatable": false,
"Listable": false,
"Draftable": true
}
},
"ContentTypePartDefinitionRecords": [
{
"PartName": "TitlePart",
"Name": "TitlePart",
"Settings": {
"ContentTypePartSettings": {
"Position": "0"
}
}
},
{
"PartName": "HtmlBodyPart",
"Name": "HtmlBodyPart",
"Settings": {
"ContentTypePartSettings": {
"Position": "1"
}
}
}
]
}
]
}
]
}
using OrchardCore.ContentManagement.Metadata;
using OrchardCore.ContentManagement.Metadata.Settings;
using OrchardCore.Data.Migration;
namespace MyModule;
public sealed class DashboardMigrations : DataMigration
{
private readonly IContentDefinitionManager _contentDefinitionManager;
public DashboardMigrations(IContentDefinitionManager contentDefinitionManager)
{
_contentDefinitionManager = contentDefinitionManager;
}
public async Task<int> CreateAsync()
{
await _contentDefinitionManager.AlterTypeDefinitionAsync("{{WidgetTypeName}}", type => type
.Stereotype("DashboardWidget")
.DisplayedAs("{{WidgetDisplayName}}")
.WithPart("TitlePart", part => part
.WithPosition("0")
)
.WithPart("HtmlBodyPart", part => part
.WithPosition("1")
)
);
return 1;
}
}
{
"steps": [
{
"name": "Content",
"data": [
{
"ContentItemId": "{{WidgetContentItemId}}",
"ContentType": "{{WidgetTypeName}}",
"DisplayText": "{{WidgetTitle}}",
"Latest": true,
"Published": true,
"DashboardPart": {
"Position": 0.0,
"Width": 2.0,
"Height": 1.0
},
"TitlePart": {
"Title": "{{WidgetTitle}}"
},
"HtmlBodyPart": {
"Html": "<p>{{WidgetContent}}</p>"
}
}
]
}
]
}
Create a template named DashboardWidget-{{ContentType}}.DetailAdmin.cshtml where {{ContentType}} is the technical name of the content type:
<div class="card h-100 @string.Join(' ', Model.Classes.ToArray())">
@if (Model.Header != null || Model.Leading != null || Model.ActionsMenu != null)
{
<div class="card-header">
@await DisplayAsync(Model.Leading)
@await DisplayAsync(Model.Header)
@if (Model.ActionsMenu != null)
{
<div class="btn-group float-end" title="@T["Actions"]">
<button type="button" class="btn btn-sm" data-bs-toggle="dropdown"
aria-haspopup="true" aria-expanded="false" aria-label="@T["Actions"]">
<i class="fa-solid fa-ellipsis-v" aria-hidden="true"></i>
</button>
<div class="actions-menu dropdown-menu">
@await DisplayAsync(Model.ActionsMenu)
</div>
</div>
}
</div>
}
<div class="dashboard-body-container card-body p-2 h-100">
@if (Model.Tags != null || Model.Meta != null)
{
<div class="dashboard-meta">
@await DisplayAsync(Model.Meta)
@await DisplayAsync(Model.Tags)
</div>
}
@await DisplayAsync(Model.Content)
</div>
@if (Model.Footer != null)
{
<div class="card-footer">
@await DisplayAsync(Model.Footer)
</div>
}
</div>
| Permission | Description |
|---|---|
ManageAdminDashboard | Add, edit, arrange, and remove dashboard widgets. Implies AccessAdminDashboard. |
AccessAdminDashboard | View the admin dashboard when the user does not manage it. Static member OrchardCore.AdminDashboard.Permissions.AccessAdminDashboard. |
ViewContent | Required, with AccessAdminDashboard, unless a per-content-type view permission grants access. |
using OrchardCore.ContentManagement.Metadata;
using OrchardCore.ContentManagement.Metadata.Settings;
using OrchardCore.Data.Migration;
namespace MyModule;
public sealed class StatsDashboardMigrations : DataMigration
{
private readonly IContentDefinitionManager _contentDefinitionManager;
public StatsDashboardMigrations(IContentDefinitionManager contentDefinitionManager)
{
_contentDefinitionManager = contentDefinitionManager;
}
public async Task<int> CreateAsync()
{
await _contentDefinitionManager.AlterPartDefinitionAsync("StatsWidgetPart", part => part
.WithField("StatLabel", field => field
.OfType("TextField")
.WithDisplayName("Stat Label")
.WithPosition("0")
)
.WithField("StatValue", field => field
.OfType("NumericField")
.WithDisplayName("Stat Value")
.WithPosition("1")
)
);
await _contentDefinitionManager.AlterTypeDefinitionAsync("StatsWidget", type => type
.Stereotype("DashboardWidget")
.DisplayedAs("Stats Widget")
.WithPart("TitlePart", part => part.WithPosition("0"))
.WithPart("StatsWidgetPart", part => part.WithPosition("1"))
);
return 1;
}
}
ManageAdminDashboard permission./admin).The feature registers OrchardCore.AdminDashboard.Services.DashboardBreadcrumbProvider with services.AddBreadcrumbProvider<DashboardBreadcrumbProvider>(). On admin requests with a visible trail it inserts a localized Dashboard ancestor (ID Dashboard, URL "~/" + AdminOptions.AdminUrlPrefix, permission AccessAdminDashboard) at index 0, unless the trail is named Dashboard or already has a Dashboard ancestor. So Manage Content › Edit Article becomes Dashboard › Manage Content › Edit Article. Users without access see the node as plain text; front-end trails and hidden admin trails (Show breadcrumb off) are not affected.
The dashboard page declares its own trail, which prevents a duplicate ancestor:
<breadcrumb name="Dashboard" title="@T["Dashboard"]" />
Restyle its current node with BreadcrumbItem-Dashboard-Title.cshtml (or BreadcrumbItem-Dashboard-Title.DetailAdmin.cshtml). See orchardcore-breadcrumbs for the provider contract.
When OrchardCore.AdminDashboard is disabled, /admin renders the AdminDashboard shape of OrchardCore.Admin, whose AdminDashboardContent child shape collects positioned content from shape table providers (see orchardcore-admin).
What SKILL.md sets; muted values are Claude Code's defaults
/orchardcore:orchardcore-admin-dashboardfrom orchardcore
npx claudepluginhub crestapps/crestapps.agentskills --plugin orchardcore140 skills in this plugin
/orchardcore-adminGuidance for the Orchard Core admin panel, including admin controllers and routes, admin menu registration with AdminNavigationProvider, ocat editor forms grouped in cards, admin pages rendering Model.Editor, the UI text casing standard, TheAdmin layout and menu colors, admin branding, the Navbar shape, the Ctrl+K quick navigation palette and QuickNavigationSource, AdminSettings such as MenuBehavior, ShowBreadcrumb, DisplayQuickNavigation, DisplayTitlesInTopbar and ActionsLayout, the AdminDashboard shape, settings pages, and admin filters and zones. Use this skill when requests mention the Orchard Core admin panel, TheAdmin, admin controllers, admin menu registration, an icon on an admin menu item, the AdminSettings recipe step, quick navigation, navigation menu behavior, the admin URL prefix, UI text casing. Strong matches include OrchardCore.Admin, AdminSettings, AdminPermissions, AdminOptions, AdminAttribute, SiteDisplayDriver, IDisplayManager./orchardcore-admin-edit-viewsSkill for writing Orchard Core admin editor views with the ocat CSS classes and cards. Covers Edit views for content parts and fields, field editor variants, part, field and site settings editors, Fields.Edit views, admin pages rendering Model.Editor built with IDisplayManager, the ocat classes and their layout rules, label associations and group captions, part and field wrapper classes, validation, hints and the Hint_Admin shape, cards declared in placement and the Card and CardContainer shapes, split editor shapes, tabs and columns, the edit page action bar, the horizontal form layout, and the UI text casing standard. Use this skill when requests mention Orchard Core admin edit views, admin forms, grouping fields in cards, Edit.cshtml, Fields.Edit.cshtml, Settings.Edit.cshtml, ocat classes, label casing, or field hints. Strong matches include ocat-wrapper, ocat-card, Hint_Admin, PlacementLocationBuilder, IDisplayManager, ContentPartDisplayDriver, SiteDisplayDriver.Other plugins' skills for the same job