mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-10 19:06:36 +00:00
Change wording from add section to create section (#19978)
* Rename add section to create section * update function name
This commit is contained in:
parent
0c6bf701c7
commit
1b7742ef7f
@ -119,13 +119,13 @@ export class SectionsView extends LitElement implements LovelaceViewElement {
|
|||||||
${editMode
|
${editMode
|
||||||
? html`
|
? html`
|
||||||
<button
|
<button
|
||||||
class="add"
|
class="create"
|
||||||
@click=${this._addSection}
|
@click=${this._createSection}
|
||||||
aria-label=${this.hass.localize(
|
aria-label=${this.hass.localize(
|
||||||
"ui.panel.lovelace.editor.section.add_section"
|
"ui.panel.lovelace.editor.section.create_section"
|
||||||
)}
|
)}
|
||||||
.title=${this.hass.localize(
|
.title=${this.hass.localize(
|
||||||
"ui.panel.lovelace.editor.section.add_section"
|
"ui.panel.lovelace.editor.section.create_section"
|
||||||
)}
|
)}
|
||||||
>
|
>
|
||||||
<ha-svg-icon .path=${mdiViewGridPlus}></ha-svg-icon>
|
<ha-svg-icon .path=${mdiViewGridPlus}></ha-svg-icon>
|
||||||
@ -137,7 +137,7 @@ export class SectionsView extends LitElement implements LovelaceViewElement {
|
|||||||
`;
|
`;
|
||||||
}
|
}
|
||||||
|
|
||||||
private _addSection(): void {
|
private _createSection(): void {
|
||||||
const newConfig = addSection(this.lovelace!.config, this.index!, {
|
const newConfig = addSection(this.lovelace!.config, this.index!, {
|
||||||
type: "grid",
|
type: "grid",
|
||||||
cards: [],
|
cards: [],
|
||||||
@ -303,7 +303,7 @@ export class SectionsView extends LitElement implements LovelaceViewElement {
|
|||||||
padding: 8px;
|
padding: 8px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.add {
|
.create {
|
||||||
margin-top: calc(66px + 8px);
|
margin-top: calc(66px + 8px);
|
||||||
outline: none;
|
outline: none;
|
||||||
background: none;
|
background: none;
|
||||||
@ -316,7 +316,7 @@ export class SectionsView extends LitElement implements LovelaceViewElement {
|
|||||||
box-sizing: content-box;
|
box-sizing: content-box;
|
||||||
}
|
}
|
||||||
|
|
||||||
.add:focus {
|
.create:focus {
|
||||||
border: 2px solid var(--primary-color);
|
border: 2px solid var(--primary-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5199,7 +5199,7 @@
|
|||||||
"section": {
|
"section": {
|
||||||
"unnamed_section": "Unnamed section",
|
"unnamed_section": "Unnamed section",
|
||||||
"add_card": "[%key:ui::panel::lovelace::editor::edit_card::add%]",
|
"add_card": "[%key:ui::panel::lovelace::editor::edit_card::add%]",
|
||||||
"add_section": "Add section"
|
"create_section": "Create section"
|
||||||
},
|
},
|
||||||
"delete_section": {
|
"delete_section": {
|
||||||
"title": "Delete section",
|
"title": "Delete section",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user