Nicolas Coden [Sat, 4 Aug 2018 17:59:32 +0000 (19:59 +0200)]
feat: add Orbit element "data-slide-active-label" to target the bullet span to move
Add the Orbit element `[data-slide-active-label]` to explicitely set which Orbit bullet children describe the active slide and should be moved to the new active slide.
Nicolas Coden [Thu, 2 Aug 2018 22:34:27 +0000 (00:34 +0200)]
fix: fix Dropdown Menu top level item properties #11412
Changes:
- Only apply top-level styles to top-level items. This increase specificity but this markup structure is alreaddy assumed elsewhere in the component.
- Remove the default `$white` background on top-level items: it was never applied before #11377 and could now cause visual changes.
Nicolas Coden [Wed, 1 Aug 2018 21:57:14 +0000 (23:57 +0200)]
fix: keep the original event datas in Touch tap/swipe events
Keep the `touchstart`/`touchmove`/`touchend` datas (like `target`) for the events that are manually triggered: `tap` and `swipe`.
This resolve a bug in "Reveal" when a `touchend` event inside the reveal modal is transformed to a `tap` event on the overlay because the original `target` is lost when triggered the event on the overlay.
Nicolas Coden [Wed, 1 Aug 2018 21:14:02 +0000 (23:14 +0200)]
fix: use mobile "tap" for the "closeOnClick" option in Reveal
BREAKING CHANGE: `foundation.utils.touch.js` is now required for `foundation.reveal.js`. If you import the Foundation Dropdown plugin manually, make sure to import the "Touch" utility as well.
BREAKING CHANGE: `foundation.utils.touch.js` is now required for `foundation.dropdown.js`. If you import the Foundation Dropdown plugin manually, make sure to import the "Touch" utility as well.
Nicolas Coden [Wed, 1 Aug 2018 21:09:30 +0000 (23:09 +0200)]
fix: fix "tap" event triggering in Touch
The current implementation actually never triggers the "tap" event. This commit refactor its handling to triggers it when the screen is touched without sliding.
Changes:
- Register the `tap` event in jQuery
- Triggers the `tap` event on `mouseend` if no moves were recorded before.
Nicolas Coden [Mon, 30 Jul 2018 22:13:00 +0000 (00:13 +0200)]
fix: set the Drilldown height for on the currently opened (sub)menu #11416
Changes:
- Save the currently opened sub-menu as `$currentMenu`
- When calculating the Drilldown wrapper height, use the currently opened menu height instead of the primary menu.
Nicolas Coden [Sat, 28 Jul 2018 22:04:18 +0000 (00:04 +0200)]
fix: make the "ignoreMousedisappear()" handler called before mouseenter
Do not debounce the received `mouseleave` event when a `mouseenter` is expected. This is not useful (we do not have to test the window focus in this case) and would make the `mouseenter` event handler called before the filtered `mouseleave` event handler.
See https://github.com/zurb/foundation-sites/pull/11418#issuecomment-407911537
Nicolas Coden [Wed, 18 Jul 2018 22:48:00 +0000 (00:48 +0200)]
feat: add support of fractions in "xy-cell-base()" function and mixin.
Make the `xy-cell-base()` function and mixin support values representing a fraction (`6`, `50%`, `1 of 2` or `1/2`...) and treating them like "shrink".
**BREAKING CHANGE**: The `xy-cell()` and `xy-cell-base()` mixins now generate the XY cell base CSS when `$size` represents a fraction.
Nicolas Coden [Wed, 18 Jul 2018 21:31:51 +0000 (23:31 +0200)]
feat: refactor `xy-cell-base()` mixin and add corresponding function
Changes:
- Add function `xy-cell-base()`: Returns the appropriate CSS flex value for a cell base.
- Refactor mixin `xy-cell-base()` to use its corresponding function.
Nicolas Coden [Tue, 17 Jul 2018 21:41:34 +0000 (23:41 +0200)]
feat: refactor mixin "xy-cell-offset()" and add corresponding function
Changes:
- Add function `xy-cell-offset()`: Returns the appropriate CSS value to offset a cell.
- Refactor mixin `xy-cell-offset()` to use its corresponding function.
**BREAKING CHANGE**: The `$breakpoint` argument in the `xy-cell-offset()` mixin does not support raw value anymore. Use `$gutters` instead.
Nicolas Coden [Tue, 17 Jul 2018 21:30:42 +0000 (23:30 +0200)]
feat: add functions/mixins for XY Grid cell base/size/gutters
Move all the `xy-cell()` mixin logics to dedicated functions and mixins.
Changes:
- Add function `xy-cell-gutters()`: Calculate the size of a cell gutters.
- Add function `xy-cell-size-css()`: Returns the appropriate CSS value for a cell size.
- Add mixin `xy-cell-size()`: ets sizing properties for cells.
- Add mixin `xy-cell-gutters()`: Sets gutters properties for cells.
- Refactor mixin `xy-cell()` to move all the logics to these new mixins.
All these functions/mixins now have the same interface. They do not always expect all the XY cell arguments, but they name and process the argument they expect the same way.
**BREAKING CHANGE**: When no gutter can be found to generate a cell, an error is now thrown
Nicolas Coden [Tue, 17 Jul 2018 20:45:41 +0000 (22:45 +0200)]
refactor: move "-zf-each-breakpoint()" mixin iteration logics to "-zf-each-breakpoint()"
Changes:
* Add mixin `-zf-each-breakpoint-in()`
* Add function `-zf-bool()` to convert values to Booleans
* Refactor mixin `-zf-each-breakpoint()` to rely on `-zf-each-breakpoint-in()`
There should be no change in the `-zf-each-breakpoint` API
Nicolas Coden [Sun, 15 Jul 2018 20:19:11 +0000 (22:19 +0200)]
feat: add support for current breakpoint to `xy-cell-offset()` and `xy-grid-layout()`
Add support for contextual breakpoint set by the `breakpoint()` mixin to the `xy-cell-offset()` mixin, and add documentation abou existing support to the `xy-grid-layout()` mixin.
Nicolas Coden [Sat, 14 Jul 2018 16:49:10 +0000 (18:49 +0200)]
refactor: deprecate xy-cell-static() and use xy-cell() to generate classes
Deprecate the` xy-cell-static()` mixin and use `xy-cell()` mixin to generate the XY Grid static classes.
The new arguments of `xy-cells` (added in previous commits) have the following goal: making a clear distinction between cells that should not have any gutter, cells from which the gutter must be removed and cells that should have a gutter but generated seperately/later. See migration notes below.
Changes:
- Add deprecation warning in `xy-cell-static()`
- Add deprecation note in `xy-cell-static()` documentation
- Use `xy-cell()` instead of `xy-cell-static()` with the transformations listed below
Migration notes:
- Use `$output: (...)` instead of separate calls to `xy-cell-static()` and `xy-cell-base()`. This may change in the future with 3 distinguish mixins to generate "base", "size" and "gutters" of the cell.
- Use `$gutter-type: none` for cells without gutters
- Use `$gutters: 0` for cells with a 0-width gutters
- Use `$output: (...)` without "gutters" for cells with gutters that must be generated seperately.
- Remove useless `$breakpoint: $-zf-size` as it is always detected automatically
Nicolas Coden [Fri, 13 Jul 2018 22:46:12 +0000 (00:46 +0200)]
feat: add `$output` to xy-cell mixin and deprecate `$output-gutter`
Add the `$output` list to the xy-cell mixin for a finer control of what should be output, and an explicit indication that each part may still have to be generated seperately.
`$gutter-output` still works the same way, and breaking change introduced in #11081 has been replaced with a deprecation notice. Migration notes and advices to correctly generate gutters will be included in the release notes of the future version
Nicolas Coden [Mon, 9 Jul 2018 21:46:05 +0000 (23:46 +0200)]
chore: update sourcemaps of distributed JS plugins
Sourcemaps for distribution main files and build JS plugins were added in https://github.com/zurb/foundation-sites/pull/11012 but distribution JS plugins were forgotten. This commit change the `deploy:plugins` gulp task to generate and copy sourcemaps for JS plugin alongside their source files.
Changes:
* Split `deploy:plugins` into `deploy:plugins:sources` and `deploy:plugins:sourcemaps`
* Generate sourcemaps for minified plugins in `deploy:plugins:sources`
* Copy sourcemaps for plugins to dist folder in `deploy:plugins:sourcemaps`
Nicolas Coden [Sat, 7 Jul 2018 20:06:52 +0000 (22:06 +0200)]
chore: upgrade gulp to v4.0.0
Changes:
- bump gulp version
- update lockfiles
- use `gulp.series` and `gulp.parallel` instead of `run-sequence` and deprecated task dependencies
- remove unused dependencies in gulpfiles