mirror of
https://github.com/home-assistant/frontend.git
synced 2025-04-25 05:47:20 +00:00
Fix SU sidebar issues (#10757)
This commit is contained in:
parent
cea1a62867
commit
6494177821
@ -370,9 +370,7 @@ class HaSidebar extends LitElement {
|
||||
private _renderPanels(panels: PanelInfo[]) {
|
||||
return panels.map((panel) =>
|
||||
this._renderPanel(
|
||||
panel.url_path === "hassio"
|
||||
? "config/dashboard?focusedPath=hassio"
|
||||
: panel.url_path,
|
||||
panel.url_path,
|
||||
panel.url_path === this.hass.defaultPanel
|
||||
? panel.title || this.hass.localize("panel.states")
|
||||
: this.hass.localize(`panel.${panel.title}`) || panel.title,
|
||||
@ -395,7 +393,11 @@ class HaSidebar extends LitElement {
|
||||
return html`
|
||||
<a
|
||||
aria-role="option"
|
||||
href=${`/${urlPath}`}
|
||||
href=${`/${
|
||||
urlPath === "hassio"
|
||||
? "config/dashboard/?focusedPath=hassio"
|
||||
: urlPath
|
||||
}`}
|
||||
data-panel=${urlPath}
|
||||
tabindex="-1"
|
||||
@mouseenter=${this._itemMouseEnter}
|
||||
|
@ -28,7 +28,7 @@ class HaConfigNavigation extends LitElement {
|
||||
|
||||
@property() public focusedPath?: string | null;
|
||||
|
||||
protected firstUpdated(changedProps: PropertyValues) {
|
||||
protected updated(changedProps: PropertyValues) {
|
||||
super.firstUpdated(changedProps);
|
||||
if (!this.focusedPath) {
|
||||
return;
|
||||
|
Loading…
x
Reference in New Issue
Block a user