2024年11月4日星期一 下午1:51:14

Home Assistant Lovelace UI

2 年 前
#13324 引用


Home Assistant Lovelace UI 官方教程
https://www.home-assistant.io/dashboards/


Home Assistant Lovelace UI  Demo online

https://demo.home-assistant.io/#/lovelace/0


How to Create a Home Assistant Dashboard
https://lazyadmin.nl/home-network/home-assistant-dashboard/


教程

Home Assistant Lovelace UI 卡片介绍

https://blog.csdn.net/baidu_26678247/article/details/117631256


https://post.smzdm.com/p/axlxed09/
0
2 年 前
#13325 引用
Quick Start

Add  new dashboard

menu path:Settings->Dashboards->Add Dashboard


or

Add  new dashboard:  http://192.168.2.50:38123/config/lovelace/dashboards




0
2 年 前
#13326 引用


Home Assistant Lovelace UI几个概念

仪表盘(Dashboard):在左侧菜单栏的顶部是仪表盘,每个仪表盘可以显示一套前端页面。

视图(View):右侧页面显示的是视图,一个仪表盘中可以包含多个视图。

卡片(card):视图由不同形式与风格的卡片组成,卡片用来显示设备状态、控制设备动作,等等。

徽章(Badges):视图顶部显示的圆形图标。


一个ha 实例包含多个Dashboard
一个Dashboard包含多个View
一个View包含多个Card
Card有不同的类型





0
2 年 前
#13327 引用
1
0
2 年 前
#13328 引用
视图(View)
一个仪表盘中可以包含多个视图,默认只有「HOME」一个视图,用户可以手动添加,点击顶部进行切换。

每个视图中可定义内容有:
0
2 年 前
#13329 引用
detail
0
2 年 前
#13330 引用
Step 1:Add new dashboard

You can define multiple dashboards in Home Assistant. Each dashboard can be added to the sidebar. This makes it possible to create separate control dashboards for each individual part of your house.

You can manage your dashboards via the user interface. Go to Settings -> Dashboards. Here you can see all defined dashboards and create new ones.

https://www.home-assistant.io/dashboards/dashboards/



gui  menu path:
overview - mange dashboard - add  dashboard
http://192.168.101.50:8123/config/lovelace/dashboards

创建家庭助理仪表板

Click Overview in your sidebar.
Click the three dots menu (top-right) and click on Edit Dashboard.

你可以 创建你的 仪表盘 如你所见! 为此,没有什么非常复杂的,您必须单击 “三个小点” 在屏幕的右上角然后打开 “配置用户界面” :

You can define multiple dashboards in Home Assistant. Each dashboard can be added to the sidebar. This makes it possible to create separate control dashboards for each individual part of your house.

Under configuration -> lovelace dashboards, click the + sign



添加您自己的主题

Add New dashboard

.storage/lovelace
.storage/lovelace.new_dashboard


output



  新文件:   .storage/lovelace.new_dashboard
  新文件:   .storage/lovelace_dashboards



.storage/lovelace_dashboards
The lovelace_dashboards file seems to be some kind of index of all dashboards.

{
"version": 1,
"minor_version": 1,
"key": "lovelace_dashboards",
"data": {
     "items": [
          {6 items},
          {6 items},
          {6 items}
     ]
  }
}


detail

{
  "version": 1,
  "minor_version": 1,
  "key": "lovelace_dashboards",
  "data": {
    "items": [
      {
        "show_in_sidebar": true,
        "title": "new dashboard",
        "require_admin": false,
        "mode": "storage",
        "url_path": "new-dashboard",
        "id": "new_dashboard"
      },
      {
        "show_in_sidebar": true,
        "title": "test",
        "require_admin": true,
        "mode": "storage",
        "url_path": "dashboard-test",
        "id": "dashboard_test"
      },
      {
        "show_in_sidebar": true,
        "title": "dashboard - card",
        "require_admin": true,
        "mode": "storage",
        "url_path": "dashboard-card",
        "id": "dashboard_card"
      }
    ]
  }
}



.storage/lovelace.new_dashboard



