All Projects β†’ gregzhang616 β†’ jquery-datepicker

gregzhang616 / jquery-datepicker

Licence: MIT license
A full-featured datepicker jquery plugin

Programming Languages

javascript
184084 projects - #8 most used programming language
CSS
56736 projects
HTML
75241 projects

Projects that are alternatives of or similar to jquery-datepicker

Angular Bootstrap Datetimepicker
Native Angular date/time picker component styled by Twitter Bootstrap
Stars: ✭ 1,289 (+3582.86%)
Mutual labels:  datetime, datepicker, picker
Pg Calendar
πŸ“† beautiful and eidetic date picker
Stars: ✭ 109 (+211.43%)
Mutual labels:  jquery-plugin, datetime, datepicker
Vuetify Daterange Picker
The missing date range picker for Vuetify JS you have been looking for.
Stars: ✭ 192 (+448.57%)
Mutual labels:  datepicker, range, picker
Horizontalpicker
DatePicker horizontal con selecciΓ³n smooth por dΓ­a para Android.
Stars: ✭ 116 (+231.43%)
Mutual labels:  datetime, datepicker, picker
Tempus Dominus
A powerful Date/time picker widget.
Stars: ✭ 6,900 (+19614.29%)
Mutual labels:  datetime, datepicker, picker
Persianrangedatepicker
Persian range date picker for android.
Stars: ✭ 48 (+37.14%)
Mutual labels:  datepicker, range, picker
Rc Datetime Picker
React component for datetime picker by Moment.js
Stars: ✭ 85 (+142.86%)
Mutual labels:  datetime, datepicker, picker
Vue Ctk Date Time Picker
VueJS component to select dates & time, including a range mode
Stars: ✭ 707 (+1920%)
Mutual labels:  datepicker, range, picker
react-calendar-datetime-picker
A simple and fast date and time picker component for React
Stars: ✭ 58 (+65.71%)
Mutual labels:  datetime, datepicker, picker
Angular Moment Picker
Angular Moment Picker is an AngularJS directive for date and time picker using Moment.js.
Stars: ✭ 536 (+1431.43%)
Mutual labels:  datetime, datepicker, picker
Lightpick
(deprecated) Check out the new date picker Litepicker
Stars: ✭ 204 (+482.86%)
Mutual labels:  datepicker, range, picker
Circularpicker
CircularPicker is helpful for creating a controller aimed to manage any calculated parameter.
Stars: ✭ 73 (+108.57%)
Mutual labels:  datetime, datepicker, picker
imrc-datetime-picker
(Improved) React component datetime picker by momentjs πŸ“†
Stars: ✭ 21 (-40%)
Mutual labels:  datetime, datepicker, picker
Datetimepicker
jQuery Plugin Date and Time Picker
Stars: ✭ 3,402 (+9620%)
Mutual labels:  jquery-plugin, datepicker, picker
Chocobo-Date-Range-Picker
πŸ—“οΈ Component - The Date Range Picker easier to use in AngularJS.
Stars: ✭ 23 (-34.29%)
Mutual labels:  range, picker, rangedate
Exceptionless.datetimeextensions
DateTimeRange, Business Day and various DateTime, DateTimeOffset, TimeSpan extension methods
Stars: ✭ 142 (+305.71%)
Mutual labels:  datetime, range
Date Picker
πŸ“… Custom responsive date picker widget for Android, written in Kotlin.
Stars: ✭ 146 (+317.14%)
Mutual labels:  datetime, picker
Flatpickr
lightweight, powerful javascript datetimepicker with no dependencies
Stars: ✭ 14,575 (+41542.86%)
Mutual labels:  datetime, datepicker
Vue Smooth Picker
πŸ„πŸΌ A SmoothPicker for Vue 2 (like native datetime picker of iOS)
Stars: ✭ 188 (+437.14%)
Mutual labels:  datetime, picker
Colorpicker
jQuery UI widget for color picking (similar to the one in Microsoft Office 2010).
Stars: ✭ 271 (+674.29%)
Mutual labels:  jquery-plugin, picker

Date Image Gemini DatePicker

A full-featured datepicker jquery plugin.

Features

  • Supports more configurable options.
  • Supports more methods
  • Supports more events
  • Supports datetime mode
  • Supports range date and range datetime mode
  • Supports internationalization
  • Cross-browser support

Example image

Type: date

Date Image

Type: month

Year Image

Type: year

Month Image

Type: datetime

Datetime Image

Type: date-range

Date range Image

Type: datetime-range

Datetime range Image

Getting started

Quick start

Installation

