GithubHelp home page GithubHelp logo

chrisway / lovelace-mushroom Goto Github PK

View Code? Open in Web Editor NEW

This project forked from piitaya/lovelace-mushroom

0.0 0.0 0.0 1.95 MB

Mushroom Cards - Build a beautiful dashboard easily πŸ„

License: Apache License 2.0

JavaScript 0.49% TypeScript 99.51%

lovelace-mushroom's Introduction

πŸ„ Mushroom

hacs release downloads build

Buy Me A Coffee

Overview

What is mushroom ?

Mushroom is a collection of cards for Home Assistant Dashboard UI.

Mushroom mission is to propose easy to use components to build your Home Assistant dashboard.

Features

  • πŸ›  Editor for all cards and and all options (no need to edit yaml)
  • 😍 Icon picker
  • πŸ–Œ Color picker
  • πŸš€ 0 dependencies : no need to install another card.
  • 🌈 Based on Material UI colors
  • πŸŒ“ Light and dark theme support
  • 🎨 Optional theme customization
  • 🌎 Internationalization

The goal of Mushroom is not to provide custom card for deep customization. You can use the excellent UI Lovelace Minimalist and Button card plugins for this.

Installation

HACS

Mushroom is available in HACS (Home Assistant Community Store).

  1. Open HACS
  2. Go to "Frontend" section
  3. Click button with "+" icon
  4. Search for "Mushroom"

Manual

  1. Download mushroom.js file from the [latest-release].
  2. Put mushroom.js file into your config/www folder.
  3. Add reference to mushroom.js in Dashboard. There's two way to do that:
    • Using UI: Settings β†’ Dashboards β†’ More Options icon β†’ Resources β†’ Add Resource β†’ Set Url as /local/mushroom.js β†’ Set Resource type as JavaScript Module. Note: If you do not see the Resources menu, you will need to enable Advanced Mode in your User Profile
    • Using YAML: Add following code to lovelace section.
      resources:
          - url: /local/mushroom.js
            type: module

Usage

All the Mushroom cards can be configured using Dashboard UI editor.

  1. In Dashboard UI, click 3 dots in top right corner.
  2. Click Edit Dashboard.
  3. Click Plus button to add a new card.
  4. Find one of the Custom: Mushroom card in the list.

Cards

Different cards are available for differents entities :

Cards on the todo list :

  • 🌑 Climate card

Theme customization

Mushroom works without theme but you can add a theme for better experience by installing the Mushroom Themes. If you want more information about themes, check out the official Home Assistant documentation about themes.

Development server

Home assistant demo

You can run a demo instance of Home Assistant with docker by running:

npm run start:hass

Once it's done, go to Home Assistant instance http://localhost:8123 and start configuration.

Windows Users

If you are on Windows, either run the above command in Powershell, or use the below if using Command Prompt:

npm run start:hass-cmd

Development

In another terminal, install dependencies and run development server:

npm install
npm start

Server will start on port 5000.

Home assistant configuration

Once both Home Assistant and mushroom are running, you have to add a resource to Home Assistant UI:

  • Enable Advanced Mode in your profile page
  • Go to Dashboard Resources and add the ressource http://localhost:5000/mushroom.js:
    Settings β†’ Dashboards β†’ More Options icon β†’ Resources β†’ Add Resource β†’ Set URL as http://localhost:5000/mushroom.js β†’ Set Resource type as JavaScript Module.

Build

You can build the mushroom.js file in dist folder by running the build command.

npm run build

Maintainer steps to add a new language

  1. To be compatible with Home Assistant, language tags have to follow BCP 47. A list of most language tags can be found here: IANA subtag registry. Examples: fr, fr-CA, zh-Hans.
  2. Create a new file {language_code}.json with your language code in the translation folder. Examples: fr.json.
  3. Import your file into the localize.ts file and add your language in the languages record.
  4. Don't forget to test locally with the development server by choosing the language with the Home Assistant UI in your profile.

Credits

The design is inspired by 7ahang’s work on Behance and Ui Lovelace Minimalist.

lovelace-mushroom's People

Contributors

acesyde avatar acshef avatar alessandroias avatar atomikwiwa avatar bemble avatar bingooo avatar cryptooth avatar dependabot[bot] avatar doryx3d avatar dsimop avatar durgnomis-drol avatar frenck avatar giacomocarrozzo avatar gnol86 avatar golles avatar greghesp avatar hooolm avatar ldvc86 avatar madmurl0c avatar mdiazgoncalves avatar mleiber avatar piitaya avatar planecore avatar redphx avatar rhuba8324 avatar skrynklarn avatar steffenrapp avatar tomaszdom avatar ulic75 avatar wilco89 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.