{
  "version": 1,
  "minor_version": 1,
  "key": "lovelace_dashboards",
  "data": {
    "items": [
      {
        "show_in_sidebar": true,
        "title": "new dashboard",
        "require_admin": false,
        "mode": "storage",
        "url_path": "new-dashboard",
        "id": "new_dashboard"
      }
    ]
  }
}




0
2 年 前
#13331 引用


.storage/lovelace.new_dashboard



{
  "version": 1,
  "minor_version": 1,
  "key": "lovelace.new_dashboard",
  "data": {
    "config": {
      "title": "Home",
      "views": [
        {
          "path": "default_view",
          "title": "Home",
          "cards": [
            {
              "type": "grid",
              "square": false,
              "columns": 1,
              "cards": [
                {
                  "type": "entities",
                  "entities": [
                    "light.yeelink_light_ceiling21_by_alone_s_miio_for_yeelink",
                    "binary_sensor.motion_sensor",
                    "light.aqara_hub_m1s_edb6_lightbulb"
                  ],
                  "title": "Living Room"
                },
                {
                  "type": "alarm-panel",
                  "entity": "alarm_control_panel.aqara_hub_m1s_edb6_security_system"
                }
              ]
            },
            {
              "type": "entities",
              "entities": [
                "binary_sensor.contact_sensor",
                "light.lightbulb"
              ],
              "title": "balcony"
            },
            {
              "type": "entities",
              "entities": [
                "binary_sensor.yeelight_ceil26_0x1c5c4959_nightlight",
                "light.yeelight_ceil26_0x1c5c4959",
                "select.ceil26_ec4d3e8def4f_a_l",
                "select.ceil26_ec4d3e8def4f_light_flow",
                "light.ceil26_ec4d3e8def4f"
              ],
              "title": "book bedroom"
            },
            {
              "type": "grid",
              "square": false,
              "columns": 1,
              "cards": [
                {
                  "type": "entities",
                  "entities": [
                    "fan.miir_ir01_6272_ir_fan_control",
                    "remote.xiaomi_l05c_5ac1_wifispeaker",
                    "binary_sensor.isa_dw2hl_2f70_magnet_sensor",
                    "select.miir_ir02_5040_ir_aircondition_control",
                    "binary_sensor.lumi_bmgl01_bf13_motion_sensor",
                    "select.miir_ir02_5040_mode_for_ir",
                    "number.miir_ir02_5040_temperature_for_ir",
                    "select.remote_ir_1558634104399286272",
                    "sensor.lumi_bmgl01_bf13_trigger_at",
                    "binary_sensor.lumi_bmgl01_bf13_light_strong",
                    "sensor.isa_dw2hl_2f70_illumination",
                    "sensor.lumi_bmgl01_bf13_illumination",
                    "sensor.xiaomi_l05c_5ac1_conversation"
                  ],
                  "title": "主卧"
                },
                {
                  "type": "thermostat",
                  "entity": "climate.miir_ir02_5040_ir_aircondition_control"
                },
                {
                  "type": "media-control",
                  "entity": "media_player.xiaomi_l05c_5ac1_play_control"
                }
              ]
            },
            {
              "type": "entities",
              "entities": [
                "light.yeelink_mbulb3_6cd9_light"
              ],
              "title": "主卧卫生间"
            },
            {
              "type": "grid",
              "square": false,
              "columns": 1,
              "cards": [
                {
                  "type": "entities",
                  "entities": [
                    "light.yeelink_ceil26_ef4f_light",
                    "remote.xiaomi_lx06_026c_wifispeaker",

            
0
2 年 前
#13332 引用
1

Well, it looks like editing the dashboard-related files in the .storage hidden directory is quite straightforward and works. They seem to be simple JSON files. You just have to make sure to change the dashboard related data in two files:

lovelace.lovelace_xxx
lovelace_dashboards

where xxx is the name of your dashboard. The second file seems to be some kind of index of all dashboards.

https://community.home-assistant.io/t/retrieve-the-dashboard-view-from-the-data-base/190118/2?u=msly
0
2 年 前
#13333 引用
Step 2:Add new View

Add new View named with "book bedroom"  in new dashboard named with ""


You can add a view to your user interface, by clicking the menu (three dots at the top right of the screen) and then Edit Dashboard. Click the + button in the top menu bar.




https://www.home-assistant.io/dashboards/views/
0