diff --git a/src/panels/config/automation/ha-automation-picker.ts b/src/panels/config/automation/ha-automation-picker.ts index 50d14b34ef..4507db80d0 100644 --- a/src/panels/config/automation/ha-automation-picker.ts +++ b/src/panels/config/automation/ha-automation-picker.ts @@ -1528,6 +1528,10 @@ ${rejected ha-assist-chip { --ha-assist-chip-container-shape: 10px; } + ha-dropdown::part(menu), + ha-dropdown::part(submenu) { + --auto-size-available-width: calc(50vw - var(--ha-space-4)); + } ha-dropdown ha-assist-chip { --md-assist-chip-trailing-space: 8px; } diff --git a/src/panels/config/devices/ha-config-devices-dashboard.ts b/src/panels/config/devices/ha-config-devices-dashboard.ts index 58786db526..3cb7112fe4 100644 --- a/src/panels/config/devices/ha-config-devices-dashboard.ts +++ b/src/panels/config/devices/ha-config-devices-dashboard.ts @@ -1296,6 +1296,10 @@ ${rejected ha-assist-chip { --ha-assist-chip-container-shape: 10px; } + ha-dropdown::part(menu), + ha-dropdown::part(submenu) { + --auto-size-available-width: calc(50vw - var(--ha-space-4)); + } ha-dropdown ha-assist-chip { --md-assist-chip-trailing-space: 8px; } diff --git a/src/panels/config/entities/ha-config-entities.ts b/src/panels/config/entities/ha-config-entities.ts index 09ab7e80a9..f6efd38fce 100644 --- a/src/panels/config/entities/ha-config-entities.ts +++ b/src/panels/config/entities/ha-config-entities.ts @@ -90,6 +90,8 @@ import type { import { updateEntityRegistryEntry } from "../../../data/entity/entity_registry"; import type { EntitySources } from "../../../data/entity/entity_sources"; import { fetchEntitySourcesWithCache } from "../../../data/entity/entity_sources"; +import type { ExposeEntitySettings } from "../../../data/expose"; +import { listExposedEntities, voiceAssistants } from "../../../data/expose"; import { HELPERS_CRUD } from "../../../data/helpers_crud"; import type { IntegrationManifest } from "../../../data/integration"; import { @@ -119,13 +121,11 @@ import { isHelperDomain } from "../helpers/const"; import "../integrations/ha-integration-overflow-menu"; import { showAddIntegrationDialog } from "../integrations/show-add-integration-dialog"; import { showLabelDetailDialog } from "../labels/show-dialog-label-detail"; -import type { ExposeEntitySettings } from "../../../data/expose"; -import { listExposedEntities, voiceAssistants } from "../../../data/expose"; -import { getAvailableAssistants } from "../voice-assistants/expose/available-assistants"; import { getAssistantsSortableKey, getAssistantsTableColumn, } from "../voice-assistants/expose/assistants-table-column"; +import { getAvailableAssistants } from "../voice-assistants/expose/available-assistants"; export interface StateEntity extends Omit< EntityRegistryEntry, @@ -1724,6 +1724,10 @@ ${rejected ha-assist-chip { --ha-assist-chip-container-shape: 10px; } + ha-dropdown::part(menu), + ha-dropdown::part(submenu) { + --auto-size-available-width: calc(50vw - var(--ha-space-4)); + } ha-dropdown ha-assist-chip { --md-assist-chip-trailing-space: 8px; } diff --git a/src/panels/config/helpers/ha-config-helpers.ts b/src/panels/config/helpers/ha-config-helpers.ts index 60a3c4b50a..b3966f6027 100644 --- a/src/panels/config/helpers/ha-config-helpers.ts +++ b/src/panels/config/helpers/ha-config-helpers.ts @@ -1580,6 +1580,10 @@ ${rejected ha-assist-chip { --ha-assist-chip-container-shape: 10px; } + ha-dropdown::part(menu), + ha-dropdown::part(submenu) { + --auto-size-available-width: calc(50vw - var(--ha-space-4)); + } ha-dropdown ha-assist-chip { --md-assist-chip-trailing-space: 8px; } diff --git a/src/panels/config/scene/ha-scene-dashboard.ts b/src/panels/config/scene/ha-scene-dashboard.ts index c1090d6585..b94729fda3 100644 --- a/src/panels/config/scene/ha-scene-dashboard.ts +++ b/src/panels/config/scene/ha-scene-dashboard.ts @@ -1,3 +1,4 @@ +import "@home-assistant/webawesome/dist/components/divider/divider"; import { ResizeController } from "@lit-labs/observers/resize-controller"; import { consume } from "@lit/context"; import { @@ -45,16 +46,15 @@ import type { } from "../../../components/data-table/ha-data-table"; import "../../../components/data-table/ha-data-table-labels"; import "../../../components/ha-button"; +import "../../../components/ha-dropdown"; +import "../../../components/ha-dropdown-item"; +import type { HaDropdownItem } from "../../../components/ha-dropdown-item"; import "../../../components/ha-fab"; import "../../../components/ha-filter-categories"; import "../../../components/ha-filter-devices"; import "../../../components/ha-filter-entities"; import "../../../components/ha-filter-floor-areas"; import "../../../components/ha-filter-labels"; -import "@home-assistant/webawesome/dist/components/divider/divider"; -import "../../../components/ha-dropdown"; -import "../../../components/ha-dropdown-item"; -import type { HaDropdownItem } from "../../../components/ha-dropdown-item"; import "../../../components/ha-filter-voice-assistants"; import "../../../components/ha-icon-button"; import "../../../components/ha-icon-overflow-menu"; @@ -84,6 +84,7 @@ import type { UpdateEntityRegistryEntryResult, } from "../../../data/entity/entity_registry"; import { updateEntityRegistryEntry } from "../../../data/entity/entity_registry"; +import { getEntityVoiceAssistantsIds } from "../../../data/expose"; import { forwardHaptic } from "../../../data/haptics"; import type { LabelRegistryEntry } from "../../../data/label/label_registry"; import { @@ -98,7 +99,6 @@ import { saveScene, showSceneEditor, } from "../../../data/scene"; -import { showSceneSaveDialog } from "./scene-save-dialog/show-dialog-scene-save"; import { showAlertDialog, showConfirmationDialog, @@ -115,12 +115,12 @@ import { showAssignCategoryDialog } from "../category/show-dialog-assign-categor import { showCategoryRegistryDetailDialog } from "../category/show-dialog-category-registry-detail"; import { configSections } from "../ha-panel-config"; import { showLabelDetailDialog } from "../labels/show-dialog-label-detail"; -import { getEntityVoiceAssistantsIds } from "../../../data/expose"; -import { getAvailableAssistants } from "../voice-assistants/expose/available-assistants"; import { - getAssistantsTableColumn, getAssistantsSortableKey, + getAssistantsTableColumn, } from "../voice-assistants/expose/assistants-table-column"; +import { getAvailableAssistants } from "../voice-assistants/expose/available-assistants"; +import { showSceneSaveDialog } from "./scene-save-dialog/show-dialog-scene-save"; type SceneItem = SceneEntity & { name: string; @@ -1367,6 +1367,10 @@ ${rejected ha-assist-chip { --ha-assist-chip-container-shape: 10px; } + ha-dropdown::part(menu), + ha-dropdown::part(submenu) { + --auto-size-available-width: calc(50vw - var(--ha-space-4)); + } ha-dropdown ha-assist-chip { --md-assist-chip-trailing-space: 8px; } diff --git a/src/panels/config/script/ha-script-picker.ts b/src/panels/config/script/ha-script-picker.ts index 742427b802..947672b5b6 100644 --- a/src/panels/config/script/ha-script-picker.ts +++ b/src/panels/config/script/ha-script-picker.ts @@ -1417,6 +1417,10 @@ ${rejected ha-assist-chip { --ha-assist-chip-container-shape: 10px; } + ha-dropdown::part(menu), + ha-dropdown::part(submenu) { + --auto-size-available-width: calc(50vw - var(--ha-space-4)); + } ha-dropdown ha-assist-chip { --md-assist-chip-trailing-space: 8px; }