Coder Social home page Coder Social logo

fuzzymistborn / mm2-clock-card Goto Github PK

View Code? Open in Web Editor NEW

This project forked from shbatm/mm2-clock-card

0.0 0.0 0.0 421 KB

A Simple Digital/Analog Clock Card for Home Assistant Lovelace

License: MIT License

TypeScript 94.21% JavaScript 5.79%

mm2-clock-card's Introduction

MM2 Clock Card by @shbatm

Digital/Analog Clock Card for Home Assistant Lovelace based on the MagicMirror2 Clock

This is a direct port of the MagicMirror2 Clock to TypeScript and the Home Assistant card. Credit goes to the original contributers to that project and module.

Screenshot

Screenshot

Options

The following properties can be configured:

Option Description
timeFormat Use 12 or 24 hour format.

Possible values: 12 or 24
Default value: uses value of config.timeFormat
displaySeconds Display seconds.

Possible values: true or false
Default value: true
showPeriod Show the period (am/pm) with 12 hour format.

Possible values: true or false
Default value: true
showPeriodUpper Show the period (AM/PM) with 12 hour format as uppercase.

Possible values: true or false
Default value: false
clockBold Remove the colon and bold the minutes to make a more modern look.

Possible values: true or false
Default value: false
showDate Turn off or on the Date section.

Possible values: true or false
Default value: true
showWeek Turn off or on the Week section.

Possible values: true or false
Default value: false
dateFormat Configure the date format as you like.

Possible values: Docs
Default value: "dddd, LL"
displayType Display a digital clock, analog clock, or both together.

Possible values: digital, analog, or both
Default value: digital
analogSize Specific to the analog clock. Defines how large the analog display is.

Possible values: A positive number of pixels<br> **Default value:**200px`
analogFace Specific to the analog clock. Specifies which clock face to use.

Possible values: simple for a simple border, none for no face or border, or face-### (where ### is currently a value between 001 and 012, inclusive)
Default value: simple
secondsColor Specific to the analog clock. Specifies what color to make the 'seconds' hand.

Possible values: any HTML RGB Color
Default value: #888888
analogPlacement Specific to the analog clock. (requires displayType set to 'both') Specifies where the analog clock is in relation to the digital clock

Possible values: top, right, bottom, or left
Default value: bottom
analogShowDate Specific to the analog clock. If the clock is used as a separate module and set to analog only, this configures whether a date is also displayed with the clock.

Possible values: false, top, or bottom
Default value: top
timezone Specific a timezone to show clock.

Possible examples values: America/New_York, America/Santiago, Etc/GMT+10
Default value: none. See more informations about configuration value here

Installation

Download the 'download.zip' folder from the latest release and store it in your configuration/www folder.

Configure Lovelace to load the card:

resources:
  - url: /local/mm2-clock-card.js
    type: module

mm2-clock-card's People

Contributors

iantrich avatar ljmerza avatar ludeeus avatar nlighteneddesign avatar shbatm 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.