Skip to content

Commit

Permalink
v.3.5.0: version bump + docs + minified files
Browse files Browse the repository at this point in the history
  • Loading branch information
amsul committed Apr 13, 2014
1 parent d65cd45 commit acd190d
Show file tree
Hide file tree
Showing 23 changed files with 124 additions and 41 deletions.
16 changes: 16 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,21 @@
# Changelog

## 3.5.0

- [#162](https://github.com/amsul/pickadate.js/issues/162): Fixed page scrolling issue when modal view is open in the default theme.
- [#350](https://github.com/amsul/pickadate.js/issues/350): Fixed Hungarian translations typo.
- [#351](https://github.com/amsul/pickadate.js/issues/351) & [#388](https://github.com/amsul/pickadate.js/issues/388) & [#393](https://github.com/amsul/pickadate.js/issues/393): Fixed issue with script freezing when `min` is `true` and “today” is disabled.
- [#358](https://github.com/amsul/pickadate.js/issues/358): Fixed parsing months as 1-indexed when value is a string.
- [#360](https://github.com/amsul/pickadate.js/issues/360): Improved Grunt script to build a cleaner project.
- [#361](https://github.com/amsul/pickadate.js/issues/361): Fixed alternate API syntax not returning the correct value.
- [#367](https://github.com/amsul/pickadate.js/issues/367): [Added a note](http://amsul.github.io/pickadate.js/date.htm#formatting-rules) on how to appropriately use the `yy` format.
- [#369](https://github.com/amsul/pickadate.js/issues/369): Added Nepali translations.
- [#377](https://github.com/amsul/pickadate.js/issues/377): Added the [`hiddenName` option](http://amsul.github.io/pickadate.js/date.htm#formats_use_hidden_only) to use the visible `input`’s name as the hidden `input`’s name.
- [#381](https://github.com/amsul/pickadate.js/issues/381): Added missing semi-colon to `legacy.js`.
- [#384](https://github.com/amsul/pickadate.js/issues/384): Year selector appears *before* the month selector.
- [#387](https://github.com/amsul/pickadate.js/issues/387): Fixed issue where the `clear` method did not reset the `select` value to `null`.
- [#395](https://github.com/amsul/pickadate.js/issues/395): [Added a note](http://amsul.github.io/pickadate.js/api.htm#method-open-close) on how to use a separate button to open/close the picker.

## 3.4.0

- ARIA support added. :star2:
Expand Down
2 changes: 1 addition & 1 deletion Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ module.exports = function( grunt ) {
docs: {
files: [
'<%= dirs.docs.src %>/*.htm',
'<%= dirs.docs.src %>/styles/*.less'
'<%= dirs.docs.src %>/*.md'
],
tasks: [ 'docs' ]
},
Expand Down
24 changes: 12 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# pickadate v3.4.0 [![pickadate build status](https://travis-ci.org/amsul/pickadate.js.png?branch=gh-pages)](https://travis-ci.org/amsul/pickadate.js)
# pickadate v3.5.0 [![pickadate build status](https://travis-ci.org/amsul/pickadate.js.png?branch=gh-pages)](https://travis-ci.org/amsul/pickadate.js)

The mobile-friendly, responsive, and lightweight jQuery date & time input picker.

Expand All @@ -11,7 +11,7 @@ The mobile-friendly, responsive, and lightweight jQuery date & time input picker

#### To get it:

[Download v3.4.0](https://github.com/amsul/pickadate.js/archive/3.4.0.zip) or `git clone git://github.com/amsul/pickadate.js.git` or `bower install pickadate`
[Download v3.5.0](https://github.com/amsul/pickadate.js/archive/3.5.0.zip) or `git clone git://github.com/amsul/pickadate.js.git` or `bower install pickadate`



Expand All @@ -28,17 +28,17 @@ The v3 API is significantly different from v2 (all for the greater good!). So if
<br>
## Library files

The `` folder includes all the compiled files and a `compressed` folder with the minified counter-parts. These files are all generated from the `_raw/lib` folder using [Grunt](#building-with-grunt).
The `lib` folder includes the library files with a `compressed` folder containing the minified counter-parts. These files are minified using [Grunt](#building-with-grunt).

### Pickers

There are currently two pickers: **date** and **time**.

File | Contents | Size (min & gzip)
----------------------- | ------------------------ | ----------------------
`picker.js` | __Base *__ | 1.52kb
`picker.date.js` | Date picker | 2.45kb
`picker.time.js` | Time picker | 1.81kb
`picker.js` | __Base *__ | 1.71kb
`picker.date.js` | Date picker | 2.58kb
`picker.time.js` | Time picker | 1.83kb

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

Expand All @@ -47,15 +47,15 @@ _To support old browsers, namely IE8, **also include** the `legacy.js` file._

### Themes

All themes are [generated using LESS](#less-styling) and compiled into the `lib/themes` folder.
All themes are [generated using LESS](#less-styling) and compiled from the `lib/themes-source` folder into the `lib/themes` folder.

File | Contents | Size (min & gzip)
----------------------- | ---------------------------- | ----------------------
`default.css` | __Base default *__ | 0.47kb
`default.date.css` | Default date picker | 0.71kb
`default.date.css` | Default date picker | 0.70kb
`default.time.css` | Default time picker | 0.35kb
`classic.css` | __Base classic *__ | 0.37kb
`classic.date.css` | Classic date picker | 0.71kb
`classic.css` | __Base classic *__ | 0.39kb
`classic.date.css` | Classic date picker | 0.70kb
`classic.time.css` | Classic time picker | 0.35kb
`rtl.css` | __RTL language stylings **__ | 0.10kb

Expand All @@ -65,7 +65,7 @@ __**__ For languages with text flowing from right-to-left, also include the `rtl

### Translations

The translations are copied into the `` folder. There are currently [37 languages](https://github.com/amsul/pickadate.js/blob/3.4.0/lib/translations) included.
The translations live in the `lib/translations` folder. There are currently [38 language translations](https://github.com/amsul/pickadate.js/blob/3.5.0/lib/translations) included.



Expand Down Expand Up @@ -103,7 +103,7 @@ After making any changes, run `grunt less:themes` to compile it into CSS.
<br>
## Versioning

To maintain some consistency in the sort of changes to expect with version bumps, [Semantic Versioning guidelines](http://semver.org/) will now be followed as closely as possible:
To maintain some consistency in the sort of changes to expect with version bumps, [Semantic Versioning guidelines](http://semver.org/) is followed as closely as possible:

`<major>.<minor>.<patch>`

Expand Down
16 changes: 16 additions & 0 deletions _docs/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,21 @@
# Changelog

## 3.5.0

- [#162]({%= pkg.bugs %}/162): Fixed page scrolling issue when modal view is open in the default theme.
- [#350]({%= pkg.bugs %}/350): Fixed Hungarian translations typo.
- [#351]({%= pkg.bugs %}/351) & [#388]({%= pkg.bugs %}/388) & [#393]({%= pkg.bugs %}/393): Fixed issue with script freezing when `min` is `true` and “today” is disabled.
- [#358]({%= pkg.bugs %}/358): Fixed parsing months as 1-indexed when value is a string.
- [#360]({%= pkg.bugs %}/360): Improved Grunt script to build a cleaner project.
- [#361]({%= pkg.bugs %}/361): Fixed alternate API syntax not returning the correct value.
- [#367]({%= pkg.bugs %}/367): [Added a note]({%= pkg.homepage %}/date.htm#formatting-rules) on how to appropriately use the `yy` format.
- [#369]({%= pkg.bugs %}/369): Added Nepali translations.
- [#377]({%= pkg.bugs %}/377): Added the [`hiddenName` option]({%= pkg.homepage %}/date.htm#formats_use_hidden_only) to use the visible `input`’s name as the hidden `input`’s name.
- [#381]({%= pkg.bugs %}/381): Added missing semi-colon to `legacy.js`.
- [#384]({%= pkg.bugs %}/384): Year selector appears *before* the month selector.
- [#387]({%= pkg.bugs %}/387): Fixed issue where the `clear` method did not reset the `select` value to `null`.
- [#395]({%= pkg.bugs %}/395): [Added a note]({%= pkg.homepage %}/api.htm#method-open-close) on how to use a separate button to open/close the picker.

## 3.4.0

- ARIA support added. :star2:
Expand Down
6 changes: 3 additions & 3 deletions _docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ The v3 API is significantly different from v2 (all for the greater good!). So if
<br>
## Library files

The `{%= dirs.lib.dest %}` folder includes all the compiled files and a `compressed` folder with the minified counter-parts. These files are all generated from the `_raw/lib` folder using [Grunt](#building-with-grunt).
The `{%= dirs.lib.src %}` folder includes the library files with a `compressed` folder containing the minified counter-parts. These files are minified using [Grunt](#building-with-grunt).

### Pickers

Expand All @@ -58,7 +58,7 @@ _To support old browsers, namely IE8, **also include** the `legacy.js` file._

### Themes

All themes are [generated using LESS](#less-styling) and compiled into the `{%= dirs.themes.dest %}` folder.
All themes are [generated using LESS](#less-styling) and compiled from the `{%= dirs.themes.src %}` folder into the `{%= dirs.themes.dest %}` folder.

File | Contents | Size (min & gzip)
----------------------- | ---------------------------- | ----------------------
Expand All @@ -76,7 +76,7 @@ __**__ For languages with text flowing from right-to-left, also include the `rtl

### Translations

The translations are copied into the `{%= dirs.translations.dest %}` folder. There are currently [{%= grunt.file.expand(dirs.translations.min + '/*.js').length %} languages]({%= pkg.repository.url.replace(/.git$/,'') %}/blob/{%= pkg.version.split('-')[0] %}/lib/translations) included.
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.



Expand Down
15 changes: 13 additions & 2 deletions _docs/date.htm
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ <h2 class="heading heading--divide"><span class="heading__text">Options<a class=
formatSubmit: undefined,
hiddenPrefix: undefined,
hiddenSuffix: '_submit',
hiddenName: undefined,

// <a href="#editable">Editable input</a>
editable: undefined,
Expand Down Expand Up @@ -279,11 +280,21 @@ <h2 class="heading heading--divide"><span class="heading__text">Formats<a class=

{%= dateDemoField({ id: 'date_demo__formats--a' }).replace( 'type=text', 'name=date_input type=text' ) %}

<h3 class="heading heading--divide"><span class="heading__text">Pre-fill values using custom formats or translations<a class="heading__anchor--bigger" name="formats_prefill" href="#formats_prefill">&sect;</a><a name="formats_translations" href="#formats_translations"></a></span></h3>
<h3 class="heading heading--divide"><span class="heading__text">Send the hidden <code class="attribute">value</code> only<a class="heading__anchor" name="formats_use_hidden_only" href="#formats_use_hidden_only">&sect;</a></span></h3>
<p>A majority of the time, the value that needs to be sent to the server is just the hidden value – and not the visible one. To make this happen, use the <code>hiddenName</code> option.</p>
<p>This essentially nullifies the <code>hiddenPrefix</code> and <code>hiddenSuffix</code>, strips the <code class="attribute">name</code> attribute from the source <code class="tag-name">input</code>, and then sets it as the <code class="attribute">name</code> of the hidden <code class="tag-name">input</code>:</p>

<pre class="pre--demo"><code data-language="javascript">$('.datepicker').pickadate({
formatSubmit: 'yyyy/mm/dd',
hiddenName: true
})</code></pre>

{%= dateDemoField({ id: 'date_demo__formats--b' }).replace( 'type=text', 'name=date_input type=text' ) %}

<h3 class="heading heading--divide"><span class="heading__text">Pre-fill values using custom formats or translations<a class="heading__anchor--bigger" name="formats_prefill" href="#formats_prefill">&sect;</a><a name="formats_translations" href="#formats_translations"></a></span></h3>
<p>When using a custom <a href="#formatting-rules">formatting rule</a> for the <code>format</code> option or when using <a href="#translations">translations</a>, the <code class="tag-name">input</code> element should be given a <code class="attribute">data-value</code> attribute formatted using the <code>formatSubmit</code> – the element’s <code class="attribute">value</code> can be left blank. This helps to parse the date from custom formats into various languages:</p>
<pre class="pre--demo"><code data-language="html">&lt;input data-value="2013/04/20"></code></pre>
{%= dateDemoField({ id: 'date_demo__formats--b' }).replace( 'type=text', 'name=date_demo__formats type=text data-value="2013/04/20"') %}
{%= dateDemoField({ id: 'date_demo__formats--c' }).replace( 'type=text', 'name=date_demo__formats type=text data-value="2013/04/20"') %}

<h3 class="heading heading--divide"><span class="heading__text">Formatting Rules<a class="heading__anchor--bigger" name="formatting-rules" href="#formatting-rules">&sect;</a></span></h3>
<p>The following rules can be used to format any date:</p>
Expand Down
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "pickadate",
"version": "3.4.0",
"version": "3.5.0",
"title": "pickadate.js",
"description": "The mobile-friendly, responsive, and lightweight jQuery date & time input picker.",
"author": {
Expand Down
21 changes: 16 additions & 5 deletions date.htm
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,8 @@ <h3 class="heading heading--thin">The basic setup requires targetting an <code c
<fieldset class="fieldset fieldset--demo js__fieldset"><div class="fieldset__wrapper"><input id="" class="fieldset__input js__datepicker" type=text placeholder="Try me&hellip;"></div></fieldset>

<div class="section__block section__block--notification">
<p>Along with v3, the v2 options and API have effectively been deprecated. Read up on the <a href="https://github.com/amsul/pickadate.js/blob/3.4.0/CHANGELOG.md">full changelog here</a>.</p>
<p>One of the most critical changes is that the “month” used to create dates, just as in JavaScript’s native Date object, now has <a href="https://github.com/amsul/pickadate.js/blob/3.4.0/CHANGELOG.md#zero-as-index">zero-as-index</a>.</p>
<p>Along with v3, the v2 options and API have effectively been deprecated. Read up on the <a href="https://github.com/amsul/pickadate.js/blob/3.5.0/CHANGELOG.md">full changelog here</a>.</p>
<p>One of the most critical changes is that the “month” used to create dates, just as in JavaScript’s native Date object, now has <a href="https://github.com/amsul/pickadate.js/blob/3.5.0/CHANGELOG.md#zero-as-index">zero-as-index</a>.</p>
</div>

</div> <!-- .section__block -->
Expand Down Expand Up @@ -106,6 +106,7 @@ <h2 class="heading heading--divide"><span class="heading__text">Options<a class=
formatSubmit: undefined,
hiddenPrefix: undefined,
hiddenSuffix: '_submit',
hiddenName: undefined,

// <a href="#editable">Editable input</a>
editable: undefined,
Expand Down Expand Up @@ -270,7 +271,7 @@ <h2 class="heading heading--divide"><span class="heading__text">Accessibility la
<div class="section__block section__block--scoped">

<h2 class="heading heading--divide"><span class="heading__text">Translations<a class="heading__anchor" name="translations" href="#translations">&sect;</a></span></h2>
<p>The picker can be extended to add support for internationalization. Translations for <a href="https://github.com/amsul/pickadate.js/blob/3.4.0/lib/translations">37 languages</a> are available out of the box, which you can include in one of two ways:</p>
<p>The picker can be extended to add support for internationalization. Translations for <a href="https://github.com/amsul/pickadate.js/blob/3.5.0/lib/translations">38 languages</a> are available out of the box, which you can include in one of two ways:</p>

<pre class="pre--demo"><code data-language="javascript">// Extend the default picker options for <u>all instances</u>.
$.extend($.fn.pickadate.defaults, {
Expand Down Expand Up @@ -328,11 +329,21 @@ <h2 class="heading heading--divide"><span class="heading__text">Formats<a class=

<fieldset class="fieldset fieldset--demo js__fieldset"><div class="fieldset__wrapper"><input id="date_demo__formats--a" class="fieldset__input " name=date_input type=text placeholder="Try me&hellip;"></div></fieldset>

<h3 class="heading heading--divide"><span class="heading__text">Pre-fill values using custom formats or translations<a class="heading__anchor--bigger" name="formats_prefill" href="#formats_prefill">&sect;</a><a name="formats_translations" href="#formats_translations"></a></span></h3>
<h3 class="heading heading--divide"><span class="heading__text">Send the hidden <code class="attribute">value</code> only<a class="heading__anchor" name="formats_use_hidden_only" href="#formats_use_hidden_only">&sect;</a></span></h3>
<p>A majority of the time, the value that needs to be sent to the server is just the hidden value – and not the visible one. To make this happen, use the <code>hiddenName</code> option.</p>
<p>This essentially nullifies the <code>hiddenPrefix</code> and <code>hiddenSuffix</code>, strips the <code class="attribute">name</code> attribute from the source <code class="tag-name">input</code>, and then sets it as the <code class="attribute">name</code> of the hidden <code class="tag-name">input</code>:</p>

<pre class="pre--demo"><code data-language="javascript">$('.datepicker').pickadate({
formatSubmit: 'yyyy/mm/dd',
hiddenName: true
})</code></pre>

<fieldset class="fieldset fieldset--demo js__fieldset"><div class="fieldset__wrapper"><input id="date_demo__formats--b" class="fieldset__input " name=date_input type=text placeholder="Try me&hellip;"></div></fieldset>

<h3 class="heading heading--divide"><span class="heading__text">Pre-fill values using custom formats or translations<a class="heading__anchor--bigger" name="formats_prefill" href="#formats_prefill">&sect;</a><a name="formats_translations" href="#formats_translations"></a></span></h3>
<p>When using a custom <a href="#formatting-rules">formatting rule</a> for the <code>format</code> option or when using <a href="#translations">translations</a>, the <code class="tag-name">input</code> element should be given a <code class="attribute">data-value</code> attribute formatted using the <code>formatSubmit</code> – the element’s <code class="attribute">value</code> can be left blank. This helps to parse the date from custom formats into various languages:</p>
<pre class="pre--demo"><code data-language="html">&lt;input data-value="2013/04/20"></code></pre>
<fieldset class="fieldset fieldset--demo js__fieldset"><div class="fieldset__wrapper"><input id="date_demo__formats--b" class="fieldset__input " name=date_demo__formats type=text data-value="2013/04/20" placeholder="Try me&hellip;"></div></fieldset>
<fieldset class="fieldset fieldset--demo js__fieldset"><div class="fieldset__wrapper"><input id="date_demo__formats--c" class="fieldset__input " name=date_demo__formats type=text data-value="2013/04/20" placeholder="Try me&hellip;"></div></fieldset>

<h3 class="heading heading--divide"><span class="heading__text">Formatting Rules<a class="heading__anchor--bigger" name="formatting-rules" href="#formatting-rules">&sect;</a></span></h3>
<p>The following rules can be used to format any date:</p>
Expand Down
Loading

0 comments on commit acd190d

Please sign in to comment.