ably-ui 8.7.0.dev.6053fb4 → 8.7.0.dev.7072b07
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +6 -6
- data/README.md +7 -3
- data/lib/ably_ui/core/code/component.css +2 -0
- data/lib/ably_ui/core/code/component.js +739 -1
- data/lib/ably_ui/core/company_autocomplete/component.css +2 -0
- data/lib/ably_ui/core/company_autocomplete/component.js +1161 -1
- data/lib/ably_ui/core/connect_state_wrapper/component.js +22 -1
- data/lib/ably_ui/core/contact_footer/component.css +2 -0
- data/lib/ably_ui/core/contact_footer/component.js +211 -1
- data/lib/ably_ui/core/cookie_message/component.css +2 -0
- data/lib/ably_ui/core/cookie_message/component.js +82 -1
- data/lib/ably_ui/core/core.rb +8 -4
- data/lib/ably_ui/core/customer_logos/component.js +22 -1
- data/lib/ably_ui/core/dropdown_menu/component.js +22 -1
- data/lib/ably_ui/core/feature_footer/component.css +2 -0
- data/lib/ably_ui/core/feature_footer/component.js +211 -1
- data/lib/ably_ui/core/featured_link/component.css +2 -0
- data/lib/ably_ui/core/featured_link/component.js +82 -1
- data/lib/ably_ui/core/flash/component.css +2 -0
- data/lib/ably_ui/core/flash/component.js +82 -1
- data/lib/ably_ui/core/footer/component.css +3 -1
- data/lib/ably_ui/core/footer/component.js +82 -1
- data/lib/ably_ui/core/footer/footer.html.erb +18 -23
- data/lib/ably_ui/core/icon/component.js +22 -1
- data/lib/ably_ui/core/images/best-support-2023.svg +1 -0
- data/lib/ably_ui/core/images/fastest-implementation-2023.svg +1 -0
- data/lib/ably_ui/core/images/high-performer-2023.svg +1 -0
- data/lib/ably_ui/core/images/highest-user-adoption-2023.svg +1 -0
- data/lib/ably_ui/core/loader/component.js +22 -1
- data/lib/ably_ui/core/logo/component.js +22 -1
- data/lib/ably_ui/core/meganav/component.css +3 -3
- data/lib/ably_ui/core/meganav/component.js +992 -1
- data/lib/ably_ui/core/meganav/component.json +1 -1
- data/lib/ably_ui/core/meganav/meganav.rb +4 -4
- data/lib/ably_ui/core/meganav_blog_posts_list/component.js +1159 -1
- data/lib/ably_ui/core/meganav_content_company/component.js +22 -1
- data/lib/ably_ui/core/meganav_content_company/meganav_content_company.html.erb +9 -0
- data/lib/ably_ui/core/meganav_content_developers/component.js +22 -1
- data/lib/ably_ui/core/meganav_content_developers/meganav_content_developers.html.erb +18 -2
- data/lib/ably_ui/core/meganav_content_products/component.js +22 -0
- data/lib/ably_ui/core/{meganav_content_platform/meganav_content_platform.html.erb → meganav_content_products/meganav_content_products.html.erb} +15 -33
- data/lib/ably_ui/core/{meganav_content_platform/meganav_content_platform.rb → meganav_content_products/meganav_content_products.rb} +1 -1
- data/lib/ably_ui/core/meganav_content_use_cases/component.js +22 -1
- data/lib/ably_ui/core/meganav_content_use_cases/meganav_content_use_cases.html.erb +42 -38
- data/lib/ably_ui/core/meganav_control/component.js +241 -1
- data/lib/ably_ui/core/meganav_control_mobile_dropdown/component.js +180 -1
- data/lib/ably_ui/core/meganav_control_mobile_panel_close/component.js +142 -1
- data/lib/ably_ui/core/meganav_control_mobile_panel_open/component.js +170 -1
- data/lib/ably_ui/core/meganav_items_desktop/component.js +22 -1
- data/lib/ably_ui/core/meganav_items_desktop/meganav_items_desktop.rb +1 -1
- data/lib/ably_ui/core/meganav_items_mobile/component.js +22 -1
- data/lib/ably_ui/core/meganav_items_signed_in/component.js +22 -1
- data/lib/ably_ui/core/meganav_search/component.js +22 -1
- data/lib/ably_ui/core/meganav_search_autocomplete/component.js +295 -1
- data/lib/ably_ui/core/meganav_search_panel/component.js +22 -1
- data/lib/ably_ui/core/meganav_search_suggestions/component.js +258 -1
- data/lib/ably_ui/core/notice/component.css +2 -0
- data/lib/ably_ui/core/notice/component.js +872 -1
- data/lib/ably_ui/core/scripts.js +1465 -1
- data/lib/ably_ui/core/showcase/component.css +2 -0
- data/lib/ably_ui/core/showcase/component.js +343 -1
- data/lib/ably_ui/core/sign_out_link/component.js +22 -1
- data/lib/ably_ui/core/slider/component.css +2 -0
- data/lib/ably_ui/core/slider/component.js +255 -1
- data/lib/ably_ui/core/sprites.svg +93 -0
- data/lib/ably_ui/core/styles.css +3 -7
- data/lib/ably_ui/core/uptime/component.css +2 -0
- data/lib/ably_ui/core/uptime/component.js +82 -1
- data/lib/ably_ui/reset/scripts.js +1 -1
- data/lib/ably_ui/reset/styles.css +1 -11
- data/lib/ably_ui/version.rb +1 -1
- metadata +9 -5
- data/lib/ably_ui/core/meganav_content_platform/component.js +0 -1
@@ -1 +1,241 @@
|
|
1
|
-
|
1
|
+
(function webpackUniversalModuleDefinition(root, factory) {
|
2
|
+
if(typeof exports === 'object' && typeof module === 'object')
|
3
|
+
module.exports = factory();
|
4
|
+
else if(typeof define === 'function' && define.amd)
|
5
|
+
define([], factory);
|
6
|
+
else if(typeof exports === 'object')
|
7
|
+
exports["AblyUi"] = factory();
|
8
|
+
else
|
9
|
+
root["AblyUi"] = root["AblyUi"] || {}, root["AblyUi"]["Core"] = root["AblyUi"]["Core"] || {}, root["AblyUi"]["Core"]["MeganavControl"] = factory();
|
10
|
+
})(this, () => {
|
11
|
+
return /******/ (() => { // webpackBootstrap
|
12
|
+
/******/ "use strict";
|
13
|
+
/******/ var __webpack_modules__ = ({
|
14
|
+
|
15
|
+
/***/ "./src/core/dom-query.js":
|
16
|
+
/*!*******************************!*\
|
17
|
+
!*** ./src/core/dom-query.js ***!
|
18
|
+
\*******************************/
|
19
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
20
|
+
|
21
|
+
__webpack_require__.r(__webpack_exports__);
|
22
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
23
|
+
/* harmony export */ "queryId": () => (/* binding */ queryId),
|
24
|
+
/* harmony export */ "queryIdAll": () => (/* binding */ queryIdAll)
|
25
|
+
/* harmony export */ });
|
26
|
+
var queryId = function queryId(val) {
|
27
|
+
var root = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : document;
|
28
|
+
return root.querySelector("[data-id=".concat(val, "]"));
|
29
|
+
};
|
30
|
+
var queryIdAll = function queryIdAll(val) {
|
31
|
+
var root = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : document;
|
32
|
+
return root.querySelectorAll("[data-id=".concat(val, "]"));
|
33
|
+
};
|
34
|
+
|
35
|
+
/***/ })
|
36
|
+
|
37
|
+
/******/ });
|
38
|
+
/************************************************************************/
|
39
|
+
/******/ // The module cache
|
40
|
+
/******/ var __webpack_module_cache__ = {};
|
41
|
+
/******/
|
42
|
+
/******/ // The require function
|
43
|
+
/******/ function __webpack_require__(moduleId) {
|
44
|
+
/******/ // Check if module is in cache
|
45
|
+
/******/ var cachedModule = __webpack_module_cache__[moduleId];
|
46
|
+
/******/ if (cachedModule !== undefined) {
|
47
|
+
/******/ return cachedModule.exports;
|
48
|
+
/******/ }
|
49
|
+
/******/ // Create a new module (and put it into the cache)
|
50
|
+
/******/ var module = __webpack_module_cache__[moduleId] = {
|
51
|
+
/******/ // no module.id needed
|
52
|
+
/******/ // no module.loaded needed
|
53
|
+
/******/ exports: {}
|
54
|
+
/******/ };
|
55
|
+
/******/
|
56
|
+
/******/ // Execute the module function
|
57
|
+
/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
|
58
|
+
/******/
|
59
|
+
/******/ // Return the exports of the module
|
60
|
+
/******/ return module.exports;
|
61
|
+
/******/ }
|
62
|
+
/******/
|
63
|
+
/************************************************************************/
|
64
|
+
/******/ /* webpack/runtime/define property getters */
|
65
|
+
/******/ (() => {
|
66
|
+
/******/ // define getter functions for harmony exports
|
67
|
+
/******/ __webpack_require__.d = (exports, definition) => {
|
68
|
+
/******/ for(var key in definition) {
|
69
|
+
/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
|
70
|
+
/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
|
71
|
+
/******/ }
|
72
|
+
/******/ }
|
73
|
+
/******/ };
|
74
|
+
/******/ })();
|
75
|
+
/******/
|
76
|
+
/******/ /* webpack/runtime/hasOwnProperty shorthand */
|
77
|
+
/******/ (() => {
|
78
|
+
/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
|
79
|
+
/******/ })();
|
80
|
+
/******/
|
81
|
+
/******/ /* webpack/runtime/make namespace object */
|
82
|
+
/******/ (() => {
|
83
|
+
/******/ // define __esModule on exports
|
84
|
+
/******/ __webpack_require__.r = (exports) => {
|
85
|
+
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
|
86
|
+
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
87
|
+
/******/ }
|
88
|
+
/******/ Object.defineProperty(exports, '__esModule', { value: true });
|
89
|
+
/******/ };
|
90
|
+
/******/ })();
|
91
|
+
/******/
|
92
|
+
/************************************************************************/
|
93
|
+
var __webpack_exports__ = {};
|
94
|
+
// This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk.
|
95
|
+
(() => {
|
96
|
+
/*!**********************************************!*\
|
97
|
+
!*** ./src/core/MeganavControl/component.js ***!
|
98
|
+
\**********************************************/
|
99
|
+
__webpack_require__.r(__webpack_exports__);
|
100
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
101
|
+
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
102
|
+
/* harmony export */ });
|
103
|
+
/* harmony import */ var _dom_query__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../dom-query */ "./src/core/dom-query.js");
|
104
|
+
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
105
|
+
|
106
|
+
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
107
|
+
|
108
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
109
|
+
|
110
|
+
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
111
|
+
|
112
|
+
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
113
|
+
|
114
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
115
|
+
|
116
|
+
|
117
|
+
|
118
|
+
var MeganavControl = function MeganavControl() {
|
119
|
+
var controls = Array.from((0,_dom_query__WEBPACK_IMPORTED_MODULE_0__.queryIdAll)("meganav-control"));
|
120
|
+
var panels = Array.from((0,_dom_query__WEBPACK_IMPORTED_MODULE_0__.queryIdAll)("meganav-panel"));
|
121
|
+
var mdBreakpoint = getComputedStyle(document.documentElement).getPropertyValue("--bp-md");
|
122
|
+
|
123
|
+
var hoverEnabled = function hoverEnabled() {
|
124
|
+
return window.matchMedia("(hover: hover) and (pointer: fine) and (min-width: ".concat(mdBreakpoint, ")")).matches;
|
125
|
+
};
|
126
|
+
|
127
|
+
var isSearchControl = function isSearchControl(node) {
|
128
|
+
return node.dataset.control === "search";
|
129
|
+
};
|
130
|
+
|
131
|
+
var isSearchPanelOpen = function isSearchPanelOpen() {
|
132
|
+
var searchPanel = document.querySelector('[data-id="meganav-panel"]#panel-search');
|
133
|
+
if (!searchPanel) return;
|
134
|
+
return !searchPanel.classList.contains("invisible");
|
135
|
+
};
|
136
|
+
|
137
|
+
var controlsHaveFocus = function controlsHaveFocus() {
|
138
|
+
return controls.some(function (control) {
|
139
|
+
return control === document.activeElement;
|
140
|
+
});
|
141
|
+
};
|
142
|
+
|
143
|
+
var hover = function hover(control, panel, open) {
|
144
|
+
if (hoverEnabled() && !controlsHaveFocus() && !isSearchPanelOpen()) {
|
145
|
+
var _panel$classList;
|
146
|
+
|
147
|
+
var classes = ["invisible", "visible"];
|
148
|
+
|
149
|
+
(_panel$classList = panel.classList).replace.apply(_panel$classList, _toConsumableArray(open ? classes : classes.reverse()));
|
150
|
+
|
151
|
+
control.setAttribute("aria-expanded", open);
|
152
|
+
control.dataset.hover = open;
|
153
|
+
}
|
154
|
+
};
|
155
|
+
|
156
|
+
var mouseenterHandler = function mouseenterHandler(control, panel) {
|
157
|
+
return function () {
|
158
|
+
return hover(control, panel, true);
|
159
|
+
};
|
160
|
+
};
|
161
|
+
|
162
|
+
var mouseleaveHandler = function mouseleaveHandler(control, panel) {
|
163
|
+
return function () {
|
164
|
+
return hover(control, panel, false);
|
165
|
+
};
|
166
|
+
};
|
167
|
+
|
168
|
+
var clickHandler = function clickHandler(control, panel) {
|
169
|
+
return function () {
|
170
|
+
controls.forEach(function (node) {
|
171
|
+
return node !== control && node.setAttribute("aria-expanded", false);
|
172
|
+
});
|
173
|
+
panels.forEach(function (node) {
|
174
|
+
return node !== panel && node.classList.replace("visible", "invisible");
|
175
|
+
});
|
176
|
+
var ariaExpanded = control.getAttribute("aria-expanded"); // Prevent closing of the panel if it was already opened by hovering
|
177
|
+
|
178
|
+
var openedByHover = control.dataset.hover === "true";
|
179
|
+
|
180
|
+
if (ariaExpanded === "true" && !openedByHover) {
|
181
|
+
control.setAttribute("aria-expanded", false);
|
182
|
+
panel.classList.replace("visible", "invisible");
|
183
|
+
} else {
|
184
|
+
control.setAttribute("aria-expanded", true);
|
185
|
+
panel.classList.replace("invisible", "visible");
|
186
|
+
}
|
187
|
+
|
188
|
+
if (openedByHover) {
|
189
|
+
control.dataset.hover = false;
|
190
|
+
}
|
191
|
+
|
192
|
+
if (isSearchControl(control)) {
|
193
|
+
var searchInput = (0,_dom_query__WEBPACK_IMPORTED_MODULE_0__.queryId)("meganav-search-input", panel);
|
194
|
+
if (!searchInput) return;
|
195
|
+
searchInput.focus();
|
196
|
+
} else {
|
197
|
+
control.focus();
|
198
|
+
}
|
199
|
+
};
|
200
|
+
};
|
201
|
+
|
202
|
+
return controls.map(function (control) {
|
203
|
+
var item = control.parentNode;
|
204
|
+
var panel = document.querySelector("#".concat(control.getAttribute("aria-controls")));
|
205
|
+
var click = clickHandler(control, panel);
|
206
|
+
control.addEventListener("click", click);
|
207
|
+
var mouseenter, mouseleave;
|
208
|
+
|
209
|
+
if (!isSearchControl(control)) {
|
210
|
+
mouseenter = mouseenterHandler(control, panel);
|
211
|
+
mouseleave = mouseleaveHandler(control, panel);
|
212
|
+
item.addEventListener("mouseenter", mouseenter);
|
213
|
+
item.addEventListener("mouseleave", mouseleave);
|
214
|
+
}
|
215
|
+
|
216
|
+
return [{
|
217
|
+
teardown: function teardown() {
|
218
|
+
if (mouseenter && mouseleave) {
|
219
|
+
item.removeEventListener("mouseenter", mouseenter);
|
220
|
+
item.removeEventListener("mouseleave", mouseleave);
|
221
|
+
}
|
222
|
+
|
223
|
+
control.removeEventListener("click", click);
|
224
|
+
},
|
225
|
+
clear: function clear() {
|
226
|
+
control.setAttribute("aria-expanded", false);
|
227
|
+
panel.classList.replace("visible", "invisible");
|
228
|
+
}
|
229
|
+
}];
|
230
|
+
}).flat();
|
231
|
+
};
|
232
|
+
|
233
|
+
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (MeganavControl);
|
234
|
+
})();
|
235
|
+
|
236
|
+
__webpack_exports__ = __webpack_exports__["default"];
|
237
|
+
/******/ return __webpack_exports__;
|
238
|
+
/******/ })()
|
239
|
+
;
|
240
|
+
});
|
241
|
+
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29yZS9NZWdhbmF2Q29udHJvbC9jb21wb25lbnQuanMiLCJtYXBwaW5ncyI6IkFBQUE7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNB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ic2VhcmNoSW5wdXQiLCJmb2N1cyIsIm1hcCIsIml0ZW0iLCJwYXJlbnROb2RlIiwiY2xpY2siLCJhZGRFdmVudExpc3RlbmVyIiwibW91c2VlbnRlciIsIm1vdXNlbGVhdmUiLCJ0ZWFyZG93biIsInJlbW92ZUV2ZW50TGlzdGVuZXIiLCJjbGVhciIsImZsYXQiXSwic291cmNlUm9vdCI6IiJ9
|
@@ -1 +1,180 @@
|
|
1
|
-
|
1
|
+
(function webpackUniversalModuleDefinition(root, factory) {
|
2
|
+
if(typeof exports === 'object' && typeof module === 'object')
|
3
|
+
module.exports = factory(require("scroll-lock"));
|
4
|
+
else if(typeof define === 'function' && define.amd)
|
5
|
+
define([], factory);
|
6
|
+
else if(typeof exports === 'object')
|
7
|
+
exports["AblyUi"] = factory(require("scroll-lock"));
|
8
|
+
else
|
9
|
+
root["AblyUi"] = root["AblyUi"] || {}, root["AblyUi"]["Core"] = root["AblyUi"]["Core"] || {}, root["AblyUi"]["Core"]["MeganavControlMobileDropdown"] = factory(root[undefined]);
|
10
|
+
})(this, (__WEBPACK_EXTERNAL_MODULE_scroll_lock__) => {
|
11
|
+
return /******/ (() => { // webpackBootstrap
|
12
|
+
/******/ "use strict";
|
13
|
+
/******/ var __webpack_modules__ = ({
|
14
|
+
|
15
|
+
/***/ "./src/core/dom-query.js":
|
16
|
+
/*!*******************************!*\
|
17
|
+
!*** ./src/core/dom-query.js ***!
|
18
|
+
\*******************************/
|
19
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
20
|
+
|
21
|
+
__webpack_require__.r(__webpack_exports__);
|
22
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
23
|
+
/* harmony export */ "queryId": () => (/* binding */ queryId),
|
24
|
+
/* harmony export */ "queryIdAll": () => (/* binding */ queryIdAll)
|
25
|
+
/* harmony export */ });
|
26
|
+
var queryId = function queryId(val) {
|
27
|
+
var root = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : document;
|
28
|
+
return root.querySelector("[data-id=".concat(val, "]"));
|
29
|
+
};
|
30
|
+
var queryIdAll = function queryIdAll(val) {
|
31
|
+
var root = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : document;
|
32
|
+
return root.querySelectorAll("[data-id=".concat(val, "]"));
|
33
|
+
};
|
34
|
+
|
35
|
+
/***/ }),
|
36
|
+
|
37
|
+
/***/ "scroll-lock":
|
38
|
+
/*!*********************************************************************!*\
|
39
|
+
!*** external {"commonjs":"scroll-lock","commonjs2":"scroll-lock"} ***!
|
40
|
+
\*********************************************************************/
|
41
|
+
/***/ ((module) => {
|
42
|
+
|
43
|
+
module.exports = __WEBPACK_EXTERNAL_MODULE_scroll_lock__;
|
44
|
+
|
45
|
+
/***/ })
|
46
|
+
|
47
|
+
/******/ });
|
48
|
+
/************************************************************************/
|
49
|
+
/******/ // The module cache
|
50
|
+
/******/ var __webpack_module_cache__ = {};
|
51
|
+
/******/
|
52
|
+
/******/ // The require function
|
53
|
+
/******/ function __webpack_require__(moduleId) {
|
54
|
+
/******/ // Check if module is in cache
|
55
|
+
/******/ var cachedModule = __webpack_module_cache__[moduleId];
|
56
|
+
/******/ if (cachedModule !== undefined) {
|
57
|
+
/******/ return cachedModule.exports;
|
58
|
+
/******/ }
|
59
|
+
/******/ // Create a new module (and put it into the cache)
|
60
|
+
/******/ var module = __webpack_module_cache__[moduleId] = {
|
61
|
+
/******/ // no module.id needed
|
62
|
+
/******/ // no module.loaded needed
|
63
|
+
/******/ exports: {}
|
64
|
+
/******/ };
|
65
|
+
/******/
|
66
|
+
/******/ // Execute the module function
|
67
|
+
/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
|
68
|
+
/******/
|
69
|
+
/******/ // Return the exports of the module
|
70
|
+
/******/ return module.exports;
|
71
|
+
/******/ }
|
72
|
+
/******/
|
73
|
+
/************************************************************************/
|
74
|
+
/******/ /* webpack/runtime/compat get default export */
|
75
|
+
/******/ (() => {
|
76
|
+
/******/ // getDefaultExport function for compatibility with non-harmony modules
|
77
|
+
/******/ __webpack_require__.n = (module) => {
|
78
|
+
/******/ var getter = module && module.__esModule ?
|
79
|
+
/******/ () => (module['default']) :
|
80
|
+
/******/ () => (module);
|
81
|
+
/******/ __webpack_require__.d(getter, { a: getter });
|
82
|
+
/******/ return getter;
|
83
|
+
/******/ };
|
84
|
+
/******/ })();
|
85
|
+
/******/
|
86
|
+
/******/ /* webpack/runtime/define property getters */
|
87
|
+
/******/ (() => {
|
88
|
+
/******/ // define getter functions for harmony exports
|
89
|
+
/******/ __webpack_require__.d = (exports, definition) => {
|
90
|
+
/******/ for(var key in definition) {
|
91
|
+
/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
|
92
|
+
/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
|
93
|
+
/******/ }
|
94
|
+
/******/ }
|
95
|
+
/******/ };
|
96
|
+
/******/ })();
|
97
|
+
/******/
|
98
|
+
/******/ /* webpack/runtime/hasOwnProperty shorthand */
|
99
|
+
/******/ (() => {
|
100
|
+
/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
|
101
|
+
/******/ })();
|
102
|
+
/******/
|
103
|
+
/******/ /* webpack/runtime/make namespace object */
|
104
|
+
/******/ (() => {
|
105
|
+
/******/ // define __esModule on exports
|
106
|
+
/******/ __webpack_require__.r = (exports) => {
|
107
|
+
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
|
108
|
+
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
109
|
+
/******/ }
|
110
|
+
/******/ Object.defineProperty(exports, '__esModule', { value: true });
|
111
|
+
/******/ };
|
112
|
+
/******/ })();
|
113
|
+
/******/
|
114
|
+
/************************************************************************/
|
115
|
+
var __webpack_exports__ = {};
|
116
|
+
// This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk.
|
117
|
+
(() => {
|
118
|
+
/*!************************************************************!*\
|
119
|
+
!*** ./src/core/MeganavControlMobileDropdown/component.js ***!
|
120
|
+
\************************************************************/
|
121
|
+
__webpack_require__.r(__webpack_exports__);
|
122
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
123
|
+
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
124
|
+
/* harmony export */ });
|
125
|
+
/* harmony import */ var scroll_lock__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! scroll-lock */ "scroll-lock");
|
126
|
+
/* harmony import */ var scroll_lock__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(scroll_lock__WEBPACK_IMPORTED_MODULE_0__);
|
127
|
+
/* harmony import */ var _dom_query__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../dom-query */ "./src/core/dom-query.js");
|
128
|
+
|
129
|
+
|
130
|
+
|
131
|
+
var MeganavControlMobileDropdown = function MeganavControlMobileDropdown(_ref) {
|
132
|
+
var clearPanels = _ref.clearPanels;
|
133
|
+
var control = (0,_dom_query__WEBPACK_IMPORTED_MODULE_1__.queryId)("meganav-control-mobile-dropdown");
|
134
|
+
var dropdown = (0,_dom_query__WEBPACK_IMPORTED_MODULE_1__.queryId)("meganav-mobile-dropdown");
|
135
|
+
var menuIcon = (0,_dom_query__WEBPACK_IMPORTED_MODULE_1__.queryId)("meganav-control-mobile-dropdown-menu");
|
136
|
+
var closeIcon = (0,_dom_query__WEBPACK_IMPORTED_MODULE_1__.queryId)("meganav-control-mobile-dropdown-close");
|
137
|
+
|
138
|
+
var clickHandler = function clickHandler() {
|
139
|
+
var ariaExpanded = control.getAttribute("aria-expanded");
|
140
|
+
|
141
|
+
if (ariaExpanded === "false") {
|
142
|
+
dropdown.classList.replace("invisible", "visible");
|
143
|
+
control.setAttribute("aria-expanded", true);
|
144
|
+
scroll_lock__WEBPACK_IMPORTED_MODULE_0___default().disablePageScroll();
|
145
|
+
} else {
|
146
|
+
dropdown.classList.replace("visible", "invisible");
|
147
|
+
control.setAttribute("aria-expanded", false);
|
148
|
+
scroll_lock__WEBPACK_IMPORTED_MODULE_0___default().enablePageScroll();
|
149
|
+
clearPanels();
|
150
|
+
}
|
151
|
+
|
152
|
+
menuIcon.classList.toggle("hidden");
|
153
|
+
closeIcon.classList.toggle("hidden");
|
154
|
+
};
|
155
|
+
|
156
|
+
control.addEventListener("click", clickHandler);
|
157
|
+
return {
|
158
|
+
teardown: function teardown() {
|
159
|
+
control.removeEventListener("click", clickHandler);
|
160
|
+
scroll_lock__WEBPACK_IMPORTED_MODULE_0___default().enablePageScroll();
|
161
|
+
},
|
162
|
+
clear: function clear() {
|
163
|
+
dropdown.classList.replace("visible", "invisible");
|
164
|
+
control.setAttribute("aria-expanded", false);
|
165
|
+
menuIcon.classList.remove("hidden");
|
166
|
+
closeIcon.classList.add("hidden");
|
167
|
+
scroll_lock__WEBPACK_IMPORTED_MODULE_0___default().enablePageScroll();
|
168
|
+
}
|
169
|
+
};
|
170
|
+
};
|
171
|
+
|
172
|
+
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (MeganavControlMobileDropdown);
|
173
|
+
})();
|
174
|
+
|
175
|
+
__webpack_exports__ = __webpack_exports__["default"];
|
176
|
+
/******/ return __webpack_exports__;
|
177
|
+
/******/ })()
|
178
|
+
;
|
179
|
+
});
|
180
|
+
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29yZS9NZWdhbmF2Q29udHJvbE1vYmlsZURyb3Bkb3duL2NvbXBvbmVudC5qcyIsIm1hcHBpbmdzIjoiQUFBQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EsdUNBQXVDLHVEQUF1RDtBQUM5RixDQUFDO0FBQ0QsTzs7Ozs7Ozs7Ozs7Ozs7O0FDVk8sSUFBTUEsT0FBTyxHQUFHLFNBQVZBLE9BQVUsQ0FBQ0MsR0FBRDtBQUFBLE1BQU1D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bnVJY29uLmNsYXNzTGlzdC5yZW1vdmUoXCJoaWRkZW5cIik7XG4gICAgICBjbG9zZUljb24uY2xhc3NMaXN0LmFkZChcImhpZGRlblwiKTtcbiAgICAgIHNjcm9sbExvY2suZW5hYmxlUGFnZVNjcm9sbCgpO1xuICAgIH0sXG4gIH07XG59O1xuXG5leHBvcnQgZGVmYXVsdCBNZWdhbmF2Q29udHJvbE1vYmlsZURyb3Bkb3duO1xuIl0sIm5hbWVzIjpbInF1ZXJ5SWQiLCJ2YWwiLCJyb290IiwiZG9jdW1lbnQiLCJxdWVyeVNlbGVjdG9yIiwicXVlcnlJZEFsbCIsInF1ZXJ5U2VsZWN0b3JBbGwiLCJzY3JvbGxMb2NrIiwiTWVnYW5hdkNvbnRyb2xNb2JpbGVEcm9wZG93biIsImNsZWFyUGFuZWxzIiwiY29udHJvbCIsImRyb3Bkb3duIiwibWVudUljb24iLCJjbG9zZUljb24iLCJjbGlja0hhbmRsZXIiLCJhcmlhRXhwYW5kZWQiLCJnZXRBdHRyaWJ1dGUiLCJjbGFzc0xpc3QiLCJyZXBsYWNlIiwic2V0QXR0cmlidXRlIiwiZGlzYWJsZVBhZ2VTY3JvbGwiLCJlbmFibGVQYWdlU2Nyb2xsIiwidG9nZ2xlIiwiYWRkRXZlbnRMaXN0ZW5lciIsInRlYXJkb3duIiwicmVtb3ZlRXZlbnRMaXN0ZW5lciIsImNsZWFyIiwicmVtb3ZlIiwiYWRkIl0sInNvdXJjZVJvb3QiOiIifQ==
|
@@ -1 +1,142 @@
|
|
1
|
-
|
1
|
+
(function webpackUniversalModuleDefinition(root, factory) {
|
2
|
+
if(typeof exports === 'object' && typeof module === 'object')
|
3
|
+
module.exports = factory();
|
4
|
+
else if(typeof define === 'function' && define.amd)
|
5
|
+
define([], factory);
|
6
|
+
else if(typeof exports === 'object')
|
7
|
+
exports["AblyUi"] = factory();
|
8
|
+
else
|
9
|
+
root["AblyUi"] = root["AblyUi"] || {}, root["AblyUi"]["Core"] = root["AblyUi"]["Core"] || {}, root["AblyUi"]["Core"]["MeganavControlMobilePanelClose"] = factory();
|
10
|
+
})(this, () => {
|
11
|
+
return /******/ (() => { // webpackBootstrap
|
12
|
+
/******/ "use strict";
|
13
|
+
/******/ var __webpack_modules__ = ({
|
14
|
+
|
15
|
+
/***/ "./src/core/dom-query.js":
|
16
|
+
/*!*******************************!*\
|
17
|
+
!*** ./src/core/dom-query.js ***!
|
18
|
+
\*******************************/
|
19
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
20
|
+
|
21
|
+
__webpack_require__.r(__webpack_exports__);
|
22
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
23
|
+
/* harmony export */ "queryId": () => (/* binding */ queryId),
|
24
|
+
/* harmony export */ "queryIdAll": () => (/* binding */ queryIdAll)
|
25
|
+
/* harmony export */ });
|
26
|
+
var queryId = function queryId(val) {
|
27
|
+
var root = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : document;
|
28
|
+
return root.querySelector("[data-id=".concat(val, "]"));
|
29
|
+
};
|
30
|
+
var queryIdAll = function queryIdAll(val) {
|
31
|
+
var root = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : document;
|
32
|
+
return root.querySelectorAll("[data-id=".concat(val, "]"));
|
33
|
+
};
|
34
|
+
|
35
|
+
/***/ })
|
36
|
+
|
37
|
+
/******/ });
|
38
|
+
/************************************************************************/
|
39
|
+
/******/ // The module cache
|
40
|
+
/******/ var __webpack_module_cache__ = {};
|
41
|
+
/******/
|
42
|
+
/******/ // The require function
|
43
|
+
/******/ function __webpack_require__(moduleId) {
|
44
|
+
/******/ // Check if module is in cache
|
45
|
+
/******/ var cachedModule = __webpack_module_cache__[moduleId];
|
46
|
+
/******/ if (cachedModule !== undefined) {
|
47
|
+
/******/ return cachedModule.exports;
|
48
|
+
/******/ }
|
49
|
+
/******/ // Create a new module (and put it into the cache)
|
50
|
+
/******/ var module = __webpack_module_cache__[moduleId] = {
|
51
|
+
/******/ // no module.id needed
|
52
|
+
/******/ // no module.loaded needed
|
53
|
+
/******/ exports: {}
|
54
|
+
/******/ };
|
55
|
+
/******/
|
56
|
+
/******/ // Execute the module function
|
57
|
+
/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
|
58
|
+
/******/
|
59
|
+
/******/ // Return the exports of the module
|
60
|
+
/******/ return module.exports;
|
61
|
+
/******/ }
|
62
|
+
/******/
|
63
|
+
/************************************************************************/
|
64
|
+
/******/ /* webpack/runtime/define property getters */
|
65
|
+
/******/ (() => {
|
66
|
+
/******/ // define getter functions for harmony exports
|
67
|
+
/******/ __webpack_require__.d = (exports, definition) => {
|
68
|
+
/******/ for(var key in definition) {
|
69
|
+
/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
|
70
|
+
/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
|
71
|
+
/******/ }
|
72
|
+
/******/ }
|
73
|
+
/******/ };
|
74
|
+
/******/ })();
|
75
|
+
/******/
|
76
|
+
/******/ /* webpack/runtime/hasOwnProperty shorthand */
|
77
|
+
/******/ (() => {
|
78
|
+
/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
|
79
|
+
/******/ })();
|
80
|
+
/******/
|
81
|
+
/******/ /* webpack/runtime/make namespace object */
|
82
|
+
/******/ (() => {
|
83
|
+
/******/ // define __esModule on exports
|
84
|
+
/******/ __webpack_require__.r = (exports) => {
|
85
|
+
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
|
86
|
+
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
87
|
+
/******/ }
|
88
|
+
/******/ Object.defineProperty(exports, '__esModule', { value: true });
|
89
|
+
/******/ };
|
90
|
+
/******/ })();
|
91
|
+
/******/
|
92
|
+
/************************************************************************/
|
93
|
+
var __webpack_exports__ = {};
|
94
|
+
// This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk.
|
95
|
+
(() => {
|
96
|
+
/*!**************************************************************!*\
|
97
|
+
!*** ./src/core/MeganavControlMobilePanelClose/component.js ***!
|
98
|
+
\**************************************************************/
|
99
|
+
__webpack_require__.r(__webpack_exports__);
|
100
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
101
|
+
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
102
|
+
/* harmony export */ });
|
103
|
+
/* harmony import */ var _dom_query__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../dom-query */ "./src/core/dom-query.js");
|
104
|
+
|
105
|
+
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (function () {
|
106
|
+
var closeControls = Array.from((0,_dom_query__WEBPACK_IMPORTED_MODULE_0__.queryIdAll)("meganav-control-mobile-panel-close"));
|
107
|
+
var openControls = Array.from((0,_dom_query__WEBPACK_IMPORTED_MODULE_0__.queryIdAll)("meganav-control-mobile-panel-open"));
|
108
|
+
|
109
|
+
var clickHandler = function clickHandler(btn, openBtn, panel) {
|
110
|
+
return function () {
|
111
|
+
btn.setAttribute("aria-expanded", false);
|
112
|
+
openBtn.setAttribute("aria-expanded", false);
|
113
|
+
panel.classList.replace("block", "hidden");
|
114
|
+
panel.style.height = null;
|
115
|
+
};
|
116
|
+
};
|
117
|
+
|
118
|
+
return closeControls.map(function (btn) {
|
119
|
+
var openBtn = openControls.find(function (open) {
|
120
|
+
return open.getAttribute("aria-controls") === btn.getAttribute("aria-controls");
|
121
|
+
});
|
122
|
+
var panel = document.querySelector("#".concat(btn.getAttribute("aria-controls")));
|
123
|
+
var handler = clickHandler(btn, openBtn, panel);
|
124
|
+
btn.addEventListener("click", handler);
|
125
|
+
return {
|
126
|
+
teardown: function teardown() {
|
127
|
+
return btn.removeEventListener("click", handler);
|
128
|
+
},
|
129
|
+
clear: function clear() {
|
130
|
+
return btn.setAttribute("aria-expanded", false);
|
131
|
+
}
|
132
|
+
};
|
133
|
+
});
|
134
|
+
});
|
135
|
+
})();
|
136
|
+
|
137
|
+
__webpack_exports__ = __webpack_exports__["default"];
|
138
|
+
/******/ return __webpack_exports__;
|
139
|
+
/******/ })()
|
140
|
+
;
|
141
|
+
});
|
142
|
+
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29yZS9NZWdhbmF2Q29udHJvbE1vYmlsZVBhbmVsQ2xvc2UvY29tcG9uZW50LmpzIiwibWFwcGluZ3MiOiJBQUFBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSx1Q0FBdUMsdURBQXVEO0FBQzlGLENBQUM7QUFDRCxPOzs7Ozs7Ozs7Ozs7Ozs7QUNWTyxJQUFNQSxPQUFPLEdBQUcsU0FBVkEsT0FBVSxDQUFDQyxHQUFEO0FBQUEsTUFBTUMsSUFBTix1RUFBYUMsUUFBYjtBQUFBLFNBQ3JCRCxJQUFJLENBQUNFLGFBQUwsb0JBQStCSCxHQUEvQixPQURxQjtBQUFBLENBQWhCO0FBR0EsSUFBTUksVUFBVSxHQUFHLFNBQWJBLFVBQWEsQ0FBQ0osR0FBRDtBQUFBLE1BQU1DLElBQU4sdUVBQWFDLFFBQWI7QUFBQSxTQUN4QkQsSUFBSSxDQUFDSSxnQkFBTCxvQkFBa0NMLEdBQWxDLE9BRHdCO0FBQUEsQ0FBbkI7Ozs7OztVQ0hQO1VBQ0E7O1VBRUE7VUFDQTtVQUNBO1VBQ0E7VUFDQTtVQUNBO1VBQ0E7VUFDQTtVQUNBO1VBQ0E7VUFDQTtVQUNBO1VBQ0E7O1VBRUE7VUFDQTs7VUFFQTtVQUNBO1VBQ0E7Ozs7O1dDdEJBO1dBQ0E7V0FDQTtXQUNBO1dBQ0EseUNBQXlDLHdDQUF3QztXQUNqRjtXQUNBO1dBQ0E7Ozs7O1dDUEE7Ozs7O1dDQUE7V0FDQTtXQUNBO1dBQ0EsdURBQXVELGlCQUFpQjtXQUN4RTtXQU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