{"id":322,"date":"2023-07-04T13:47:48","date_gmt":"2023-07-04T05:47:48","guid":{"rendered":"http:\/\/blog.naspro.cc\/?p=322"},"modified":"2024-07-15T15:05:36","modified_gmt":"2024-07-15T07:05:36","slug":"%e5%a6%82%e4%bd%95%e5%9c%a8%e4%b8%bb%e9%a1%b5%e6%b7%bb%e5%8a%a0%e5%bc%b9%e5%87%ba%e5%8d%a1%e7%89%87","status":"publish","type":"post","link":"http:\/\/blog.naspro.cc\/?p=322","title":{"rendered":"Home Assistant \u5982\u4f55\u5728\u4e3b\u9875\u6dfb\u52a0\u5f39\u51fa\u5361\u7247"},"content":{"rendered":"<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_73 counter-flat ez-toc-counter ez-toc-light-blue ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<span class=\"ez-toc-title-toggle\"><a href=\"#\" class=\"ez-toc-pull-right ez-toc-btn ez-toc-btn-xs ez-toc-btn-default ez-toc-toggle\" aria-label=\"Toggle Table of Content\"><span class=\"ez-toc-js-icon-con\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/span><\/a><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"http:\/\/blog.naspro.cc\/?p=322\/#%e6%95%88%e6%9e%9c%e9%a2%84%e8%a7%88\" title=\"\u6548\u679c\u9884\u89c8\">\u6548\u679c\u9884\u89c8<\/a><\/li><li class='ez-toc-page-1'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"http:\/\/blog.naspro.cc\/?p=322\/#%e4%bb%a3%e7%a0%81\" title=\"\u4ee3\u7801\">\u4ee3\u7801<\/a><\/li><\/ul><\/nav><\/div>\n<h2><span class=\"ez-toc-section\" id=\"%e6%95%88%e6%9e%9c%e9%a2%84%e8%a7%88\"><\/span>\u6548\u679c\u9884\u89c8<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p><img decoding=\"async\" src=\"https:\/\/p.tolan.link:6688\/i\/2023\/07\/04\/m94tmk-0.gif\" alt=\"\u7b80\u5355\u56fe\u5e8a - EasyImage\" \/><\/p>\n<h2><span class=\"ez-toc-section\" id=\"%e4%bb%a3%e7%a0%81\"><\/span>\u4ee3\u7801<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<pre class=\"prettyprint linenums\" ><code class=\"language-yaml\">- type: custom:layout-card #\u5f39\u51fa\u5361\u7247\u4ee3\u7801\u5f00\u59cb\uff0c\u6dfb\u52a0\u5d4c\u5957\u5361\u7247#\r\n  layout type: custom:horizontal-layout\r\n  layout:\r\n    width: 60 #\u5bbd\u5ea6\r\n    max_cols: 10 #\u6700\u5927\u503c\r\n  style: #\u8c03\u6574\u5361\u7247\u4f4d\u7f6e#\r\n    top: 52.2%\r\n    left: 92% \r\n    opacity: 0.7 #\u4e0d\u900f\u660e\u5ea6\r\n  cards: #\u6dfb\u52a0\u9700\u8981\u5f39\u51fa\u7684\u5361\u7247\u6309\u94ae#\r\n    - type: horizontal-stack\r\n      cards:\r\n        - type: custom:mushroom-template-card\r\n          primary: \u5929\u6c14 #\u6309\u94ae\u540d\u79f0\r\n          secondary: ''\r\n          icon: mdi:cloud  #\u5361\u7247\u56fe\u6807 \u83b7\u53d6\u56fe\u6807\u5730\u5740 https:\/\/joe1900.github.io\/MDI\/ #\r\n          layout: vertical\r\n          fill_container:  \r\n          icon_color: '#20B2AA'\r\n          tap_action:\r\n            action: fire-dom-event\r\n            browser_mod:\r\n              service: browser_mod.popup\r\n              data:\r\n                title: \u5929\u6c14 #\u6dfb\u52a0\u5f39\u51fa\u9875\u9762\u6807\u9898#\r\n                content: #\u6dfb\u52a0\u9700\u8981\u5f39\u51fa\u7684\u5361\u7247\u4ee3\u7801\uff0c\u4ee5\u4e0b\u4ee3\u7801\u66ff\u6362\u6210\u4f60\u8981\u6dfb\u52a0\u7684\u5361\u7247\u4ee3\u7801#\r\n                  type: grid\r\n                  square: false\r\n                  columns: 1\r\n                  cards:\r\n                    - type: entities\r\n                      entities:\r\n                        - entity: sensor.wo_de_jia_feng_su\r\n                          name: \u98ce\u901f\r\n                        - entity: sensor.wo_de_jia_gan_jue_wen_du\r\n                          name: \u611f\u89c9\u6e29\u5ea6\r\n                        - entity: sensor.wo_de_jia_neng_jian_du\r\n                          name: \u80fd\u89c1\u5ea6\r\n                        - entity: sensor.wo_de_jia_qi_ya\r\n                          name: \u6c14\u538b\r\n                        - entity: sensor.wo_de_jia_shi_du\r\n                          name: \u6e7f\u5ea6\r\n                        - entity: sensor.wo_de_jia_shu_gua_zhi_shu\r\n                          name: \u8212\u9002\u6307\u6570\r\n                        - entity: sensor.wo_de_jia_wen_du\r\n                          name: \u6e29\u5ea6\r\n                        - entity: sensor.wo_de_jia_yu_liang\r\n                          name: \u96e8\u91cf\r\n                        - entity: sensor.wo_de_jia_yun_liang\r\n                          name: \u4e91\u91cf\r\n                        - entity: sensor.wo_de_jia_zi_wai_xian\r\n                          name: \u7d2b\u5916\u7ebf\r\n                      title: \u6211\u7684\u5bb6\r\n                    - type: weather-forecast\r\n                      entity: weather.wo_de_jia\r\n                      show_forecast: false\r\n<\/code><\/pre>\n<p>\u5907\u6ce8\uff1a\u6ce8\u610f\u4ee3\u7801\u7f29\u8fdb<\/p>\n<p>\u8865\u5145 \u624b\u673aUI\u754c\u9762\u7684\u5f39\u51fa\u5361\u7247\u4ee3\u7801<\/p>\n<pre class=\"prettyprint linenums\" ><code class=\"language-yaml\">type: custom:mushroom-template-card\r\nprimary: \u7a7a\u6c14\u70b8\u9505\r\nsecondary: &#039;&#039;\r\nicon: mdi:cloud\r\nlayout: vertical\r\nfill_container: null\r\nicon_color: &#039;#20B2AA&#039;\r\ntap_action:\r\n  action: fire-dom-event\r\n  browser_mod:\r\n    service: browser_mod.popup\r\n    data:\r\n      title: .\r\n      content:\r\n        type: grid\r\n        square: false\r\n        columns: 1\r\n        cards:\r\n          - type: entities\r\n            entities:\r\n              - entity: button.careli_maf03a_ae49_start_cook\r\n                name: \u5f00\u59cb\u70f9\u996a\r\n              - select.careli_maf03a_ae49_target_time\r\n              - number.careli_maf03a_ae49_target_temperature\r\n              - select.careli_maf03a_ae49_target_temperature\r\n              - switch.careli_maf03a_ae49_air_fryer_status\r\n              - button.careli_maf03a_ae49_cancel_cooking\r\n              - entity: button.careli_maf03a_ae49_pause\r\n                name: \u6682\u505c\r\n            title: \u7c73\u5bb6\u7a7a\u6c14\u70b8\u9505d\r\n<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u6548\u679c\u9884\u89c8 \u4ee3\u7801 &#8211; type: custom:layout-card #\u5f39\u51fa\u5361\u7247\u4ee3\u7801\u5f00\u59cb\uff0c\u6dfb\u52a0\u5d4c\u5957\u5361\u7247# layout type: custom:horizontal-layout layout: width: 60 #\u5bbd\u5ea6 max_cols: 10 #\u6700\u5927\u503c style: #\u8c03\u6574\u5361\u7247\u4f4d\u7f6e# top: 52.2% left: 92% opacity: 0.7 #\u4e0d\u900f\u660e\u5ea6 cards: #\u6dfb\u52a0\u9700\u8981\u5f39 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[38,3],"tags":[39],"class_list":["post-322","post","type-post","status-publish","format-standard","hentry","category-home-assistant","category-internet","tag-39"],"_links":{"self":[{"href":"http:\/\/blog.naspro.cc\/index.php?rest_route=\/wp\/v2\/posts\/322","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/blog.naspro.cc\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/blog.naspro.cc\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/blog.naspro.cc\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/blog.naspro.cc\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=322"}],"version-history":[{"count":0,"href":"http:\/\/blog.naspro.cc\/index.php?rest_route=\/wp\/v2\/posts\/322\/revisions"}],"wp:attachment":[{"href":"http:\/\/blog.naspro.cc\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=322"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/blog.naspro.cc\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=322"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/blog.naspro.cc\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=322"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}