rename node property to content property
This commit is contained in:
@@ -3,7 +3,7 @@ import './components/backoffice-header.element';
|
||||
import './components/backoffice-main.element';
|
||||
import './components/backoffice-modal-container.element';
|
||||
import './components/backoffice-notification-container.element';
|
||||
import './components/node-property/node-property.element';
|
||||
import './components/content-property/content-property.element';
|
||||
import './components/table/table.element';
|
||||
import './components/shared/code-block.element';
|
||||
import './sections/shared/section-main/section-main.element';
|
||||
|
||||
@@ -5,16 +5,15 @@ import { customElement, property, state } from 'lit/decorators.js';
|
||||
import { EMPTY, of, switchMap } from 'rxjs';
|
||||
|
||||
import { UmbDataTypesStore } from '../../../core/stores/data-types/data-types.store';
|
||||
import { NodeProperty } from '../../../core/mocks/data/node.data';
|
||||
import { UmbObserverMixin } from '@umbraco-cms/observable-api';
|
||||
import type { ManifestTypes } from '@umbraco-cms/models';
|
||||
import type { ContentProperty, ManifestTypes } from '@umbraco-cms/models';
|
||||
import { umbExtensionsRegistry } from '@umbraco-cms/extensions-registry';
|
||||
import { UmbContextConsumerMixin } from '@umbraco-cms/context-api';
|
||||
|
||||
import '../entity-property/entity-property.element';
|
||||
|
||||
@customElement('umb-node-property')
|
||||
export class UmbNodePropertyElement extends UmbContextConsumerMixin(UmbObserverMixin(LitElement)) {
|
||||
@customElement('umb-content-property')
|
||||
export class UmbContentPropertyElement extends UmbContextConsumerMixin(UmbObserverMixin(LitElement)) {
|
||||
static styles = [
|
||||
UUITextStyles,
|
||||
css`
|
||||
@@ -24,12 +23,12 @@ export class UmbNodePropertyElement extends UmbContextConsumerMixin(UmbObserverM
|
||||
`,
|
||||
];
|
||||
|
||||
private _property?: NodeProperty;
|
||||
private _property?: ContentProperty;
|
||||
@property({ type: Object, attribute: false })
|
||||
public get property(): NodeProperty | undefined {
|
||||
public get property(): ContentProperty | undefined {
|
||||
return this._property;
|
||||
}
|
||||
public set property(value: NodeProperty | undefined) {
|
||||
public set property(value: ContentProperty | undefined) {
|
||||
this._property = value;
|
||||
this._observeDataType();
|
||||
}
|
||||
@@ -86,6 +85,6 @@ export class UmbNodePropertyElement extends UmbContextConsumerMixin(UmbObserverM
|
||||
|
||||
declare global {
|
||||
interface HTMLElementTagNameMap {
|
||||
'umb-node-property': UmbNodePropertyElement;
|
||||
'umb-content-property': UmbContentPropertyElement;
|
||||
}
|
||||
}
|
||||
@@ -7,7 +7,7 @@ import { UmbContextConsumerMixin } from '@umbraco-cms/context-api';
|
||||
import { UmbObserverMixin } from '@umbraco-cms/observable-api';
|
||||
import type { ContentProperty, ContentPropertyData, DocumentDetails, MediaDetails } from '@umbraco-cms/models';
|
||||
|
||||
import '../../../../../components/node-property/node-property.element';
|
||||
import '../../../../../components/content-property/content-property.element';
|
||||
|
||||
@customElement('umb-editor-view-content-edit')
|
||||
export class UmbEditorViewContentEditElement extends UmbContextConsumerMixin(UmbObserverMixin(LitElement)) {
|
||||
@@ -52,9 +52,9 @@ export class UmbEditorViewContentEditElement extends UmbContextConsumerMixin(Umb
|
||||
<uui-box>
|
||||
${this._properties.map(
|
||||
(property: ContentProperty) => html`
|
||||
<umb-node-property
|
||||
<umb-content-property
|
||||
.property=${property}
|
||||
.value=${this._data.find((data) => data.alias === property.alias)?.value}></umb-node-property>
|
||||
.value=${this._data.find((data) => data.alias === property.alias)?.value}></umb-content-property>
|
||||
`
|
||||
)}
|
||||
</uui-box>
|
||||
|
||||
Reference in New Issue
Block a user