I created a card with swiper, that lets you flick through multiple cards.
You can use (almost?) all options of swiper, these can be found here.
More info can be found in the repo: https://github.com/bramkragten/custom-ui/tree/master/swipe-card
A few config examples:
Full width cards with scrollbar:
- type: custom:swipe-card
parameters:
spaceBetween: 8
scrollbar:
hide: false
draggable: true
snapOnRelease: true
cards:
- type: sensor
entity: sensor.temperature_158d0001720278
name: Temperatuur
line_width: 8
line_color: '#FF6384'
- type: sensor
entity: sensor.humidity_158d0001720278
name: Luchtvochtigheid
line_color: '#36A2EB'
line_width: 8
- type: sensor
entity: sensor.illumination_f0b429cc4c88
name: Licht
line_color: '#ffce57'
line_width: 8
- type: sensor
entity: sensor.pressure_158d0001720278
name: Druk
line_color: "#4BC0C0"
accuracy: 8
line_width: 8
Coverflow with pagination:
- type: custom:swipe-card
card_width: '185px'
start_card: 2
parameters:
effect: 'coverflow'
grabCursor: true
centeredSlides: true
slidesPerView: 'auto'
coverflowEffect:
rotate: 50
stretch: 0
depth: 100
modifier: 1
slideShadows : true
pagination:
type: 'bullets'
cards:
- type: sensor
entity: sensor.temperature_158d0001720278
name: Temperatuur
line_width: 8
line_color: '#FF6384'
- type: sensor
entity: sensor.humidity_158d0001720278
name: Luchtvochtigheid
line_color: '#36A2EB'
line_width: 8
- type: sensor
entity: sensor.illumination_f0b429cc4c88
name: Licht
line_color: '#ffce57'
line_width: 8
- type: sensor
entity: sensor.pressure_158d0001720278
name: Druk
line_color: "#4BC0C0"
accuracy: 8
line_width: 8
Navigation, keyboard and progressbar:
- type: custom:swipe-card
card_width: '80%'
parameters:
centeredSlides: true
slidesPerView: 'auto'
spaceBetween: 8
pagination:
type: 'progressbar'
navigation:
keyboard:
enabled: true
onlyInViewport: true
cards:
- type: sensor
entity: sensor.temperature_158d0001720278
name: Temperatuur
line_width: 8
line_color: '#FF6384'
- type: sensor
entity: sensor.humidity_158d0001720278
name: Luchtvochtigheid
line_color: '#36A2EB'
line_width: 8
- type: sensor
entity: sensor.illumination_f0b429cc4c88
name: Licht
line_color: '#ffce57'
line_width: 8
- type: sensor
entity: sensor.pressure_158d0001720278
name: Druk
line_color: "#4BC0C0"
accuracy: 8
line_width: 8
Default:
- type: custom:swipe-card
cards:
- type: sensor
entity: sensor.temperature_158d0001720278
name: Temperatuur
line_width: 8
line_color: '#FF6384'
- type: sensor
entity: sensor.humidity_158d0001720278
name: Luchtvochtigheid
line_color: '#36A2EB'
line_width: 8
- type: sensor
entity: sensor.illumination_f0b429cc4c88
name: Licht
line_color: '#ffce57'
line_width: 8
- type: sensor
entity: sensor.pressure_158d0001720278
name: Druk
line_color: "#4BC0C0"
accuracy: 8
line_width: 8
Place swipe-card.js in /config/www/custom-lovelace/swipe-card/
- url: /local/custom-lovelace/swipe-card/swipe-card.js?v=3.0.0
type: module
Optional: add to custom_updater:
https://raw.githubusercontent.com/bramkragten/custom-ui/master/updater.json