Ink.Dom.Browser no longer detects some IE11 mobile browsers as Safari
Fix a bug in Modal when open() is called with no arguments and there's an onShow callback present.
When a Carousel does not have a stage, the error message now makes some more sense than "a is not defined".
Do not crash with <option> elements in FormValidator_2
Do a better feature detection of the vh/vw units, for old IOS safari.
Fix SmoothScroller adding "active" classes in <li> elements, but never removing them
3.1.9
CSS
Hotfix release, updates FontAwesome files.
3.1.8
CSS
Fixes round corners when there's only one child in the .button-group element.
Fixes vertical alignment in Safari.
Base font settings are now defined with the font property and the $base-font-weight,$base-font-stretch and $base-font-variant variables were added.
JS
Dropdown does not need to be passed a 'target' option anymore, it can find its menu by itself
Modal will not stop propagation of events any more
Modal's onShow callback now takes an object with the modal trigger. It now is function (modalInstance, { trigger }) {}
Modal getModalElement, getShadeElement methods, which return the corresponding DOM elements which make up the modal
Pagination JS now supports chevron and dotted mode at the same time.
FormValidator_2 now supports a data-lang option to set its language to something else.
FormValidator_2 FormElement instances now have forceInvalid and forceValid methods, so you can arbitrarily say an input is valid or invalid and bypass all validation rules.
Support Opera Mini, which does not have onscroll, in LazyLoad
InkArray.forEachObj, for iterating an object's key/value pairs as you do in InkArray.forEach.
Fixed an Ink.UI.DatePicker bug in Chrome, which didn't let you select the field.
3.1.7
JS
InkEvent.throttle preventDefault and bind options
Fixed bug in Ajax, when requests are abort()ed, they should not generate errors any more
Adds LazyLoad to Autoload with the .ink-lazyload class
Add loadedClass (data-loaded-class="class-name") option to put classes in LazyLoaded elements when they are loaded so they can be styled.
Adds TL phones to Ink.Util.Validator
Adds EAN validation to Ink.Util.Validator and Ink.UI.FormValidator_2
Fixes multiple onInViewport callbacks in Ink.UI.LazyLoad_1
Make FormValidator's "matches" rule match form elements without a [rules] attribute, because those may not be validated.
Modal now uses Flex and VH/VH CSS dimensions remove or lighten the necessity for javascript layout. It is more smooth and a lot faster too! It gracefully degrades into using some javascript layout, or fully rely on it, on older browsers.
Toggle will now pass (newState, { element }) as arguments to the onChangeState callback, instead of just the new state
DatePicker bugfixes
when isAccordion, the closeOnClick option of a toggle will default to false.
DatePicker lang option, to set the language to Portuguese easily, and an Ink.Util.I18n instance to help create more languages.
Minor breaking change: Ink.UI.Toggle no longer supports detecting whether the toggled element is currently visible (using getComputedStyle) in order to set its initial state. To achieve the same effect, set the class of the first target to be the same as the classNameOn option (which defaults to 'show-all'). This may break some things, but it improves the predictability and usability of the component. d497ba5
getInstance() function in UI component classes. Use it like this: var myModal = Modal.getInstance('#element-with-a-modal'). This deprecates the need of disabling Ink.UI.Autoload to interact with UI components.
Do not pollute elements with data-instance attributes. This also fixes a memory leak when UI components are removed from the DOM.
If you were using requireModules to load modules asynchronously (eg. not using ink-all.js), now there is no default URL for the Ink namespace. This will only affect you if you are using requireModules asynchronously and are not calling setPath() yourself. We're not bumping a major because this is not likely to affect anyone although, theoretically, it's a breaking change.
CSS
Removes a fade() call left over from the old LESS source (#349)
JS
Fixing FormValidator
Removing the default Ink.setPath() call. We removed this because it causes surprising results and brings no benefits, and causes people to accidentally use https://js.ink.sapo.pt every time they misspelled a module name. Now you will get an error.
Drops the makefiles and unifies the dependency management and build process with grunt and bower.
Changes the repository structure. Source code is now kept under "src" and compiled/distributable code is kept in the "dist" folder.
CSS
Layout
Default ink-grid maximum width increased to 1400px.
Adds 2 breakpoints: "tiny" for screen widths below 320px and "xlarge" for screen widths over 1200px. The new breakpoints are disabled by default. To use them you'll need to edit src/less/grid.less and src/less/config/__grid.less and uncomment the code that creates the additional breakpoints.
Adds breakpoint dependent spacing and column horizontal alignment classes i.e. small-top-space, small-push-center.
Adds breakpoint dependent text alignment classes i.e. small-align-center.
Adds breakpoint dependent gutters i.e. small-gutters.
Adds "double" size variant for gutters and spacing class i.e. double-gutters.
Improves CSS selector specificity to avoid class name collisions in several components.
Several bug fixes.
JavaScript
UI
Adds UI Carousel component.
Improves UI Sticky component.
Improves UI DatePicker component.
Improves UI Common.options() component. enables UI modules to receive options of several types including Numbers, Booleans and Selectors (this improves most other components)
Renames Ink.UI.Aux to Ink.UI.Common.
Global fixes and changes
Core Event API change/addition. Integrated Bean ( https://github.com/fat/bean ) in the module. New methods on the API ( on, one, off, clone, fire ). Also created observeDelegated(element, eventName, selector, callback)
Ink.Dom.Element.create() can now call Ink.Dom.Event functions for quick creation and placement of elements: InkElement.create('div', { insertBottom: document.body });
Ink.Dom.Element.wrap() and unwrap.
Core Ajax
Formvalidator v1
Treeview
SortableList
Tagfield
Table
Modal
Sticky
Datepicker
Promoted Ink.Autoload to an Ink module. It now has the Autoload.run() function for running Autoload on dynamically generated content.
structural change: Ink.js Git submodule dropped, now Ink and Ink.js are the same repository
Javascript
Ink.UI.Sticky bugfixes
Ink.UI.Draggables improved
Ink.Dom.Event improvements: throttle (limit the amount of times a function can be called) and observeMulti (attaches an event to a selector or array of elements).
Ink.UI.Toggle now toggles several elements at once, if the selector selects many elements.
Added more spacing and gutter size options. E. g. .half-space, .quarter-space, top-space,
.bottom-space, .left-space, .right-space, .half-gutters, .horizontal-gutters and much more.