Advertisement
naynner

Weather Forecast Graph - Card

Feb 12th, 2024 (edited)
776
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 34.66 KB | None | 0 0
  1. type: vertical-stack
  2. cards:
  3. - type: horizontal-stack
  4. cards:
  5. - type: vertical-stack
  6. cards:
  7. - type: custom:mushroom-template-card
  8. primary: Today
  9. secondary: ''
  10. icon: ''
  11. card_mod:
  12. style:
  13. mushroom-state-info$: |
  14. .container {
  15. --card-primary-font-size: 12px;
  16. align-items: center;
  17. }
  18. .: |
  19. ha-card {
  20. background-color: transparent;
  21. opacity: 0.9;
  22. padding-top: 0px !important;
  23. padding-bottom: 0px !important;
  24. margin-top: -0px !important;
  25. margin-bottom: -10px !important;
  26. }
  27. - type: custom:mushroom-chips-card
  28. chips:
  29. - type: template
  30. content: ''
  31. picture: >-
  32. {% set cond =
  33. (state_attr('sensor.pirate_weather_daily','forecast')[0].condition)
  34. %} {% if cond == 'clear-day' %}
  35. /local/animated/clear-day.svg
  36. {% elif cond == 'clear-night' %}
  37. /local/animated/clear-night.svg
  38. {% elif cond == 'rainy' %}
  39. /local/animated/rainy-6.svg
  40. {% elif cond == 'rain' %}
  41. /local/animated/rainy-6.svg
  42. {% elif cond == 'snowy' %}
  43. /local/animated/snow.svg
  44. {% elif cond == 'snow' %}
  45. /local/animated/snow.svg
  46. {% elif cond == 'sleet' %}
  47. /local/animated/sleet.svg
  48. {% elif cond == 'windy' %}
  49. /local/animated/wind.svg
  50. {% elif cond == 'wind' %}
  51. /local/animated/wind.svg
  52. {% elif cond == 'fog' %}
  53. /local/animated/fog.svg
  54. {% elif cond == 'cloudy' %}
  55. /local/animated/cloudy.svg
  56. {% elif cond == 'partlycloudy' %}
  57. /local/animated/partly-cloudy-day_old.svg
  58. {% elif cond == 'partly-cloudy-day' %}
  59. /local/animated/partly-cloudy-day_old.svg
  60. {% elif cond == 'partly-cloudy-night' %}
  61. /local/animated/partly-cloudy-night.svg
  62. {% elif cond == 'lightning' %}
  63. /local/animated/thunder.svg
  64. {% elif cond == 'snowy_rainy' %}
  65. /local/animated/sleet.svg
  66. {% elif cond == 'sunny' %}
  67. /local/animated/clear-day.svg
  68. {% elif cond == 'hail' %}
  69. /local/animated/rainy-6.svg
  70. {% endif %}
  71. alignment: center
  72. card_mod:
  73. style: |
  74. ha-card {
  75. opacity: 0.8;
  76. --chip-background: transparent !important;
  77. --chip-height: 50px;
  78. padding-top: 0px !important;
  79. padding-bottom: 0px !important;
  80. margin-top: -10px !important;
  81. margin-bottom: -10px !important;
  82. }
  83. - type: custom:mushroom-template-card
  84. primary: >-
  85. {{ state_attr('sensor.pirate_weather_daily','forecast')[0].temperature | round(0) }}° |‎ ‎{{ states('sensor.forecast_low') }}°
  86. secondary: ''
  87. icon: ''
  88. card_mod:
  89. style:
  90. mushroom-state-info$: |
  91. .container {
  92. --card-primary-font-size: 16px;
  93. align-items: center;
  94. }
  95. .: |
  96. ha-card {
  97. opacity: 0.8;
  98. background: transparent !important;
  99. padding-top: 0px !important;
  100. padding-bottom: 0px !important;
  101. margin-top: -15px !important;
  102. margin-bottom: -10px !important;
  103. }
  104. picture: ''
  105. - type: vertical-stack
  106. cards:
  107. - type: custom:mushroom-template-card
  108. primary: >-
  109. {{
  110. as_timestamp(state_attr('sensor.pirate_weather_daily','forecast')[1].datetime)
  111. | timestamp_custom('%a %-d') }}
  112. secondary: ''
  113. icon: ''
  114. card_mod:
  115. style:
  116. mushroom-state-info$: |
  117. .container {
  118. --card-primary-font-size: 12px;
  119. align-items: center;
  120. }
  121. .: |
  122. ha-card {
  123. background-color: transparent;
  124. opacity: 0.9;
  125. padding-top: 0px !important;
  126. padding-bottom: 0px !important;
  127. margin-top: -0px !important;
  128. margin-bottom: -10px !important;
  129. }
  130. - type: custom:mushroom-chips-card
  131. chips:
  132. - type: template
  133. content: ''
  134. picture: >-
  135. {% set cond =
  136. (state_attr('sensor.pirate_weather_daily','forecast')[1].condition)
  137. %} {% if cond == 'clear-day' %}
  138. /local/animated/clear-day.svg
  139. {% elif cond == 'clear-night' %}
  140. /local/animated/clear-night.svg
  141. {% elif cond == 'rainy' %}
  142. /local/animated/rainy-6.svg
  143. {% elif cond == 'rain' %}
  144. /local/animated/rainy-6.svg
  145. {% elif cond == 'snowy' %}
  146. /local/animated/snow.svg
  147. {% elif cond == 'snow' %}
  148. /local/animated/snow.svg
  149. {% elif cond == 'sleet' %}
  150. /local/animated/sleet.svg
  151. {% elif cond == 'windy' %}
  152. /local/animated/wind.svg
  153. {% elif cond == 'wind' %}
  154. /local/animated/wind.svg
  155. {% elif cond == 'fog' %}
  156. /local/animated/fog.svg
  157. {% elif cond == 'cloudy' %}
  158. /local/animated/cloudy.svg
  159. {% elif cond == 'partlycloudy' %}
  160. /local/animated/partly-cloudy-day_old.svg
  161. {% elif cond == 'partly-cloudy-day' %}
  162. /local/animated/partly-cloudy-day_old.svg
  163. {% elif cond == 'partly-cloudy-night' %}
  164. /local/animated/partly-cloudy-night.svg
  165. {% elif cond == 'lightning' %}
  166. /local/animated/thunder.svg
  167. {% elif cond == 'snowy_rainy' %}
  168. /local/animated/sleet.svg
  169. {% elif cond == 'sunny' %}
  170. /local/animated/clear-day.svg
  171. {% elif cond == 'hail' %}
  172. /local/animated/rainy-6.svg
  173. {% endif %}
  174. alignment: center
  175. card_mod:
  176. style: |
  177. ha-card {
  178. opacity: 0.8;
  179. --chip-background: transparent !important;
  180. --chip-height: 50px;
  181. padding-top: 0px !important;
  182. padding-bottom: 0px !important;
  183. margin-top: -10px !important;
  184. margin-bottom: -10px !important;
  185. }
  186. - type: custom:mushroom-template-card
  187. primary: >-
  188. {{
  189. state_attr('sensor.pirate_weather_daily','forecast')[1].temperature
  190. }}° |‎ ‎{{ states('sensor.forecast_low_pirate_day_2') }}°
  191. secondary: ''
  192. icon: ''
  193. card_mod:
  194. style:
  195. mushroom-state-info$: |
  196. .container {
  197. --card-primary-font-size: 16px;
  198. align-items: center;
  199. }
  200. .: |
  201. ha-card {
  202. opacity: 0.8;
  203. background: transparent !important;
  204. padding-top: 0px !important;
  205. padding-bottom: 0px !important;
  206. margin-top: -15px !important;
  207. margin-bottom: -10px !important;
  208. }
  209. - type: vertical-stack
  210. cards:
  211. - type: custom:mushroom-template-card
  212. primary: >-
  213. {{
  214. as_timestamp(state_attr('sensor.pirate_weather_daily','forecast')[2].datetime)
  215. | timestamp_custom('%a %-d') }}
  216. secondary: ''
  217. icon: ''
  218. card_mod:
  219. style:
  220. mushroom-state-info$: |
  221. .container {
  222. --card-primary-font-size: 12px;
  223. align-items: center;
  224. }
  225. .: |
  226. ha-card {
  227. background-color: transparent;
  228. opacity: 0.9;
  229. padding-top: 0px !important;
  230. padding-bottom: 0px !important;
  231. margin-top: -0px !important;
  232. margin-bottom: -10px !important;
  233. }
  234. - type: custom:mushroom-chips-card
  235. chips:
  236. - type: template
  237. content: ''
  238. picture: >-
  239. {% set cond =
  240. (state_attr('sensor.pirate_weather_daily','forecast')[2].condition)
  241. %} {% if cond == 'clear-day' %}
  242. /local/animated/clear-day.svg
  243. {% elif cond == 'clear-night' %}
  244. /local/animated/clear-night.svg
  245. {% elif cond == 'rainy' %}
  246. /local/animated/rainy-6.svg
  247. {% elif cond == 'rain' %}
  248. /local/animated/rainy-6.svg
  249. {% elif cond == 'snowy' %}
  250. /local/animated/snow.svg
  251. {% elif cond == 'snow' %}
  252. /local/animated/snow.svg
  253. {% elif cond == 'sleet' %}
  254. /local/animated/sleet.svg
  255. {% elif cond == 'windy' %}
  256. /local/animated/wind.svg
  257. {% elif cond == 'wind' %}
  258. /local/animated/wind.svg
  259. {% elif cond == 'fog' %}
  260. /local/animated/fog.svg
  261. {% elif cond == 'cloudy' %}
  262. /local/animated/cloudy.svg
  263. {% elif cond == 'partlycloudy' %}
  264. /local/animated/partly-cloudy-day_old.svg
  265. {% elif cond == 'partly-cloudy-day' %}
  266. /local/animated/partly-cloudy-day_old.svg
  267. {% elif cond == 'partly-cloudy-night' %}
  268. /local/animated/partly-cloudy-night.svg
  269. {% elif cond == 'lightning' %}
  270. /local/animated/thunder.svg
  271. {% elif cond == 'snowy_rainy' %}
  272. /local/animated/sleet.svg
  273. {% elif cond == 'sunny' %}
  274. /local/animated/clear-day.svg
  275. {% elif cond == 'hail' %}
  276. /local/animated/rainy-6.svg
  277. {% endif %}
  278. alignment: center
  279. card_mod:
  280. style: |
  281. ha-card {
  282. opacity: 0.8;
  283. --chip-background: transparent !important;
  284. --chip-height: 50px;
  285. padding-top: 0px !important;
  286. padding-bottom: 0px !important;
  287. margin-top: -10px !important;
  288. margin-bottom: -10px !important;
  289. }
  290. - type: custom:mushroom-template-card
  291. primary: >-
  292. {{
  293. state_attr('sensor.pirate_weather_daily','forecast')[2].temperature
  294. }}° |‎ ‎{{ states('sensor.forecast_low_pirate_day_3') }}°
  295. secondary: ''
  296. icon: ''
  297. card_mod:
  298. style:
  299. mushroom-state-info$: |
  300. .container {
  301. --card-primary-font-size: 16px;
  302. align-items: center;
  303. }
  304. .: |
  305. ha-card {
  306. opacity: 0.8;
  307. background: transparent !important;
  308. padding-top: 0px !important;
  309. padding-bottom: 0px !important;
  310. margin-top: -15px !important;
  311. margin-bottom: -10px !important;
  312. }
  313. - type: vertical-stack
  314. cards:
  315. - type: custom:mushroom-template-card
  316. primary: >-
  317. {{
  318. as_timestamp(state_attr('sensor.pirate_weather_daily','forecast')[3].datetime)
  319. | timestamp_custom('%a %-d') }}
  320. secondary: ''
  321. icon: ''
  322. card_mod:
  323. style:
  324. mushroom-state-info$: |
  325. .container {
  326. --card-primary-font-size: 12px;
  327. align-items: center;
  328. }
  329. .: |
  330. ha-card {
  331. background-color: transparent;
  332. opacity: 0.9;
  333. padding-top: 0px !important;
  334. padding-bottom: 0px !important;
  335. margin-top: -0px !important;
  336. margin-bottom: -10px !important;
  337. }
  338. - type: custom:mushroom-chips-card
  339. chips:
  340. - type: template
  341. content: ''
  342. picture: >-
  343. {% set cond =
  344. (state_attr('sensor.pirate_weather_daily','forecast')[3].condition)
  345. %} {% if cond == 'clear-day' %}
  346. /local/animated/clear-day.svg
  347. {% elif cond == 'clear-night' %}
  348. /local/animated/clear-night.svg
  349. {% elif cond == 'rainy' %}
  350. /local/animated/rainy-6.svg
  351. {% elif cond == 'rain' %}
  352. /local/animated/rainy-6.svg
  353. {% elif cond == 'snowy' %}
  354. /local/animated/snow.svg
  355. {% elif cond == 'snow' %}
  356. /local/animated/snow.svg
  357. {% elif cond == 'sleet' %}
  358. /local/animated/sleet.svg
  359. {% elif cond == 'windy' %}
  360. /local/animated/wind.svg
  361. {% elif cond == 'wind' %}
  362. /local/animated/wind.svg
  363. {% elif cond == 'fog' %}
  364. /local/animated/fog.svg
  365. {% elif cond == 'cloudy' %}
  366. /local/animated/cloudy.svg
  367. {% elif cond == 'partlycloudy' %}
  368. /local/animated/partly-cloudy-day_old.svg
  369. {% elif cond == 'partly-cloudy-day' %}
  370. /local/animated/partly-cloudy-day_old.svg
  371. {% elif cond == 'partly-cloudy-night' %}
  372. /local/animated/partly-cloudy-night.svg
  373. {% elif cond == 'lightning' %}
  374. /local/animated/thunder.svg
  375. {% elif cond == 'snowy_rainy' %}
  376. /local/animated/sleet.svg
  377. {% elif cond == 'sunny' %}
  378. /local/animated/clear-day.svg
  379. {% elif cond == 'hail' %}
  380. /local/animated/rainy-6.svg
  381. {% endif %}
  382. alignment: center
  383. card_mod:
  384. style: |
  385. ha-card {
  386. opacity: 0.8;
  387. --chip-background: transparent !important;
  388. --chip-height: 50px;
  389. padding-top: 0px !important;
  390. padding-bottom: 0px !important;
  391. margin-top: -10px !important;
  392. margin-bottom: -10px !important;
  393. }
  394. - type: custom:mushroom-template-card
  395. primary: >-
  396. {{
  397. state_attr('sensor.pirate_weather_daily','forecast')[3].temperature
  398. }}° |‎ ‎{{ states('sensor.forecast_low_pirate_day_4') }}°
  399. secondary: ''
  400. icon: ''
  401. card_mod:
  402. style:
  403. mushroom-state-info$: |
  404. .container {
  405. --card-primary-font-size: 16px;
  406. align-items: center;
  407. }
  408. .: |
  409. ha-card {
  410. opacity: 0.8;
  411. background: transparent !important;
  412. padding-top: 0px !important;
  413. padding-bottom: 0px !important;
  414. margin-top: -15px !important;
  415. margin-bottom: -10px !important;
  416. }
  417. - type: vertical-stack
  418. cards:
  419. - type: custom:mushroom-template-card
  420. primary: >-
  421. {{
  422. as_timestamp(state_attr('sensor.pirate_weather_daily','forecast')[4].datetime)
  423. | timestamp_custom('%a %-d') }}
  424. secondary: ''
  425. icon: ''
  426. card_mod:
  427. style:
  428. mushroom-state-info$: |
  429. .container {
  430. --card-primary-font-size: 12px;
  431. align-items: center;
  432. }
  433. .: |
  434. ha-card {
  435. background-color: transparent;
  436. opacity: 0.9;
  437. padding-top: 0px !important;
  438. padding-bottom: 0px !important;
  439. margin-top: -0px !important;
  440. margin-bottom: -10px !important;
  441. }
  442. - type: custom:mushroom-chips-card
  443. chips:
  444. - type: template
  445. content: ''
  446. picture: >-
  447. {% set cond =
  448. (state_attr('sensor.pirate_weather_daily','forecast')[4].condition)
  449. %} {% if cond == 'clear-day' %}
  450. /local/animated/clear-day.svg
  451. {% elif cond == 'clear-night' %}
  452. /local/animated/clear-night.svg
  453. {% elif cond == 'rainy' %}
  454. /local/animated/rainy-6.svg
  455. {% elif cond == 'rain' %}
  456. /local/animated/rainy-6.svg
  457. {% elif cond == 'snowy' %}
  458. /local/animated/snow.svg
  459. {% elif cond == 'snow' %}
  460. /local/animated/snow.svg
  461. {% elif cond == 'sleet' %}
  462. /local/animated/sleet.svg
  463. {% elif cond == 'windy' %}
  464. /local/animated/wind.svg
  465. {% elif cond == 'wind' %}
  466. /local/animated/wind.svg
  467. {% elif cond == 'fog' %}
  468. /local/animated/fog.svg
  469. {% elif cond == 'cloudy' %}
  470. /local/animated/cloudy.svg
  471. {% elif cond == 'partlycloudy' %}
  472. /local/animated/partly-cloudy-day_old.svg
  473. {% elif cond == 'partly-cloudy-day' %}
  474. /local/animated/partly-cloudy-day_old.svg
  475. {% elif cond == 'partly-cloudy-night' %}
  476. /local/animated/partly-cloudy-night.svg
  477. {% elif cond == 'lightning' %}
  478. /local/animated/thunder.svg
  479. {% elif cond == 'snowy_rainy' %}
  480. /local/animated/sleet.svg
  481. {% elif cond == 'sunny' %}
  482. /local/animated/clear-day.svg
  483. {% elif cond == 'hail' %}
  484. /local/animated/rainy-6.svg
  485. {% endif %}
  486. alignment: center
  487. card_mod:
  488. style: |
  489. ha-card {
  490. opacity: 0.8;
  491. --chip-background: transparent !important;
  492. --chip-height: 50px;
  493. padding-top: 0px !important;
  494. padding-bottom: 0px !important;
  495. margin-top: -10px !important;
  496. margin-bottom: -10px !important;
  497. }
  498. - type: custom:mushroom-template-card
  499. primary: >-
  500. {{
  501. state_attr('sensor.pirate_weather_daily','forecast')[4].temperature
  502. }}° |‎ ‎{{ states('sensor.forecast_low_pirate_day_5') }}°
  503. secondary: ''
  504. icon: ''
  505. card_mod:
  506. style:
  507. mushroom-state-info$: |
  508. .container {
  509. --card-primary-font-size: 16px;
  510. align-items: center;
  511. }
  512. .: |
  513. ha-card {
  514. opacity: 0.8;
  515. background: transparent !important;
  516. padding-top: 0px !important;
  517. padding-bottom: 0px !important;
  518. margin-top: -15px !important;
  519. margin-bottom: -10px !important;
  520. }
  521. - type: vertical-stack
  522. cards:
  523. - type: custom:mushroom-template-card
  524. primary: >-
  525. {{
  526. as_timestamp(state_attr('sensor.pirate_weather_daily','forecast')[5].datetime)
  527. | timestamp_custom('%a %-d') }}
  528. secondary: ''
  529. icon: ''
  530. card_mod:
  531. style:
  532. mushroom-state-info$: |
  533. .container {
  534. --card-primary-font-size: 12px;
  535. align-items: center;
  536. }
  537. .: |
  538. ha-card {
  539. background-color: transparent;
  540. opacity: 0.9;
  541. padding-top: 0px !important;
  542. padding-bottom: 0px !important;
  543. margin-top: -0px !important;
  544. margin-bottom: -10px !important;
  545. }
  546. - type: custom:mushroom-chips-card
  547. chips:
  548. - type: template
  549. content: ''
  550. picture: >-
  551. {% set cond =
  552. (state_attr('sensor.pirate_weather_daily','forecast')[5].condition)
  553. %} {% if cond == 'clear-day' %}
  554. /local/animated/clear-day.svg
  555. {% elif cond == 'clear-night' %}
  556. /local/animated/clear-night.svg
  557. {% elif cond == 'rainy' %}
  558. /local/animated/rainy-6.svg
  559. {% elif cond == 'rain' %}
  560. /local/animated/rainy-6.svg
  561. {% elif cond == 'snowy' %}
  562. /local/animated/snow.svg
  563. {% elif cond == 'snow' %}
  564. /local/animated/snow.svg
  565. {% elif cond == 'sleet' %}
  566. /local/animated/sleet.svg
  567. {% elif cond == 'windy' %}
  568. /local/animated/wind.svg
  569. {% elif cond == 'wind' %}
  570. /local/animated/wind.svg
  571. {% elif cond == 'fog' %}
  572. /local/animated/fog.svg
  573. {% elif cond == 'cloudy' %}
  574. /local/animated/cloudy.svg
  575. {% elif cond == 'partlycloudy' %}
  576. /local/animated/partly-cloudy-day_old.svg
  577. {% elif cond == 'partly-cloudy-day' %}
  578. /local/animated/partly-cloudy-day_old.svg
  579. {% elif cond == 'partly-cloudy-night' %}
  580. /local/animated/partly-cloudy-night.svg
  581. {% elif cond == 'lightning' %}
  582. /local/animated/thunder.svg
  583. {% elif cond == 'snowy_rainy' %}
  584. /local/animated/sleet.svg
  585. {% elif cond == 'sunny' %}
  586. /local/animated/clear-day.svg
  587. {% elif cond == 'hail' %}
  588. /local/animated/rainy-6.svg
  589. {% endif %}
  590. alignment: center
  591. card_mod:
  592. style: |
  593. ha-card {
  594. opacity: 0.8;
  595. --chip-background: transparent !important;
  596. --chip-height: 50px;
  597. padding-top: 0px !important;
  598. padding-bottom: 0px !important;
  599. margin-top: -10px !important;
  600. margin-bottom: -10px !important;
  601. }
  602. - type: custom:mushroom-template-card
  603. primary: >-
  604. {{
  605. state_attr('sensor.pirate_weather_daily','forecast')[5].temperature
  606. }}° |‎ ‎{{ states('sensor.forecast_low_pirate_day_6') }}°
  607. secondary: ''
  608. icon: ''
  609. card_mod:
  610. style:
  611. mushroom-state-info$: |
  612. .container {
  613. --card-primary-font-size: 16px;
  614. align-items: center;
  615. }
  616. .: |
  617. ha-card {
  618. opacity: 0.8;
  619. background: transparent !important;
  620. padding-top: 0px !important;
  621. padding-bottom: 0px !important;
  622. margin-top: -15px !important;
  623. margin-bottom: -10px !important;
  624. }
  625. - type: vertical-stack
  626. cards:
  627. - type: custom:mushroom-template-card
  628. primary: >-
  629. {{
  630. as_timestamp(state_attr('sensor.pirate_weather_daily','forecast')[6].datetime)
  631. | timestamp_custom('%a %-d') }}
  632. secondary: ''
  633. icon: ''
  634. card_mod:
  635. style:
  636. mushroom-state-info$: |
  637. .container {
  638. --card-primary-font-size: 12px;
  639. align-items: center;
  640. }
  641. .: |
  642. ha-card {
  643. background-color: transparent;
  644. opacity: 0.9;
  645. padding-top: 0px !important;
  646. padding-bottom: 0px !important;
  647. margin-top: -0px !important;
  648. margin-bottom: -10px !important;
  649. }
  650. - type: custom:mushroom-chips-card
  651. chips:
  652. - type: template
  653. content: ''
  654. picture: >-
  655. {% set cond =
  656. (state_attr('sensor.pirate_weather_daily','forecast')[6].condition)
  657. %} {% if cond == 'clear-day' %}
  658. /local/animated/clear-day.svg
  659. {% elif cond == 'clear-night' %}
  660. /local/animated/clear-night.svg
  661. {% elif cond == 'rainy' %}
  662. /local/animated/rainy-6.svg
  663. {% elif cond == 'rain' %}
  664. /local/animated/rainy-6.svg
  665. {% elif cond == 'snowy' %}
  666. /local/animated/snow.svg
  667. {% elif cond == 'snow' %}
  668. /local/animated/snow.svg
  669. {% elif cond == 'sleet' %}
  670. /local/animated/sleet.svg
  671. {% elif cond == 'windy' %}
  672. /local/animated/wind.svg
  673. {% elif cond == 'wind' %}
  674. /local/animated/wind.svg
  675. {% elif cond == 'fog' %}
  676. /local/animated/fog.svg
  677. {% elif cond == 'cloudy' %}
  678. /local/animated/cloudy.svg
  679. {% elif cond == 'partlycloudy' %}
  680. /local/animated/partly-cloudy-day_old.svg
  681. {% elif cond == 'partly-cloudy-day' %}
  682. /local/animated/partly-cloudy-day_old.svg
  683. {% elif cond == 'partly-cloudy-night' %}
  684. /local/animated/partly-cloudy-night.svg
  685. {% elif cond == 'lightning' %}
  686. /local/animated/thunder.svg
  687. {% elif cond == 'snowy_rainy' %}
  688. /local/animated/sleet.svg
  689. {% elif cond == 'sunny' %}
  690. /local/animated/clear-day.svg
  691. {% elif cond == 'hail' %}
  692. /local/animated/rainy-6.svg
  693. {% endif %}
  694. alignment: center
  695. card_mod:
  696. style: |
  697. ha-card {
  698. opacity: 0.8;
  699. --chip-background: transparent !important;
  700. --chip-height: 50px;
  701. padding-top: 0px !important;
  702. padding-bottom: 0px !important;
  703. margin-top: -10px !important;
  704. margin-bottom: -10px !important;
  705. }
  706. - type: custom:mushroom-template-card
  707. primary: >-
  708. {{
  709. state_attr('sensor.pirate_weather_daily','forecast')[6].temperature
  710. }}° |‎ ‎{{ states('sensor.forecast_low_pirate_day_7') }}°
  711. secondary: ''
  712. icon: ''
  713. card_mod:
  714. style:
  715. mushroom-state-info$: |
  716. .container {
  717. --card-primary-font-size: 16px;
  718. align-items: center;
  719. }
  720. .: |
  721. ha-card {
  722. opacity: 0.8;
  723. background: transparent !important;
  724. padding-top: 0px !important;
  725. padding-bottom: 0px !important;
  726. margin-top: -15px !important;
  727. margin-bottom: -10px !important;
  728. }
  729. - type: custom:apexcharts-card
  730. graph_span: 7d
  731. span:
  732. start: day
  733. experimental:
  734. color_threshold: true
  735. now:
  736. show: true
  737. color: grey
  738. apex_config:
  739. legend:
  740. show: false
  741. chart:
  742. height: 120
  743. zoom:
  744. enabled: true
  745. xaxis:
  746. labels:
  747. show: false
  748. yaxis:
  749. max: 100
  750. labels:
  751. show: false
  752. grid:
  753. strokeDashArray: 0
  754. borderColor: grey
  755. xaxis:
  756. lines:
  757. show: true
  758. yaxis:
  759. lines:
  760. show: false
  761. series:
  762. - entity: sensor.pirate_weather_hourly
  763. type: line
  764. name: Pirate Forecast Temp
  765. stroke_width: 2
  766. fill_raw: last
  767. color_threshold:
  768. - value: 32
  769. color: '#0066ff'
  770. - value: 40
  771. color: '#00ffff'
  772. - value: 50
  773. color: '#00ffa6'
  774. - value: 60
  775. color: '#00ff08'
  776. - value: 70
  777. color: '#91ff00'
  778. - value: 80
  779. color: '#fff700'
  780. - value: 85
  781. color: '#ffc400'
  782. - value: 95
  783. color: '#ff0800'
  784. - value: 100
  785. color: '#ae00ff'
  786. data_generator: |
  787. return entity.attributes.forecast.map((entry) => {
  788. return [new Date(entry.datetime), entry.apparent_temperature];
  789. });
  790. - entity: sensor.pirate_weather_hourly
  791. type: area
  792. stroke_width: 0
  793. color: rgb(56, 158, 209)
  794. name: Pirate Forecast Precip
  795. data_generator: |
  796. return entity.attributes.forecast.map((entry) => {
  797. return [new Date(entry.datetime), entry.precipitation_probability];
  798. });
  799. - entity: weather.nws_hourly
  800. type: area
  801. stroke_width: 0
  802. name: NWS Forecast Precip
  803. color: rgba(100, 200, 255, 1)
  804. opacity: 0.3
  805. data_generator: |
  806. return entity.attributes.forecast.map((entry) => {
  807. return [new Date(entry.datetime), entry.precipitation_probability];
  808. });
  809. - entity: sensor.pirate_weather_hourly
  810. type: area
  811. name: Pirate Forecast Cloud Cover
  812. color: grey
  813. opacity: 0.3
  814. stroke_width: 0
  815. data_generator: |
  816. return entity.attributes.forecast.map((entry) => {
  817. return [new Date(entry.datetime), entry.cloud_coverage];
  818. });
  819. - entity: sensor.current_temp
  820. type: line
  821. name: Current Temp
  822. fill_raw: last
  823. color_threshold:
  824. - value: 32
  825. color: '#0066ff'
  826. - value: 40
  827. color: '#00ffff'
  828. - value: 50
  829. color: '#00ffa6'
  830. - value: 60
  831. color: '#00ff08'
  832. - value: 70
  833. color: '#91ff00'
  834. - value: 80
  835. color: '#fff700'
  836. - value: 85
  837. color: '#ffc400'
  838. - value: 95
  839. color: '#ff0800'
  840. - value: 100
  841. color: '#ae00ff'
  842. extend_to: now
  843. stroke_width: 2
  844. opacity: 0.7
  845. - entity: sensor.pirate_historical_cloud_cover
  846. type: area
  847. name: Patio Temp
  848. fill_raw: last
  849. color: grey
  850. extend_to: now
  851. stroke_width: 0
  852. opacity: 0.2
  853. - entity: sensor.pirate_historical_precip_prob
  854. type: area
  855. name: Patio Temp
  856. fill_raw: last
  857. color: rgb(56, 158, 209)
  858. extend_to: now
  859. stroke_width: 0
  860. opacity: 0.2
  861. - entity: sensor.nws_historical_precip_prob
  862. type: area
  863. name: Patio Temp
  864. fill_raw: last
  865. color: rgba(100, 200, 255, 1)
  866. extend_to: now
  867. stroke_width: 0
  868. opacity: 0.2
  869. view_layout:
  870. position: sidebar
  871. card_mod:
  872. style: |
  873. ha-card {
  874. background-color: transparent;
  875. margin-top: -25px;
  876. margin-left: -10px;
  877. margin-bottom: -15px;
  878. }
  879.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement