Socket
Socket
Sign inDemoInstall

ps-input-time

Package Overview
Dependencies
0
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    ps-input-time

AngularJS time selector


Version published
Weekly downloads
2
increased by100%
Maintainers
1
Install size
17.6 kB
Created
Weekly downloads
 

Readme

Source

psInputTime

AngularJS time selector

DEMO

Angular Strap did not easily play well with other date time objects and editing the time in an INPUT was preferable to AngularUI's control.

// include js scripts
<script src="js/angular.js"></script>
<script src="js/ps-input-time.js"></script>
// add to your app
var app = angular.module('myApp', ['ps.inputTime']);
// add input
<input type="text" ng-model="myTime" ps-input-time>

Supports input formats: HHmm, hh:mmAM, HH:mm for easy keyboard input. Use arrow keys (up,down,left,right,tab) to select and adjust time.

ngModel: required, watched, date object, default: local now

fixedDay: optional, boolean, default: false. If time can move past a 24 hour restriction and adjust the day of the date object.

minuteStep: optional, numeric, default: 5. How many minutes to increase time when using the UP arrow key. The down arrow key always is 1 minute.

min/max: optional, watched, date object, forces limits. Important when fixedDay = false

If your interested please rip this apart. Looking for lessons in proper use of AngularJs, javaScript and GitHub.

ToDo

  • Wrap a popup (like AngularUI) for easy mobile input, or if possible, revert to html5 input=time for mobile.

Keywords

FAQs

Last updated on 02 Sep 2016

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc