Skip to content

Commit

Permalink
add title=placeholder if no title
Browse files Browse the repository at this point in the history
  • Loading branch information
mcshaz committed Apr 16, 2020
1 parent d41bb28 commit dbea61a
Show file tree
Hide file tree
Showing 32 changed files with 41 additions and 38 deletions.
2 changes: 2 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,5 @@
node_modules
src
examples
index.html
rollup.config.js
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ Execute `dateInputPolyfill.polyfillIfRequired()` with any options described abov
## Features
* **Easily Stylable:** [These are the default styles](https://github.com/brianblakely/esm-date-input-polyfill/blob/master/esm-date-input-polyfill.scss), which you may override with your own.
* **Easily Stylable:** [These are the default styles](https://github.com/mcshaz/esm-date-input-polyfill/blob/master/esm-date-input-polyfill.scss), which you may override with your own.
* **Polyfills `valueAsDate` and `valueAsNumber`:**
[Learn more about these properties.](https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement#property-valueasdate). They behave as getters and setters.
Expand Down

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
// @license MIT - https://github.com/brianblakely/esm-date-input-polyfill
"use strict";const e=function(){const e=document.createElement("input");e.setAttribute("type","date");return e.setAttribute("value","not-a-date"),"not-a-date"!==e.value}();exports.FindInputsHelper=class{constructor({allowForcePicker:e=!1}={}){this.allowForcePicker=e}requiresPolyfilling(t){return t&&"INPUT"===t.tagName&&"date"===t.getAttribute("type")&&!t.hasAttribute("data-has-picker")&&(!e||this.allowForcePicker&&null!==t.closest("[data-force-date-input-polyfill]"))}getAllInputsForPolyfilling(){return Array.from(document.getElementsByTagName("input")).filter(e=>this.requiresPolyfilling(e))||[]}},exports.dateInputIsSupported=e,exports.pickerAppliedAttr="data-has-picker",exports.polyfillIfRequired=function({watchForInsert:t=!1,allowForcePicker:r=!1,yrsBack:o=80,yrsFwd:a=20}={}){return!e||r&&document.querySelector("[data-force-date-input-polyfill]")?new Promise((function(e){e(require("./add-pickers-ba507d00.cjs.mjs"))})).then(e=>new Promise(i=>{let n=!1;const l=()=>{n||(e.addPickers({watchForInsert:t,allowForcePicker:r,yrsBack:o,yrsFwd:a}),i(),n=!0)};"complete"===document.readyState?l():(document.addEventListener("DOMContentLoaded",l),window.addEventListener("load",l))})):Promise.resolve()};
"use strict";const e=function(){const e=document.createElement("input");e.setAttribute("type","date");return e.setAttribute("value","not-a-date"),"not-a-date"!==e.value}();exports.FindInputsHelper=class{constructor({allowForcePicker:e=!1}={}){this.allowForcePicker=e}requiresPolyfilling(t){return t&&"INPUT"===t.tagName&&"date"===t.getAttribute("type")&&!t.hasAttribute("data-has-picker")&&(!e||this.allowForcePicker&&null!==t.closest("[data-force-date-input-polyfill]"))}getAllInputsForPolyfilling(){return Array.from(document.getElementsByTagName("input")).filter(e=>this.requiresPolyfilling(e))||[]}},exports.dateInputIsSupported=e,exports.pickerAppliedAttr="data-has-picker",exports.polyfillIfRequired=function({watchForInsert:t=!1,allowForcePicker:r=!1,yrsBack:o=80,yrsFwd:i=20}={}){return!e||r&&document.querySelector("[data-force-date-input-polyfill]")?new Promise((function(e){e(require("./add-pickers-59466f4f.cjs.mjs"))})).then(e=>new Promise(n=>{let a=!1;const l=()=>{a||(e.addPickers({watchForInsert:t,allowForcePicker:r,yrsBack:o,yrsFwd:i}),n(),a=!0)};"complete"===document.readyState?l():(document.addEventListener("DOMContentLoaded",l),window.addEventListener("load",l))})):Promise.resolve()};
2 changes: 1 addition & 1 deletion dist/cjs/polyfill-if-required.cjs.js
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
// @license MIT - https://github.com/brianblakely/esm-date-input-polyfill
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./polyfill-if-required-6dfd5f3d.cjs.mjs");exports.polyfillIfRequired=e.polyfillIfRequired;
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./polyfill-if-required-d8ecbf95.cjs.mjs");exports.polyfillIfRequired=e.polyfillIfRequired;
2 changes: 1 addition & 1 deletion dist/iife/esm-date-input-polyfill.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/iife/esm-date-input-polyfill.js.map

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
// @license MIT - https://github.com/brianblakely/esm-date-input-polyfill
const e=function(){const e=document.createElement("input");e.setAttribute("type","date");return e.setAttribute("value","not-a-date"),"not-a-date"!==e.value}();const t="data-has-picker";class r{constructor({allowForcePicker:e=!1}={}){this.allowForcePicker=e}requiresPolyfilling(t){return t&&"INPUT"===t.tagName&&"date"===t.getAttribute("type")&&!t.hasAttribute("data-has-picker")&&(!e||this.allowForcePicker&&null!==t.closest("[data-force-date-input-polyfill]"))}getAllInputsForPolyfilling(){return Array.from(document.getElementsByTagName("input")).filter(e=>this.requiresPolyfilling(e))||[]}}function a({watchForInsert:t=!1,allowForcePicker:r=!1,yrsBack:a=80,yrsFwd:o=20}={}){return!e||r&&document.querySelector("[data-force-date-input-polyfill]")?import("./add-pickers-dd4f5f85.mjs").then(e=>new Promise(n=>{let l=!1;const i=()=>{l||(e.addPickers({watchForInsert:t,allowForcePicker:r,yrsBack:a,yrsFwd:o}),n(),l=!0)};"complete"===document.readyState?i():(document.addEventListener("DOMContentLoaded",i),window.addEventListener("load",i))})):Promise.resolve()}export{r as F,t as a,e as d,a as p};
//# sourceMappingURL=polyfill-if-required-d890f842.mjs.map
const e=function(){const e=document.createElement("input");e.setAttribute("type","date");return e.setAttribute("value","not-a-date"),"not-a-date"!==e.value}();const t="data-has-picker";class r{constructor({allowForcePicker:e=!1}={}){this.allowForcePicker=e}requiresPolyfilling(t){return t&&"INPUT"===t.tagName&&"date"===t.getAttribute("type")&&!t.hasAttribute("data-has-picker")&&(!e||this.allowForcePicker&&null!==t.closest("[data-force-date-input-polyfill]"))}getAllInputsForPolyfilling(){return Array.from(document.getElementsByTagName("input")).filter(e=>this.requiresPolyfilling(e))||[]}}function a({watchForInsert:t=!1,allowForcePicker:r=!1,yrsBack:a=80,yrsFwd:o=20}={}){return!e||r&&document.querySelector("[data-force-date-input-polyfill]")?import("./add-pickers-d77e4620.mjs").then(e=>new Promise(n=>{let l=!1;const i=()=>{l||(e.addPickers({watchForInsert:t,allowForcePicker:r,yrsBack:a,yrsFwd:o}),n(),l=!0)};"complete"===document.readyState?i():(document.addEventListener("DOMContentLoaded",i),window.addEventListener("load",i))})):Promise.resolve()}export{r as F,t as a,e as d,a as p};
//# sourceMappingURL=polyfill-if-required-00d9150b.mjs.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/polyfill-if-required.mjs
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
// @license MIT - https://github.com/brianblakely/esm-date-input-polyfill
export{p as polyfillIfRequired}from"./polyfill-if-required-d890f842.mjs";
export{p as polyfillIfRequired}from"./polyfill-if-required-00d9150b.mjs";
//# sourceMappingURL=polyfill-if-required.mjs.map
3 changes: 3 additions & 0 deletions examples/dist/add-pickers-d77e4620-116076a8.js

Large diffs are not rendered by default.

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions examples/dist/add-pickers-d77e4620-a5ce75a2.js

Large diffs are not rendered by default.

Large diffs are not rendered by default.

3 changes: 0 additions & 3 deletions examples/dist/add-pickers-dd4f5f85-dfbf435a.js

This file was deleted.

3 changes: 0 additions & 3 deletions examples/dist/add-pickers-dd4f5f85-f659d4be.js

This file was deleted.

Loading

0 comments on commit dbea61a

Please sign in to comment.