feat: expose decor default color in main toolbar

Issue: #360
User-Visible: yes
This commit is contained in:
Sergey Matyunin
2026-08-29 11:48:50 +03:00
parent e21f02b295
commit 822c8000a2
24 changed files with 323 additions and 148 deletions
+9
View File
@@ -5409,6 +5409,15 @@ public _renderDecorBar(): TemplateResult {
</button>`,
)}
${this.host._editorToolbarGroups.map((group) => this._renderEditorGroupLauncher(group))}
<hp-color-opacity class="decor-default-color"
.label=${this.host._t('decor.color')}
.color=${this.host._decorStyle.color}
.opacity=${this.host._decorStyle.opacity}
.opacityLabel=${this.host._t('space.opacity')}
.pickerLabels=${this.host._colorPickerLabels}
@hp-color-opacity-change=${(e: CustomEvent<{ color: string; opacity: number }>) =>
(this.host._decorStyle = { ...this.host._decorStyle, ...e.detail })}>
</hp-color-opacity>
<button class="btn ghost" @click=${() => this._undoGeometry()} ?disabled=${!undoName}
title=${undoName ? this.host._t('history.undo_named', { name: undoName }) : this.host._t('history.undo_empty')}>
<ha-icon icon="mdi:undo-variant"></ha-icon>${this.host._t('history.undo')}