Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/components/ha-related-items.ts
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ export class HaRelatedItems extends SubscribeMixin(LitElement) {
href="/config/integrations/config_entry/${relatedConfigEntryId}"
@click=${this._close}
>
${this.hass.localize(`component.${entry.domain}.config.title`)}:
${this.hass.localize(`component.${entry.domain}.title`)}:
${entry.title}
</a>
`;
Expand Down
2 changes: 1 addition & 1 deletion src/data/config_flow.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ export const localizeConfigFlowTitle = (
const placeholders = flow.context.title_placeholders || {};
const placeholderKeys = Object.keys(placeholders);
if (placeholderKeys.length === 0) {
return localize(`component.${flow.handler}.config.title`);
return localize(`component.${flow.handler}.title`);
}
const args: string[] = [];
placeholderKeys.forEach((key) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ class DialogConfigEntrySystemOptions extends LitElement {
"ui.dialogs.config_entry_system_options.title",
"integration",
this.hass.localize(
`component.${this._params.entry.domain}.config.title`
`component.${this._params.entry.domain}.title`
) || this._params.entry.domain
)}
</h2>
Expand Down Expand Up @@ -98,7 +98,7 @@ class DialogConfigEntrySystemOptions extends LitElement {
"ui.dialogs.config_entry_system_options.enable_new_entities_description",
"integration",
this.hass.localize(
`component.${this._params.entry.domain}.config.title`
`component.${this._params.entry.domain}.title`
) || this._params.entry.domain
)}
</p>
Expand Down
4 changes: 2 additions & 2 deletions src/dialogs/config-flow/show-dialog-config-flow.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ export const showConfigFlowDialog = (
getConfigFlowHandlers(hass).then((handlers) =>
handlers.sort((handlerA, handlerB) =>
caseInsensitiveCompare(
hass.localize(`component.${handlerA}.config.title`),
hass.localize(`component.${handlerB}.config.title`)
hass.localize(`component.${handlerA}.title`),
hass.localize(`component.${handlerB}.title`)
)
)
),
Expand Down
3 changes: 1 addition & 2 deletions src/dialogs/config-flow/step-flow-pick-handler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,7 @@ class StepFlowPickHandler extends LitElement {
private _getHandlers = memoizeOne((h: string[], filter?: string) => {
const handlers: HandlerObj[] = h.map((handler) => {
return {
name:
this.hass.localize(`component.${handler}.config.title`) || handler,
name: this.hass.localize(`component.${handler}.title`) || handler,
slug: handler,
};
});
Expand Down
4 changes: 1 addition & 3 deletions src/onboarding/onboarding-integrations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,7 @@ class OnboardingIntegrations extends LitElement {
// Render discovered and existing entries together sorted by localized title.
const entries: Array<[string, TemplateResult]> = this._entries.map(
(entry) => {
const title = this.hass.localize(
`component.${entry.domain}.config.title`
);
const title = this.hass.localize(`component.${entry.domain}.title`);
return [
title,
html`
Expand Down
5 changes: 2 additions & 3 deletions src/panels/config/devices/ha-config-devices-dashboard.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,9 +115,8 @@ export class HaConfigDeviceDashboard extends LitElement {
.filter((entId) => entId in entryLookup)
.map(
(entId) =>
localize(
`component.${entryLookup[entId].domain}.config.title`
) || entryLookup[entId].domain
localize(`component.${entryLookup[entId].domain}.title`) ||
entryLookup[entId].domain
)
.join(", ")
: "No integration",
Expand Down
5 changes: 2 additions & 3 deletions src/panels/config/devices/ha-devices-data-table.ts
Original file line number Diff line number Diff line change
Expand Up @@ -116,9 +116,8 @@ export class HaDevicesDataTable extends LitElement {
.filter((entId) => entId in entryLookup)
.map(
(entId) =>
localize(
`component.${entryLookup[entId].domain}.config.title`
) || entryLookup[entId].domain
localize(`component.${entryLookup[entId].domain}.title`) ||
entryLookup[entId].domain
)
.join(", ")
: "No integration",
Expand Down
4 changes: 2 additions & 2 deletions src/panels/config/entities/ha-config-entities.ts
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ export class HaConfigEntities extends SubscribeMixin(LitElement) {
return html`
${name}<br />
${entity.entity_id} |
${this.hass.localize(`component.${entity.platform}.config.title`) ||
${this.hass.localize(`component.${entity.platform}.title`) ||
entity.platform}
`;
};
Expand All @@ -190,7 +190,7 @@ export class HaConfigEntities extends SubscribeMixin(LitElement) {
filterable: true,
width: "20%",
template: (platform) =>
this.hass.localize(`component.${platform}.config.title`) || platform,
this.hass.localize(`component.${platform}.title`) || platform,
};
columns.status = statusColumn;

Expand Down
6 changes: 3 additions & 3 deletions src/panels/config/integrations/ha-config-entries-dashboard.ts
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ export class HaConfigManagerDashboard extends LitElement {
<paper-item>
<paper-item-body>
${this.hass.localize(
`component.${item.domain}.config.title`
`component.${item.domain}.title`
)}
</paper-item-body>
<paper-icon-button
Expand Down Expand Up @@ -210,7 +210,7 @@ export class HaConfigManagerDashboard extends LitElement {
<paper-item-body two-line>
<div>
${this.hass.localize(
`component.${item.domain}.config.title`
`component.${item.domain}.title`
)}:
${item.title}
</div>
Expand Down Expand Up @@ -311,7 +311,7 @@ export class HaConfigManagerDashboard extends LitElement {
title: this.hass!.localize(
"ui.panel.config.integrations.ignore.confirm_delete_ignore_title",
"name",
this.hass.localize(`component.${entry.domain}.config.title`)
this.hass.localize(`component.${entry.domain}.title`)
),
text: this.hass!.localize(
"ui.panel.config.integrations.ignore.confirm_delete_ignore"
Expand Down