mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-27 11:16:35 +00:00
Use named export for compare (#3169)
This commit is contained in:
parent
0e044acaa9
commit
b9f86f735b
@ -1,4 +1,4 @@
|
||||
export default (a, b) => {
|
||||
export const compare = (a: string, b: string) => {
|
||||
if (a < b) {
|
||||
return -1;
|
||||
}
|
||||
|
@ -16,7 +16,7 @@ import {
|
||||
import { HomeAssistant } from "../../types";
|
||||
import { fireEvent } from "../../common/dom/fire_event";
|
||||
import { User, fetchUsers } from "../../data/user";
|
||||
import compare from "../../common/string/compare";
|
||||
import { compare } from "../../common/string/compare";
|
||||
|
||||
class HaEntityPicker extends LitElement {
|
||||
public hass?: HomeAssistant;
|
||||
|
@ -21,7 +21,7 @@ import {
|
||||
import "../../../components/ha-card";
|
||||
import "../../../layouts/hass-subpage";
|
||||
import "../../../layouts/hass-loading-screen";
|
||||
import compare from "../../../common/string/compare";
|
||||
import { compare } from "../../../common/string/compare";
|
||||
import "../ha-config-section";
|
||||
import {
|
||||
showAreaRegistryDetailDialog,
|
||||
|
@ -21,7 +21,7 @@ import "../../../layouts/hass-subpage";
|
||||
import "../../../layouts/hass-loading-screen";
|
||||
import "../../../components/ha-card";
|
||||
import "../../../components/ha-icon";
|
||||
import compare from "../../../common/string/compare";
|
||||
import { compare } from "../../../common/string/compare";
|
||||
import domainIcon from "../../../common/entity/domain_icon";
|
||||
import stateIcon from "../../../common/entity/state_icon";
|
||||
import computeDomain from "../../../common/entity/compute_domain";
|
||||
|
@ -4,7 +4,7 @@ import { PolymerElement } from "@polymer/polymer/polymer-element";
|
||||
import "../../../layouts/hass-subpage";
|
||||
|
||||
import "../../../components/entity/state-badge";
|
||||
import compare from "../../../common/string/compare";
|
||||
import { compare } from "../../../common/string/compare";
|
||||
|
||||
import "./ha-device-card";
|
||||
import "./ha-ce-entities-card";
|
||||
|
@ -7,7 +7,7 @@ import { timeOut } from "@polymer/polymer/lib/utils/async";
|
||||
import "./ha-config-entries-dashboard";
|
||||
import "./ha-config-entry-page";
|
||||
import NavigateMixin from "../../../mixins/navigate-mixin";
|
||||
import compare from "../../../common/string/compare";
|
||||
import { compare } from "../../../common/string/compare";
|
||||
import { fetchAreaRegistry } from "../../../data/area_registry";
|
||||
|
||||
class HaConfigIntegrations extends NavigateMixin(PolymerElement) {
|
||||
|
@ -13,7 +13,7 @@ import EventsMixin from "../../../mixins/events-mixin";
|
||||
import LocalizeMixin from "../../../mixins/localize-mixin";
|
||||
import computeStateName from "../../../common/entity/compute_state_name";
|
||||
import "../../../components/entity/state-badge";
|
||||
import compare from "../../../common/string/compare";
|
||||
import { compare } from "../../../common/string/compare";
|
||||
import { updateDeviceRegistryEntry } from "../../../data/device_registry";
|
||||
|
||||
function computeEntityName(hass, entity) {
|
||||
|
@ -21,7 +21,7 @@ import {
|
||||
import "../../../components/ha-card";
|
||||
import "../../../layouts/hass-subpage";
|
||||
import "../../../layouts/hass-loading-screen";
|
||||
import compare from "../../../common/string/compare";
|
||||
import { compare } from "../../../common/string/compare";
|
||||
import "../ha-config-section";
|
||||
import {
|
||||
showPersonDetailDialog,
|
||||
|
@ -22,7 +22,7 @@ import {
|
||||
} from "lit-element";
|
||||
|
||||
import { fireEvent } from "../../../common/dom/fire_event";
|
||||
import compare from "../../../common/string/compare";
|
||||
import { compare } from "../../../common/string/compare";
|
||||
import {
|
||||
AreaRegistryEntry,
|
||||
fetchAreaRegistry,
|
||||
|
Loading…
x
Reference in New Issue
Block a user