@hakit/core
Version:
A collection of React hooks and helpers for Home Assistant to easily communicate with the Home Assistant WebSocket API.
18 lines (17 loc) • 525 B
JavaScript
import { useMemo as r } from "react";
import "lodash";
import "../../../index-BDZyTvOW.js";
import "../useLocale/locales/index.js";
import "home-assistant-js-websocket";
import "../../utils/date.js";
import { ON as o } from "../../data/entity.js";
import "@iconify/react";
import "use-debounce";
const g = (t) => r(
() => t.state === o ? Math.max(Math.round((t.attributes.brightness ?? 0) * 100 / 255), 1) : 0,
[t.attributes.brightness, t.state]
);
export {
g as useLightBrightness
};
//# sourceMappingURL=index.js.map