refactor: Convert protected methods to private (#2358)

This commit is contained in:
Dermot Duffy
2026-02-19 20:47:59 -08:00
committed by GitHub
parent 529500ed94
commit 0a67df9a25
122 changed files with 815 additions and 829 deletions
+8 -8
View File
@@ -9,11 +9,11 @@ import { arrayify, setOrRemoveAttribute } from '../utils/basic';
import { Timer } from '../utils/timer';
export class StatusBarController {
protected _host: LitElement;
protected _config: StatusBarConfig | null = null;
private _host: LitElement;
private _config: StatusBarConfig | null = null;
protected _popupTimer = new Timer();
protected _items: StatusBarItem[] = [];
private _popupTimer = new Timer();
private _items: StatusBarItem[] = [];
constructor(host: LitElement) {
this._host = host;
@@ -90,7 +90,7 @@ export class StatusBarController {
});
}
protected _getSufficientValue(item: StatusBarItem): string | null {
private _getSufficientValue(item: StatusBarItem): string | null {
/* istanbul ignore else: cannot happen -- @preserve */
if (item.type === 'custom:advanced-camera-card-status-bar-icon') {
return item.icon;
@@ -103,17 +103,17 @@ export class StatusBarController {
}
}
protected _getSufficientValues(items: StatusBarItem[]): (string | null)[] {
private _getSufficientValues(items: StatusBarItem[]): (string | null)[] {
return items
.filter((item) => item.enabled !== false && item.sufficient)
.map((item) => this._getSufficientValue(item));
}
protected _show(): void {
private _show(): void {
setOrRemoveAttribute(this._host, false, 'hide');
}
protected _hide(): void {
private _hide(): void {
setOrRemoveAttribute(this._host, true, 'hide');
}
}