clean up
This commit is contained in:
@@ -53,7 +53,6 @@ export class UmbPropertyEditorUIBlockGridElement extends UmbLitElement implement
|
||||
@state()
|
||||
private _layoutColumns?: number;
|
||||
|
||||
#debounceChangeEvent?: boolean;
|
||||
@property({ attribute: false })
|
||||
public set value(value: UmbBlockGridValueModel | undefined) {
|
||||
const buildUpValue: Partial<UmbBlockGridValueModel> = value ? { ...value } : {};
|
||||
|
||||
@@ -121,17 +121,6 @@ export class UmbPropertyEditorUIBlockListElement extends UmbLitElement implement
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
/*
|
||||
this.consumeContext(UMB_PROPERTY_CONTEXT, (propertyContext) => {
|
||||
this.observe(
|
||||
propertyContext?.alias,
|
||||
(alias) => {
|
||||
this.#catalogueModal.setUniquePathValue('propertyAlias', alias);
|
||||
},
|
||||
'observePropertyAlias',
|
||||
);
|
||||
});
|
||||
*/
|
||||
this.observe(this.#entriesContext.layoutEntries, (layouts) => {
|
||||
this._layouts = layouts;
|
||||
// Update sorter.
|
||||
@@ -167,34 +156,10 @@ export class UmbPropertyEditorUIBlockListElement extends UmbLitElement implement
|
||||
this.observe(this.#entriesContext.catalogueRouteBuilder, (routeBuilder) => {
|
||||
this._catalogueRouteBuilder = routeBuilder;
|
||||
});
|
||||
|
||||
/*
|
||||
this.#catalogueModal = new UmbModalRouteRegistrationController(this, UMB_BLOCK_CATALOGUE_MODAL)
|
||||
.addUniquePaths(['propertyAlias'])
|
||||
.addAdditionalPath(':view/:index')
|
||||
.onSetup((routingInfo) => {
|
||||
const index = routingInfo.index ? parseInt(routingInfo.index) : -1;
|
||||
return {
|
||||
data: {
|
||||
blocks: this._blocks ?? [],
|
||||
openClipboard: routingInfo.view === 'clipboard',
|
||||
blockOriginData: { index: index },
|
||||
},
|
||||
};
|
||||
})
|
||||
.observeRouteBuilder((routeBuilder) => {
|
||||
this._catalogueRouteBuilder = routeBuilder;
|
||||
});
|
||||
*/
|
||||
}
|
||||
|
||||
#debounceChangeEvent?: boolean;
|
||||
#fireChangeEvent = async () => {
|
||||
if (this.#debounceChangeEvent) return;
|
||||
this.#debounceChangeEvent = true;
|
||||
await Promise.resolve();
|
||||
#fireChangeEvent = () => {
|
||||
this.dispatchEvent(new UmbPropertyValueChangeEvent());
|
||||
this.#debounceChangeEvent = false;
|
||||
};
|
||||
|
||||
render() {
|
||||
|
||||
Reference in New Issue
Block a user