Include files:

Css file

<link rel="stylesheet" href="https://github.com/assets/css/iconfont.css">
<link rel="stylesheet" href="https://github.com/css/jquery.datepicker.min.css">

Javascript file

<script src="https://github.com/assets/js/jquery.min.js"></script>
<script src="https://github.com/js/jquery.datepicker.min.js"></script>
// there is no need to import the next line of code when current language is 'en-US'
<script src="https://github.com/i18n/datepicker.zh-CN.js"></script>
CommonJs / NodeJs:

Css file

require('gemini-datepicker/dist/css/jquery.datepicker.min.css');

Javascript file

require('gemini-datepicker');

Attributes

You may set datepicker options with $().datepicker(options), the options type is Object.

Name Type Default value Optional value Description
type String 'date' year/month/date/datetime/datetime-range/date-range type of the picker
readonly Boolean false false/ true whether DatePicker is read only
disabled Boolean false false/ true whether DatePicker is disabled
format String 'yyyy-MM-dd' year->yyyy, month->MM, day->dd, hour->HH, minute->mm, second->ss format of the picker
placeholder String 'Please pick a day' -- init input element's placeholder
align String 'left' 'left'/'center'/'right' the pick panel's alignment
weekStart Number 0 -- Start of the week
startDate Date null -- If the start date exists, the date before the start date is disabled
endDate Date null -- If the end date exists, the date after the end date is disabled
lang String 'en-US' 'en-US'/'zh-CN'/'vi' language of the datepicker
rangeSeparator String '-' -- if type is 'date-range' or 'datetime-range', use rangeSeparator to separate the date
defaultValue String/Date '' -- default date, if picker type is date-range or datetime-range, picker's type must be String
zIndex Number 2008 -- The CSS style z-index for the picker.

Methods

Common usage

$().datepicker(methodName, argument1, argument2, ..., argumentN);
setDate(date)

Set the current date with a new date, parameter date type is String or Date .

$().datepicker('setDate', '2016-02-09');
$().datepicker('setDate', new Date(2016, 1, 9));
getDate()

Get the current date.

$().datepicker('getDate');
clear()

Clear the picker date (when date is cleared, the current date is displayed by default).

$().datepicker('clear');
show()

Show the picker panel.

$().datepicker('show');
hide()

hide the picker panel.

$().datepicker('hide');
disable(value)

disable or enable the picker, if parameter value is true that can disable the picker, otherwise can enable the picker.

// disable the picker
$().datepicker('disable', true);
// enable the picker
$().datepicker('disable', false);
destroy()

Destroy the picker and remove the instance from target element.

$().datepicker('destroy');

Events

Common usage

$().on(eventName, function (e, arguments) {
  // todo
});
pick.datepicker

This event fires when date is changed.

  • event ( Type: Object )
    • newDate ( Type: String )
    • oldDate ( Type: String )
$().on('pick.datepicker', function (event) {
  console.log('newDate: ' + event.newDate);
  console.log('oldDate: ' + event.oldDate);
});
show.datepicker

This event fires when picker is show.

$().on('show.datepicker', function (e) {
  // todo
});
hide.datepicker

This event fires when picker is hide.

$().on('hide.datepicker', function (e) {
  // todo
});

Callbacks

Common usage

$().datepicker({
    CallbackName: function () {
      // todo
    }
});
onChange

A shortcut of the "pick.datepicker" event, this callback called when picker value is changed.

$().datepicker({
    onChange: function (events) {
      console.log('newDate: ' + event.newDate);
      console.log('oldDate: ' + event.oldDate);
    }
});
onShow

A shortcut of the "show.datepicker" event, this callback called when picker is show.

$().datepicker({
    onShow: function () {
      // todo
    }
});
onHide

A shortcut of the "hide.datepicker" event, this callback called when picker is hide.

$().datepicker({
    onHide: function () {
      // todo
    }
});

Locale

I18n config, default language is en-US

Usage
<script src="https://github.com/js/jquery.datepicker.min.js"></script>
<script src="https://github.com/i18n/datepicker.zh-CN.js"></script>
<script>
  $().datepicker({
    lang: 'zh-CN'
  });
</script>  

Run example

Please download the project, and then enter into this directory.(download gulp-sass plugin need to connect vpn)

Browser support

  • Chrome Most versions
  • Firefox Most versions
  • Safari Most versions
  • Opera Most versions
  • Edge Most versions
  • Internet Explorer 8+

Author

Greg Zhang from Baidu ([email protected]).

Remarks

Thanks for the eleme UED team to provide such a good UI design.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].