renaming and added test layout
This commit is contained in:
@@ -4,8 +4,7 @@ import { customElement } from 'lit/decorators.js';
|
||||
import { ifDefined } from 'lit/directives/if-defined.js';
|
||||
import type { ManifestCollectionBulkAction } from '@umbraco-cms/models';
|
||||
|
||||
//TODO: Should be renamed to a specific usecase. eg. umb-media-collection-bulk-action
|
||||
@customElement('umb-collection-bulk-action')
|
||||
@customElement('umb-collection-bulk-action-media-test')
|
||||
export class UmbCollectionBulkActionElement extends LitElement {
|
||||
static styles = [UUITextStyles, css``];
|
||||
|
||||
@@ -21,6 +20,6 @@ export class UmbCollectionBulkActionElement extends LitElement {
|
||||
|
||||
declare global {
|
||||
interface HTMLElementTagNameMap {
|
||||
'umb-collection-bulk-action': UmbCollectionBulkActionElement;
|
||||
'umb-collection-bulk-action-media-test': UmbCollectionBulkActionElement;
|
||||
}
|
||||
}
|
||||
@@ -5,8 +5,8 @@ export const manifests: Array<ManifestCollectionBulkAction> = [
|
||||
type: 'collectionBulkAction',
|
||||
alias: 'Umb.CollectionBulkAction.Test',
|
||||
name: 'Test',
|
||||
elementName: 'umb-collection-bulk-action',
|
||||
loader: () => import('./collection-bulk-action-test.element'),
|
||||
elementName: 'umb-collection-bulk-action-media-test',
|
||||
loader: () => import('./collection-bulk-action-media-test.element'),
|
||||
weight: 600,
|
||||
meta: {
|
||||
label: 'Test',
|
||||
|
||||
@@ -7,9 +7,8 @@ import { UmbMediaStore } from '@umbraco-cms/stores/media/media.store';
|
||||
import { UmbContextConsumerMixin } from '@umbraco-cms/context-api';
|
||||
import { UmbObserverMixin } from '@umbraco-cms/observable-api';
|
||||
|
||||
//TODO: Should be renamed to a specific usecase. eg. umb-media-collection-layout-grid
|
||||
@customElement('umb-collection-layout-grid')
|
||||
export class UmbCollectionLayoutGridElement extends UmbContextConsumerMixin(UmbObserverMixin(LitElement)) {
|
||||
@customElement('umb-collection-layout-media-grid')
|
||||
export class UmbCollectionLayoutMediaGridElement extends UmbContextConsumerMixin(UmbObserverMixin(LitElement)) {
|
||||
static styles = [
|
||||
UUITextStyles,
|
||||
css`
|
||||
@@ -123,6 +122,6 @@ export class UmbCollectionLayoutGridElement extends UmbContextConsumerMixin(UmbO
|
||||
|
||||
declare global {
|
||||
interface HTMLElementTagNameMap {
|
||||
'umb-collection-layout-grid': UmbCollectionLayoutGridElement;
|
||||
'umb-collection-layout-media-grid': UmbCollectionLayoutMediaGridElement;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
import { UUITextStyles } from '@umbraco-ui/uui-css';
|
||||
import { css, html, LitElement } from 'lit';
|
||||
import { customElement } from 'lit/decorators.js';
|
||||
|
||||
@customElement('umb-collection-layout-media-table')
|
||||
export class UmbCollectionLayoutMediaTableElement extends LitElement {
|
||||
static styles = [UUITextStyles, css``];
|
||||
|
||||
render() {
|
||||
return html`<h1>umb-collection-layout-media-table</h1>`;
|
||||
}
|
||||
}
|
||||
|
||||
declare global {
|
||||
interface HTMLElementTagNameMap {
|
||||
'umb-collection-layout-media-table': UmbCollectionLayoutMediaTableElement;
|
||||
}
|
||||
}
|
||||
@@ -2,17 +2,17 @@ import { UUITextStyles } from '@umbraco-ui/uui-css';
|
||||
import { css, html, LitElement } from 'lit';
|
||||
import { customElement } from 'lit/decorators.js';
|
||||
|
||||
@customElement('umb-collection-layout-table')
|
||||
export class UmbCollectionLayoutTableElement extends LitElement {
|
||||
@customElement('umb-collection-layout-media-test')
|
||||
export class UmbCollectionLayoutMediaTestElement extends LitElement {
|
||||
static styles = [UUITextStyles, css``];
|
||||
|
||||
render() {
|
||||
return html`umb-collection-layout-table`;
|
||||
return html`umb-collection-layout-media-test`;
|
||||
}
|
||||
}
|
||||
|
||||
declare global {
|
||||
interface HTMLElementTagNameMap {
|
||||
'umb-collection-layout-table': UmbCollectionLayoutTableElement;
|
||||
'umb-collection-layout-media-test': UmbCollectionLayoutMediaTestElement;
|
||||
}
|
||||
}
|
||||
@@ -5,9 +5,9 @@ export const manifests: Array<ManifestCollectionLayout> = [
|
||||
type: 'collectionLayout',
|
||||
alias: 'Umb.CollectionLayout.Grid',
|
||||
name: 'Grid',
|
||||
elementName: 'umb-collection-layout-grid',
|
||||
loader: () => import('./collection-layout-grid.element'),
|
||||
weight: 100,
|
||||
elementName: 'umb-collection-layout-media-grid',
|
||||
loader: () => import('./collection-layout-media-grid.element'),
|
||||
weight: 300,
|
||||
meta: {
|
||||
label: 'Grid',
|
||||
icon: 'umb:grid',
|
||||
@@ -19,14 +19,28 @@ export const manifests: Array<ManifestCollectionLayout> = [
|
||||
type: 'collectionLayout',
|
||||
alias: 'Umb.CollectionLayout.Table',
|
||||
name: 'Table',
|
||||
elementName: 'umb-collection-layout-table',
|
||||
loader: () => import('./collection-layout-table.element'),
|
||||
weight: 100,
|
||||
elementName: 'umb-collection-layout-media-table',
|
||||
loader: () => import('./collection-layout-media-table.element'),
|
||||
weight: 200,
|
||||
meta: {
|
||||
label: 'Table',
|
||||
icon: 'umb:table',
|
||||
icon: 'umb:box',
|
||||
entityType: 'media',
|
||||
pathName: 'table',
|
||||
},
|
||||
},
|
||||
{
|
||||
type: 'collectionLayout',
|
||||
alias: 'Umb.CollectionLayout.Test',
|
||||
name: 'Test',
|
||||
elementName: 'umb-collection-layout-media-test',
|
||||
loader: () => import('./collection-layout-media-test.element'),
|
||||
weight: 100,
|
||||
meta: {
|
||||
label: 'Test',
|
||||
icon: 'umb:newspaper',
|
||||
entityType: 'media',
|
||||
pathName: 'test',
|
||||
},
|
||||
},
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user