This repository has been archived on 2023-02-21. You can view files and clone it, but cannot push or open issues or pull requests.
perso-hebdo/js/pickadate.js-3.5.3/_docs/README.md

6.3 KiB
Raw Blame History

{%= pkg.name %} v{%= pkg.version %} {%= pkg.name %} build status {%= pkg.name %} dev dependencies status

{%= pkg.description %}

{% fileSize_js_core = meta.fileSize( grunt.file.read( dirs.lib.min + '/picker.js') ) fileSize_js_date = meta.fileSize( grunt.file.read( dirs.lib.min + '/picker.date.js') ) fileSize_js_time = meta.fileSize( grunt.file.read( dirs.lib.min + '/picker.time.js') ) fileSize_css_default = meta.fileSize( grunt.file.read( dirs.themes.min + '/default.css') ) fileSize_css_classic = meta.fileSize( grunt.file.read( dirs.themes.min + '/classic.css') ) fileSize_css_default_date = meta.fileSize( grunt.file.read( dirs.themes.min + '/default.date.css') ) fileSize_css_default_time = meta.fileSize( grunt.file.read( dirs.themes.min + '/default.time.css') ) fileSize_css_classic_date = meta.fileSize( grunt.file.read( dirs.themes.min + '/classic.date.css') ) fileSize_css_classic_time = meta.fileSize( grunt.file.read( dirs.themes.min + '/classic.time.css') ) fileSize_css_rtl = meta.fileSize( grunt.file.read( dirs.themes.min + '/rtl.css') ) %}

To get started, check out the:

[Homepage]({%= pkg.homepage %}) - [Date picker]({%= pkg.homepage %}/date.htm) - [Time picker]({%= pkg.homepage %}/time.htm) - [API]({%= pkg.homepage %}/api.htm)

To get it:

[Download v{%= pkg.version %}]({%= meta.gitrepo_url %}/archive/{%= pkg.version %}.zip) or git clone git://github.com/amsul/pickadate.js.git or bower install pickadate


## Upgrading from v2 to v3

The v3 API is significantly different from v2 (all for the greater good!). So if youre upgrading to v3, make sure to read the [changelog]({%= meta.gitrepo_url %}/blob/gh-pages/CHANGELOG.md).


## Library files

The {%= dirs.lib.src %} folder includes the library files with a compressed folder containing the minified counter-parts. These files are minified using Grunt.

Pickers

There are currently two pickers: date and time.

File Contents Size (min & gzip)
picker.js Base * {%= (fileSize_js_core.gzip/1024).toFixed(2) %}kb
picker.date.js Date picker {%= (fileSize_js_date.gzip/1024).toFixed(2) %}kb
picker.time.js Time picker {%= (fileSize_js_time.gzip/1024).toFixed(2) %}kb

* The base script is required for any of the pickers to function.

To support old browsers, namely IE8, also include the legacy.js file.

Themes

All themes are generated using LESS and compiled from the {%= dirs.themes.src %} folder into the {%= dirs.themes.dest %} folder.

File Contents Size (min & gzip)
default.css Base default * {%= (fileSize_css_default.gzip/1024).toFixed(2) %}kb
default.date.css Default date picker {%= (fileSize_css_default_date.gzip/1024).toFixed(2) %}kb
default.time.css Default time picker {%= (fileSize_css_default_time.gzip/1024).toFixed(2) %}kb
classic.css Base classic * {%= (fileSize_css_classic.gzip/1024).toFixed(2) %}kb
classic.date.css Classic date picker {%= (fileSize_css_classic_date.gzip/1024).toFixed(2) %}kb
classic.time.css Classic time picker {%= (fileSize_css_classic_time.gzip/1024).toFixed(2) %}kb
rtl.css RTL language stylings ** {%= (fileSize_css_rtl.gzip/1024).toFixed(2) %}kb

* One and only one base stylesheet is required. [Choose a theme]({%= pkg.homepage %}#menu) then include the respective pickers as well.

** For languages with text flowing from right-to-left, also include the rtl.css stylesheet.

Translations

The translations live in the {%= dirs.translations.src %} folder. There are currently [{%= grunt.file.expand(dirs.translations.src + '/*.js').length %} language translations]({%= meta.gitrepo_url %}/blob/{%= pkg.version %}/lib/translations) included.


## Building with Grunt

Grunt ~{%= grunt.version %} is used to build the project files. To get started, clone the project and then run:

  • npm install to get the required node modules.
  • grunt --verbose to confirm you have all the dependencies.

Read the Gruntfile to see the build tasks and relative directories of the source files.


## Styling with LESS

The picker themes are built using LESS with Grunt. To customize the CSS output, read the _variables.less file in the {%= dirs.themes.src %} folder. You can specify:

  • colors for the theme,
  • sizes for the picker,
  • media-query breakpoints,
  • and a whole bunch of other stuff.

After making any changes, run grunt less:themes to compile it into CSS.


## Versioning

To maintain some consistency in the sort of changes to expect with version bumps, Semantic Versioning guidelines will now be followed as closely as possible:

<major>.<minor>.<patch>

Constructed as such:

  • major: breaks backward compatibility (resets the minor and patch)
  • minor: new additions with backward compatibility (resets the patch)
  • patch: bug fixes and misc changes

## Bugs

Before opening a new issue, please search the existing [Issues]({%= pkg.bugs %}) for anything similar there might already be an answer to your problem. You might also wanna check out the [Contributing]({%= meta.gitrepo_url %}/blob/gh-pages/CONTRIBUTING.md) guide.


## Contributing

Before contributing any code to the project, please take a look at the [Contributing]({%= meta.gitrepo_url %}/blob/gh-pages/CONTRIBUTING.md) guide.


## Support

If you find this library useful and would like to see further development, consider supporting it.




© {%= grunt.template.date('yyyy') %} Amsul

Licensed under [{%= pkg.licenses[0].type %}]({%= pkg.licenses[0].url %})