Git Product home page Git Product logo

timepicker.js's Introduction

JavaScript Realtime Analog Clock/Timepicker Library

DOI: 10.5281/zenodo.2600135

Overview

This widget can be used to display a Realtime Analog Clock besides as a Timepicker. As a timepicker, this widget can be directly draggable at both hour hand and minute hand. Drag at behind the axis of both hands which causes reverse rotation is also supported. Dragging on touch devices are supported well. Dragging at the both clock hands are very smoothly, no matter how much angle of rotation have been made by your finger or mouse pointer, over there the appropriate hand will point at without lagging nor leading even a little.

Demo

Demo here.

Dependencies

No dependencies even css file.

Usage

Simply put this code snippet to anywhere you want in the body of your html file:

Offline

<div id="timepicker"></div>
<script type="text/javascript" src="timepicker.js"></script>
<script type="text/javascript">
    let timepicker = new Timepicker();
    document.getElementById('timepicker').appendChild(timepicker.getElement());
    // or use
    // timepicker.attachTo(document.getElementById('timepicker'));
    // other code
</script>

Online

<div id="timepicker"></div>
<script type="text/javascript" src="https://zulns.github.io/Timepicker.js/timepicker.js"></script>
<script type="text/javascript">
    let timepicker = new Timepicker();
    document.getElementById('timepicker').appendChild(timepicker.getElement());
    // or use
    // timepicker.attachTo(document.getElementById('timepicker'));
    // other code
</script>

API Documentation

API doc here.

 

 

 


Designed By ZulNs

@Gorontalo, 25 February 2019

timepicker.js's People

Contributors

zulns avatar

Stargazers

 avatar Devashish P. avatar shariq mohammad avatar Cat  avatar Andy Maleh avatar  avatar 品足论头 avatar David Thompson avatar

Watchers

James Cloos avatar  avatar

timepicker.js's Issues

Simple implementation question

Is there anything else to make it work besides adding the few lines of code and uploading the js file? No css file?
Because it doesn't seem to work on my page. What should I double check?

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.