- Navigate to your
<config>/www/
folder inside your Home Assistant installation and create a new folder namedsky-tonight-native-card
. - Manually download sky-tonight-native-card.js and
images
folder. - Place them inside the
sky-tonight-native-card
folder you created in step 1. - Add the following to your
configuration.yaml
file:
lovelace:
resources:
- url: /local/sky-tonight-native-card/sky-tonight-native-card.js
type: module
- Alternately, go to
Settings
->Dashboards
. Then in the top right corner, click the 3 dots icon and clickResources
. Click the+ Add Resource
button in the bottom right corner. Add/local/sky-tonight-native-card/sky-tonight-native-card.js
as theURL
and chooseJavaScript Module
as theResource Type
. ClickCreate
. - Finally, refresh your browser window.
Name | Type | Default | Description |
---|---|---|---|
type | string | Required | custom:sky-tonight-native-card |
title | string | Title of the card (hidden when null or empty) | |
latitude | string | Required | Latitude of the observer |
longitude | string | Required | Longitude of the observer |
elevation | number | Elevation of the observer in metres above sea level | |
time | string | Time of observation in ISO 8601 format, defaults to current time | |
showSun | boolean | true |
Set to false to hide the Sun |
onlyAboveHorizon | boolean | true |
Set to false to display all planetary bodies even if they are below the horizon |
weatherEntity | string | If a weather entity is provided, appropriate stargazing suggestions will be shown based on the weather | |
translations | dictionary | translations | Dictionary to override the default translation |
type: custom:sky-tonight-native-card
latitude: 28.627222
longitude: -80.620833
The following texts can be translated or altered.
Key | Default value |
---|---|
jan | Jan |
feb | Feb |
mar | Mar |
apr | Apr |
may | May |
jun | Jun |
jul | Jul |
aug | Aug |
sep | Sep |
oct | Oct |
nov | Nov |
dec | Dec |
above-horizon | Above Horizon |
below-horizon | Below Horizon |
sun | Sun |
mercury | Mercury |
venus | Venus |
moon | Moon |
mars | Mars |
jupiter | Jupiter |
saturn | Saturn |
uranus | Uranus |
neptune | Neptune |
pluto | Pluto |
star | Star |
planet | Planet |
dwarf-planet | Dwarf Planet |
visible-to-the-naked-eye | Visible to the naked eye |
visible-with-binoculars | Visible with binoculars |
visible-with-telescope | Visible with telescope |
nothing-to-see | Nothing to see |
no-stargazing-opportunities | No stargazing opportunities |
enjoy-your-stargazing | Enjoy your stargazing |
first-quarter | First Quarter |
full | Full Moon |
last-quarter | Last Quarter |
new | New Moon |
waning-cresent | Waning Cresent |
waning-gibbous | Waning Gibbous |
waxing-cresent | Waxing Cresent |
waxing-gibbous | Waxing Gibbous |
Example:
type: custom:sky-tonight-native-card
latitude: 28.627222
longitude: -80.620833
time: 2023-07-01T00:00:00Z
translations:
'jan' : 'January'
- Add tests
- Redesign and optimize the layout for all screen resolutions
- Use the weather entity in a better way
- Use Sun and Moon entity