home-assistant-dashboards-cards

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Home Assistant Dashboards & Cards

Home Assistant 仪表盘与卡片

Workflow

工作流程

  • Determine whether to create a new dashboard or edit an existing one.
  • If editing, locate target cards first and transform config with a current
    config_hash
    .
  • Use built-in cards unless a custom card is required.
  • Discover entity IDs before wiring cards.
  • Provide minimal, valid dashboard snippets or tool-driven changes.
  • 判断是创建新仪表盘还是编辑现有仪表盘。
  • 若为编辑操作,先定位目标卡片,再结合当前的
    config_hash
    修改配置。
  • 除非需要自定义卡片,否则优先使用内置卡片。
  • 在配置卡片前先获取实体ID。
  • 提供精简且有效的仪表盘代码片段或工具驱动的变更方案。

Tooling map (ha-mcp)

工具映射(ha-mcp)

  • Discover entities:
    ha_get_overview
    ,
    ha_search_entities
  • List/get dashboards:
    ha_config_get_dashboard
  • Find cards:
    ha_dashboard_find_card
  • Card docs:
    ha_get_card_types
    ,
    ha_get_card_documentation
  • Update config:
    ha_config_set_dashboard
    ,
    ha_config_update_dashboard_metadata
  • Resources:
    ha_config_list_dashboard_resources
    ,
    ha_config_set_dashboard_resource
    ,
    ha_config_set_inline_dashboard_resource
    ,
    ha_config_delete_dashboard_resource
  • HACS cards:
    ha_hacs_info
    ,
    ha_hacs_list_installed
    ,
    ha_hacs_search
    ,
    ha_hacs_download
  • 发现实体:
    ha_get_overview
    ,
    ha_search_entities
  • 列出/获取仪表盘:
    ha_config_get_dashboard
  • 查找卡片:
    ha_dashboard_find_card
  • 卡片文档:
    ha_get_card_types
    ,
    ha_get_card_documentation
  • 更新配置:
    ha_config_set_dashboard
    ,
    ha_config_update_dashboard_metadata
  • 资源管理:
    ha_config_list_dashboard_resources
    ,
    ha_config_set_dashboard_resource
    ,
    ha_config_set_inline_dashboard_resource
    ,
    ha_config_delete_dashboard_resource
  • HACS卡片:
    ha_hacs_info
    ,
    ha_hacs_list_installed
    ,
    ha_hacs_search
    ,
    ha_hacs_download

Caveats

注意事项

  • Dashboard URL paths must contain a hyphen.
  • Strategy dashboards require “Take Control” before editing.
  • Resource changes may require a hard refresh.
  • Jinja templates are not evaluated in core Lovelace YAML.
  • 仪表盘URL路径必须包含连字符。
  • 策略型仪表盘在编辑前需要“Take Control”权限。
  • 资源变更后可能需要强制刷新页面。
  • 核心Lovelace YAML中不会解析Jinja模板。

References

参考资料

All reference files are relative to the location of this SKILL.md file.
  • Design patterns:
    references/DESIGN_PATTERNS.md
  • Card schema guide:
    references/CARD_SCHEMA_GUIDE.md
  • Custom resources:
    references/CUSTOM_RESOURCES.md
所有参考文件的路径均相对于本SKILL.md文件的位置。
  • 设计模式:
    references/DESIGN_PATTERNS.md
  • 卡片Schema指南:
    references/CARD_SCHEMA_GUIDE.md
  • 自定义资源:
    references/CUSTOM_RESOURCES.md