Skip to content

A Lovelace card that shows the rain gauge for Home Assistant

License

Notifications You must be signed in to change notification settings

AndLindemann/rain-gauge-card

 
 

Repository files navigation

Rain Gauge Card

A Lovelace card that shows the rain gauge for Home Assistant.

GitHub Release GitHub Release Date GitHub Releases GitHub Releases

HACS Badge HomeAssistant License

Project Maintenance GitHub Activity Open bugs Open enhancements

[![Community Forum][forum-shield]][forum-link]

Installation

HACS (Home Assistant Community Store)

  1. Go to HACS page on your Home Assistant instance
  2. Select Frontend
  3. Press add icon and search for rain-gauge
  4. Select Rain Gauge Card repo and install
  5. Force refresh the Home Assistant page (Ctrl + F5)
  6. Add rain-gauge-card to your page

Open your Home Assistant instance and open a repository inside the Home Assistant Community Store.

Manual

  1. Download the 'rain-gauge-card.js' from the latest release (with right click, save link as)
  2. Place the downloaded file on your Home Assistant machine in the config/www folder (when there is no www folder in the folder where your configuration.yaml file is, create it and place the file there)
  3. In Home Assistant go to Configuration->Lovelace Dashboards->Resources (When there is no resources tag on the Lovelace Dashboard page, enable advanced mode in your account settings, and retry this step)
  4. Add a new resource
    1. Url = /local/rain-gauge-card.js
    2. Resource type = module
  5. Force refresh the Home Assistant page (Ctrl + F5)
  6. Add rain-gauge-card to your page

Using the card

  • Add the card with the visual editor
  • Or add the card manually with the following (minimal) configuration:
type: custom:rain-gauge-card
entity: sensor.rain_daily

Lovelace Examples

Default

type: custom:rain-gauge-card
entity: sensor.rain_daily

Default

Options

Name Type Requirement Description Default
type string Required custom:rain-gauge-card
name string Optional Card name Rain Gauge
border_colour string Optional Change the border colour #000000
show_error boolean Optional Show what an error looks like for the card false
show_warning boolean Optional Show what a warning looks like for the card false
entity string Required Home Assistant entity ID. none
max_level number Optional Override the max level in the drop (will take inches too) 40mm
language string Optional The 2 character that determines the language en
is_imperial boolean Optional Switch to inches (in) instead of mm false
hourly_rate_entity string Optional Home Assistant entity ID to hourly rate none
tap_action object Optional Action to take on tap action: more-info
hold_action object Optional Action to take on hold none
double_tap_action object Optional Action to take on double tap none

Action Options

Name Type Requirement Description Default
action string Required Action to perform (more-info, toggle, call-service, navigate url, none) more-info
navigation_path string Optional Path to navigate to (e.g. /lovelace/0/) when action defined as navigate none
url string Optional URL to open on click when action is url. The URL will open in a new tab none
service string Optional Service to call (e.g. media_player.media_play_pause) when action defined as call-service none
service_data object Optional Service data to include (e.g. entity_id: media_player.bedroom) when action defined as call-service none
haptic string Optional Haptic feedback success, warning, failure, light, medium, heavy, selection none
repeat number Optional How often to repeat the hold_action in milliseconds. none

Language

The following languages are supported:

Language Yaml value Supported Translated by
English en v1.0.0 @t1gr0u
French fr v1.0.0 @t1gr0u
Portuguese pt v1.1.0 @ViPeR5000
Slovenian sl v1.1.0 @mnheia

Thanks to

Support

Clone and create a PR to help make the card even better.

About

A Lovelace card that shows the rain gauge for Home Assistant

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 73.9%
  • JavaScript 26.1%