本帖最后由 咸味土豆 于 2019-8-7 10:26 编辑
更一下:用slideshow-card插件或者swipe-card配置一下效果会好一点
- type: custom:slideshow-card
fill: true
auto_play: true
auto_delay: 15
arrow_color: var(--primary-text-color)
arrow_opacity: .7
style: |
ha-card {
font-variant: small-caps;
background-color: #fafafa;
box-shadow: none;
margin: 4px 6px 8px 10px;
background-color: rgba(255,255,255, 0);
border: solid 1px rgba(14,27,32, 0);
border-radius: 0px
}
.card-header {
font-size: 15px;
color: rgb(37,129,171);
}
cards:
- type: entities #glance
column_width: 50%
style: |
ha-card {
font-variant: small-caps;
background-color: #fafafa;
box-shadow: none;
margin: 4px 6px 8px 10px;
background-color: rgba(255,255,255, 0);
border: solid 5px rgba(14,27,32, 0);
border-radius: 5px
}
.card-header {
font-size: 15px;
color: rgb(37,129,171);
}
entities:
- type: custom:upcoming-media-card
entity: sensor.kodi_recently_added_movies
# title: 新加入电影
image_style: fanart
- type: entities #glance
column_width: 50%
style: |
ha-card {
font-variant: small-caps;
background-color: #fafafa;
box-shadow: none;
margin: 4px 6px 8px 10px;
background-color: rgba(255,255,255, 0);
border: solid 5px rgba(14,27,32, 0);
border-radius: 5px
}
.card-header {
font-size: 15px;
color: rgb(37,129,171);
}
entities:
- type: custom:upcoming-media-card
entity: sensor.kodi_recently_added_tv
# title: 新加入剧集
image_style: fanart
先上效果
依赖插件
configuration.yaml配置
##根据实际情况修改
sensor:
- platform: kodi_recently_added
# username: kodi
host: 10.16.100.29
# password: YOUR_KODI_PASSWORD
port: 8089
ui-lovelace.yaml配置
- type: custom:upcoming-media-card
entity: sensor.kodi_recently_added_tv
title: 新加入剧集
image_style: fanart
- type: custom:upcoming-media-card
entity: sensor.kodi_recently_added_movies
title: 新加入电影
image_style: fanart
瞎玩玩,勿喷。
|