Skip to content
This repository was archived by the owner on Nov 6, 2025. It is now read-only.

Commit 87f867c

Browse files
committed
umb-ref-manifest + icons
1 parent 6d9611f commit 87f867c

File tree

533 files changed

+642
-568
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

533 files changed

+642
-568
lines changed

package-lock.json

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,7 +252,7 @@
252252
"eslint-plugin-wc": "^2.1.0",
253253
"glob": "^11.0.0",
254254
"globals": "^15.8.0",
255-
"lucide-static": "^0.408.0",
255+
"lucide-static": "^0.424.0",
256256
"msw": "^1.3.2",
257257
"playwright-msw": "^3.0.1",
258258
"prettier": "3.3.3",

src/packages/block/block-type/components/block-type-custom-view-guide/block-type-custom-view-guide.element.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -83,11 +83,7 @@ export class UmbBlockTypeCustomViewGuideElement extends UmbLitElement {
8383
${repeat(
8484
this._manifests,
8585
(x) => x.alias,
86-
(x) => html`
87-
<uui-ref-node standalone name=${x.name} detail=${x.alias}>
88-
<umb-icon slot="icon" name=${'icon-flowerpot'}></umb-icon
89-
></uui-ref-node>
90-
`,
86+
(x) => html` <umb-ref-manifest standalone .manifest=${x}></umb-ref-manifest> `,
9187
)}
9288
</div>`
9389
: html`No custom view matches the current block editor type and content type.`;
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
export * from './extension-slot/index.js';
22
export * from './extension-with-api-slot/index.js';
3+
export * from './ref-manifest/ref-manifest.element.js';
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
import { UUIIconRequestEvent, UUIRefNodeElement } from '@umbraco-cms/backoffice/external/uui';
2+
import { html, customElement, property, state } from '@umbraco-cms/backoffice/external/lit';
3+
import { UmbElementMixin } from '@umbraco-cms/backoffice/element-api';
4+
import type { ManifestBase } from '@umbraco-cms/backoffice/extension-api';
5+
6+
@customElement('umb-ref-manifest')
7+
export class UmbRefManifestElement extends UmbElementMixin(UUIRefNodeElement) {
8+
@property({ type: Object, attribute: false })
9+
public get manifest(): ManifestBase | undefined {
10+
return undefined;
11+
}
12+
public set manifest(value: ManifestBase | undefined) {
13+
this._alias = value?.alias;
14+
this.name = value?.name ?? '';
15+
}
16+
17+
@state()
18+
private _alias?: string;
19+
20+
override connectedCallback() {
21+
super.connectedCallback();
22+
23+
this.#requestIconSVG('icon-umb-manifest');
24+
}
25+
26+
/* This is a bit stupid, but because this element extends from uui-ref-node, it only accepts the icon via the icon slot.
27+
** Instead we overwrite the fallbackIcon property which requires a SVG... */
28+
#requestIconSVG(iconName: string) {
29+
if (iconName !== '' && iconName !== null) {
30+
const event = new UUIIconRequestEvent(UUIIconRequestEvent.ICON_REQUEST, {
31+
detail: { iconName: iconName },
32+
});
33+
this.dispatchEvent(event);
34+
if (event.icon !== null) {
35+
event.icon.then((iconSvg: string) => {
36+
this.fallbackIcon = iconSvg;
37+
this.requestUpdate('fallbackIcon');
38+
});
39+
}
40+
}
41+
}
42+
43+
protected override renderDetail() {
44+
return html`<small id="detail">${this._alias}<slot name="detail"></slot></small>`;
45+
}
46+
}
47+
48+
declare global {
49+
interface HTMLElementTagNameMap {
50+
'umb-ref-manifest': UmbRefManifestElement;
51+
}
52+
}

src/packages/core/icon-registry/icon-dictionary.json

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -139,15 +139,15 @@
139139
},
140140
{
141141
"name": "icon-bar-chart",
142-
"file": "bar-chart-2.svg"
142+
"file": "chart-no-axes-column.svg"
143143
},
144144
{
145145
"name": "icon-barcode",
146146
"file": "scan-barcode.svg"
147147
},
148148
{
149149
"name": "icon-bars",
150-
"file": "bar-chart.svg"
150+
"file": "chart-no-axes-column-increasing.svg"
151151
},
152152
{
153153
"name": "icon-battery-full",
@@ -376,11 +376,11 @@
376376
},
377377
{
378378
"name": "icon-chart-curve",
379-
"file": "area-chart.svg"
379+
"file": "chart-no-axes-combined.svg"
380380
},
381381
{
382382
"name": "icon-chart",
383-
"file": "line-chart.svg"
383+
"file": "chart-line.svg"
384384
},
385385
{
386386
"name": "icon-chat-active",
@@ -653,7 +653,7 @@
653653
},
654654
{
655655
"name": "icon-defrag",
656-
"file": "scatter-chart.svg"
656+
"file": "chart-scatter.svg"
657657
},
658658
{
659659
"name": "icon-delete-key",
@@ -1664,7 +1664,7 @@
16641664
},
16651665
{
16661666
"name": "icon-pie-chart",
1667-
"file": "pie-chart.svg"
1667+
"file": "chart-pie.svg"
16681668
},
16691669
{
16701670
"name": "icon-piggy-bank",
@@ -2447,6 +2447,10 @@
24472447
{
24482448
"name": "icon-database",
24492449
"file": "database.svg"
2450+
},
2451+
{
2452+
"name": "icon-umb-manifest",
2453+
"file": "puzzle.svg"
24502454
}
24512455
],
24522456
"simpleIcons": [

src/packages/core/icon-registry/icons.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2099,6 +2099,10 @@ name: "icon-database",
20992099

21002100
path: () => import("./icons/icon-database.js"),
21012101
},{
2102+
name: "icon-umb-manifest",
2103+
2104+
path: () => import("./icons/icon-umb-manifest.js"),
2105+
},{
21022106
name: "icon-facebook",
21032107

21042108
path: () => import("./icons/icon-facebook.js"),

src/packages/core/icon-registry/icons/icon-activity.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
export default `<!-- @license lucide-static v0.408.0 - ISC -->
1+
export default `<!-- @license lucide-static v0.424.0 - ISC -->
22
<svg
33
class="lucide lucide-activity"
44
xmlns="http://www.w3.org/2000/svg"

src/packages/core/icon-registry/icons/icon-add.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
export default `<!-- @license lucide-static v0.408.0 - ISC -->
1+
export default `<!-- @license lucide-static v0.424.0 - ISC -->
22
<svg
33
class="lucide lucide-plus"
44
xmlns="http://www.w3.org/2000/svg"

src/packages/core/icon-registry/icons/icon-addressbook.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
export default `<!-- @license lucide-static v0.408.0 - ISC -->
1+
export default `<!-- @license lucide-static v0.424.0 - ISC -->
22
<svg
33
class="lucide lucide-book-user"
44
xmlns="http://www.w3.org/2000/svg"

0 commit comments

Comments
 (0)