ably-ui 7.10.0 → 8.0.0.dev.7e3a14d

Sign up to get free protection for your applications and to get access to all the features.
Files changed (29) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +1 -1
  3. data/lib/ably_ui/core/fonts/source-code-pro.css +3 -0
  4. data/lib/ably_ui/core/icon/component.css +1 -0
  5. data/lib/ably_ui/core/meganav/component.css +5 -1
  6. data/lib/ably_ui/core/meganav/component.js +2 -1
  7. data/lib/ably_ui/core/meganav/meganav.html.erb +10 -5
  8. data/lib/ably_ui/core/meganav_content_platform/meganav_content_platform.html.erb +24 -18
  9. data/lib/ably_ui/core/meganav_control/component.js +1 -1
  10. data/lib/ably_ui/core/meganav_control/meganav_control.html.erb +2 -2
  11. data/lib/ably_ui/core/meganav_control/meganav_control.rb +3 -1
  12. data/lib/ably_ui/core/meganav_items_mobile/meganav_items_mobile.html.erb +30 -2
  13. data/lib/ably_ui/core/meganav_items_signed_in/meganav_items_signed_in.html.erb +6 -2
  14. data/lib/ably_ui/core/meganav_search/component.js +1 -0
  15. data/lib/ably_ui/core/meganav_search/meganav_search.html.erb +15 -0
  16. data/lib/ably_ui/core/meganav_search/meganav_search.rb +13 -0
  17. data/lib/ably_ui/core/meganav_search_autocomplete/component.js +2 -0
  18. data/lib/ably_ui/core/meganav_search_autocomplete/meganav_search_autocomplete.html.erb +6 -0
  19. data/lib/ably_ui/core/meganav_search_autocomplete/meganav_search_autocomplete.rb +6 -0
  20. data/lib/ably_ui/core/meganav_search_panel/component.js +1 -0
  21. data/lib/ably_ui/core/meganav_search_panel/meganav_search_panel.html.erb +22 -0
  22. data/lib/ably_ui/core/meganav_search_panel/meganav_search_panel.rb +13 -0
  23. data/lib/ably_ui/core/meganav_search_suggestions/component.js +1 -0
  24. data/lib/ably_ui/core/meganav_search_suggestions/meganav_search_suggestions.html.erb +22 -0
  25. data/lib/ably_ui/core/meganav_search_suggestions/meganav_search_suggestions.rb +18 -0
  26. data/lib/ably_ui/core/scripts.js +1 -1
  27. data/lib/ably_ui/core/styles.css +18 -36
  28. data/lib/ably_ui/version.rb +1 -1
  29. metadata +23 -9
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 460a704f715b5b23ae780bb23f65c36fbc40d0b91571581bf9b6cce22ba29d1d
4
- data.tar.gz: 3c2a8330e3d44f947f8d76fe2ab28a29dd1759c2cc5a8e32193fe6dab09b6c01
3
+ metadata.gz: 5ede766427f7dafc1ccd7f2f69876fe3e51fe22879fa6c45e22b4d01302ec061
4
+ data.tar.gz: 3079c22c62d9864d49bc287b006f7aedc5cfecbcbaf8e44c9aa5a2535bcb4c95
5
5
  SHA512:
6
- metadata.gz: 765f348f47d37b3c26a0539c457854b9d55fefedcbb2dc198030780b01f16d276ec707472e28c216e0468acbf8c13dbdb609c398c0d1bfc0082fc7bcff245abe
7
- data.tar.gz: 42bc5ba1a718c9ea373cc7ce1e06b4a5961946cd0f311b17614d05f756e88bf09e056841237aab957d4e8da34350e453d206e7f0b9e322e1f9733dde2488e608
6
+ metadata.gz: ad57214d95a9aa6a67ed3973bce7702c40f92c5a0128da5333b300f8cadc775f70aad34220bf6428570b9d57d1de94f6b2058958eb675ce19329c90030c71c8b
7
+ data.tar.gz: 71a27ddddb09072652047817c1d7e4faa791562c5e530909e6048488eeb8f72d75a7ec6be867a128128a015c60c66efc9aa5e56e4ccd8c0e0a14392a0859f7f0
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- ably-ui (7.9.3.dev.7c9a58e)
4
+ ably-ui (8.0.0.dev.467d57d)
5
5
  view_component (>= 2.33, < 2.50)
6
6
 
7
7
  GEM
@@ -0,0 +1,3 @@
1
+ @layer base {
2
+ @import url("https://fonts.googleapis.com/css2?family=Source+Code+Pro:wght@600&display=swap");
3
+ }
@@ -0,0 +1 @@
1
+
@@ -48,11 +48,15 @@
48
48
 
49
49
  .ui-meganav-link {
50
50
  @apply text-menu2 font-medium block;
51
- @apply mx-8 lg:mx-12 px-0 py-20;
51
+ @apply mr-12 lg:mr-24 px-0 py-20;
52
52
  @apply hover:text-gui-hover focus:text-gui-focus focus:outline-none;
53
53
  @apply transition-colors;
54
54
  }
55
55
 
56
+ .ui-meganav-item {
57
+ flex: 1 0 auto;
58
+ }
59
+
56
60
  .ui-meganav-mobile-link {
57
61
  @apply p-menu-row relative -left-8 w-extend-8;
58
62
  @apply text-menu2 font-medium block text-cool-black text-left;
@@ -1 +1,2 @@
1
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.AblyUi=t():(e.AblyUi=e.AblyUi||{},e.AblyUi.Core=e.AblyUi.Core||{},e.AblyUi.Core.Meganav=t())}(this,(function(){return(()=>{var e={2498:(e,t,r)=>{"use strict";r.d(t,{default:()=>l});var n=r(9581);function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}const l=function(){var e=Array.from((0,n.n)("meganav-control")),t=Array.from((0,n.n)("meganav-panel")),r=getComputedStyle(document.documentElement).getPropertyValue("--bp-md"),l=function(t,n,l){if(window.matchMedia("(hover: hover) and (pointer: fine) and (min-width: ".concat(r,")")).matches&&!e.some((function(e){return e===document.activeElement}))){var i,a=["invisible","visible"];(i=n.classList).replace.apply(i,function(e){if(Array.isArray(e))return o(e)}(c=l?a:a.reverse())||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(c)||function(e,t){if(e){if("string"==typeof e)return o(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?o(e,t):void 0}}(c)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),t.setAttribute("aria-expanded",l)}var c};return e.map((function(r){var n=r.parentNode,o=document.querySelector("#".concat(r.getAttribute("aria-controls"))),i=function(r,n){return function(){e.forEach((function(e){return e!==r&&e.setAttribute("aria-expanded",!1)})),t.forEach((function(e){return e!==n&&e.classList.replace("visible","invisible")})),r.getAttribute("aria-expanded")?(r.setAttribute("aria-expanded",!0),n.classList.replace("invisible","visible")):(r.setAttribute("aria-expanded",!1),n.classList.replace("visible","invisible"))}}(r,o),a=function(e,t){return function(){return l(e,t,!0)}}(r,o),c=function(e,t){return function(){return l(e,t,!1)}}(r,o);return n.addEventListener("mouseenter",a),n.addEventListener("mouseleave",c),r.addEventListener("click",i),[{teardown:function(){n.removeEventListener("mouseenter",a),n.removeEventListener("mouseleave",c),r.removeEventListener("click",i)},clear:function(){r.setAttribute("aria-expanded",!1),o.classList.replace("visible","invisible")}}]})).flat()}},1792:(e,t,r)=>{"use strict";r.d(t,{default:()=>i});var n=r(6265),o=r.n(n),l=r(9581);const i=function(e){var t=e.clearPanels,r=(0,l.A)("meganav-control-mobile-dropdown"),n=(0,l.A)("meganav-mobile-dropdown"),i=(0,l.A)("meganav-control-mobile-dropdown-menu"),a=(0,l.A)("meganav-control-mobile-dropdown-close"),c=function(){"false"===r.getAttribute("aria-expanded")?(n.classList.replace("invisible","visible"),r.setAttribute("aria-expanded",!0),o().disablePageScroll()):(n.classList.replace("visible","invisible"),r.setAttribute("aria-expanded",!1),o().enablePageScroll(),t()),i.classList.toggle("hidden"),a.classList.toggle("hidden")};return r.addEventListener("click",c),{teardown:function(){r.removeEventListener("click",c),o().enablePageScroll()},clear:function(){n.classList.replace("visible","invisible"),r.setAttribute("aria-expanded",!1),i.classList.remove("hidden"),a.classList.add("hidden"),o().enablePageScroll()}}}},7359:(e,t,r)=>{"use strict";r.d(t,{default:()=>o});var n=r(9581);const o=function(){var e=Array.from((0,n.n)("meganav-control-mobile-panel-close")),t=Array.from((0,n.n)("meganav-control-mobile-panel-open"));return e.map((function(e){var r=t.find((function(t){return t.getAttribute("aria-controls")===e.getAttribute("aria-controls")})),n=document.querySelector("#".concat(e.getAttribute("aria-controls"))),o=function(e,t,r){return function(){e.setAttribute("aria-expanded",!1),t.setAttribute("aria-expanded",!1),r.classList.replace("block","hidden"),r.style.height=null}}(e,r,n);return e.addEventListener("click",o),{teardown:function(){return e.removeEventListener("click",o)},clear:function(){return e.setAttribute("aria-expanded",!1)}}}))}},9552:(e,t,r)=>{"use strict";r.d(t,{default:()=>o});var n=r(9581);const o=function(){var e,t=Array.from((0,n.n)("meganav-control-mobile-panel-close")),r=Array.from((0,n.n)("meganav-control-mobile-panel-open")),o=(0,n.A)("meganav-mobile-dropdown"),l=(e=getComputedStyle(document.documentElement).getPropertyValue("--ui-meganav-height"),parseFloat(e)*parseFloat(getComputedStyle(document.documentElement).fontSize));return r.map((function(e){var r=t.find((function(t){return t.getAttribute("aria-controls")===e.getAttribute("aria-controls")})),n=document.querySelector("#".concat(e.getAttribute("aria-controls"))),i=function(e,t,r){return function(){e.setAttribute("aria-expanded",!0),t.setAttribute("aria-expanded",!0),r.classList.replace("hidden","block"),r.style.height="".concat(window.innerHeight-l>r.offsetHeight?r.offsetHeight:window.innerHeight-l,"px")}}(e,r,n);return e.addEventListener("click",i),{teardown:function(){return e.removeEventListener("click",i)},clear:function(){n.classList.replace("block","hidden"),o.classList.remove("ui-meganav-mobile-dropdown-expand"),e.setAttribute("aria-expanded",!1),n.style.height=null}}}))}},9581:(e,t,r)=>{"use strict";r.d(t,{A:()=>n,n:()=>o});var n=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;return t.querySelector("[data-id=".concat(e,"]"))},o=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;return t.querySelectorAll("[data-id=".concat(e,"]"))}},3096:(e,t,r)=>{var n="Expected a function",o=/^\s+|\s+$/g,l=/^[-+]0x[0-9a-f]+$/i,i=/^0b[01]+$/i,a=/^0o[0-7]+$/i,c=parseInt,u="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g,s="object"==typeof self&&self&&self.Object===Object&&self,d=u||s||Function("return this")(),f=Object.prototype.toString,p=Math.max,g=Math.min,b=function(){return d.Date.now()};function v(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function m(e){if("number"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==f.call(e)}(e))return NaN;if(v(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=v(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(o,"");var r=i.test(e);return r||a.test(e)?c(e.slice(2),r?2:8):l.test(e)?NaN:+e}e.exports=function(e,t,r){var o=!0,l=!0;if("function"!=typeof e)throw new TypeError(n);return v(r)&&(o="leading"in r?!!r.leading:o,l="trailing"in r?!!r.trailing:l),function(e,t,r){var o,l,i,a,c,u,s=0,d=!1,f=!1,h=!0;if("function"!=typeof e)throw new TypeError(n);function y(t){var r=o,n=l;return o=l=void 0,s=t,a=e.apply(n,r)}function S(e){return s=e,c=setTimeout(A,t),d?y(e):a}function w(e){var r=e-u;return void 0===u||r>=t||r<0||f&&e-s>=i}function A(){var e=b();if(w(e))return k(e);c=setTimeout(A,function(e){var r=t-(e-u);return f?g(r,i-(e-s)):r}(e))}function k(e){return c=void 0,h&&o?y(e):(o=l=void 0,a)}function L(){var e=b(),r=w(e);if(o=arguments,l=this,u=e,r){if(void 0===c)return S(u);if(f)return c=setTimeout(A,t),y(u)}return void 0===c&&(c=setTimeout(A,t)),a}return t=m(t)||0,v(r)&&(d=!!r.leading,i=(f="maxWait"in r)?p(m(r.maxWait)||0,t):i,h="trailing"in r?!!r.trailing:h),L.cancel=function(){void 0!==c&&clearTimeout(c),s=0,o=u=l=c=void 0},L.flush=function(){return void 0===c?a:k(b())},L}(e,t,{leading:o,maxWait:t,trailing:l})}},6265:function(e){var t;t=function(){return function(e){var t={};function r(n){if(t[n])return t[n].exports;var o=t[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=0)}([function(e,t,r){"use strict";r.r(t);var n=function(e){return Array.isArray(e)?e:[e]},o=function(e){return e instanceof Node},l=function(e,t){if(e&&t){e=function(e){return e instanceof NodeList}(e)?e:[e];for(var r=0;r<e.length&&!0!==t(e[r],r,e.length);r++);}},i=function(e){return console.error("[scroll-lock] ".concat(e))},a=function(e){if(Array.isArray(e))return e.join(", ")},c=function(e){var t=[];return l(e,(function(e){return t.push(e)})),t},u=function(e,t){var r=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:document;if(r&&-1!==c(n.querySelectorAll(t)).indexOf(e))return e;for(;(e=e.parentElement)&&-1===c(n.querySelectorAll(t)).indexOf(e););return e},s=function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:document,n=-1!==c(r.querySelectorAll(t)).indexOf(e);return n},d=function(e){if(e)return"hidden"===getComputedStyle(e).overflow},f=function(e){if(e)return!!d(e)||e.scrollTop<=0},p=function(e){if(e){if(d(e))return!0;var t=e.scrollTop,r=e.scrollHeight;return t+e.offsetHeight>=r}},g=function(e){if(e)return!!d(e)||e.scrollLeft<=0},b=function(e){if(e){if(d(e))return!0;var t=e.scrollLeft,r=e.scrollWidth;return t+e.offsetWidth>=r}},v=function(e){return s(e,'textarea, [contenteditable="true"]')},m=function(e){return s(e,'input[type="range"]')};function h(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}r.d(t,"disablePageScroll",(function(){return w})),r.d(t,"enablePageScroll",(function(){return A})),r.d(t,"getScrollState",(function(){return k})),r.d(t,"clearQueueScrollLocks",(function(){return L})),r.d(t,"getTargetScrollBarWidth",(function(){return x})),r.d(t,"getCurrentTargetScrollBarWidth",(function(){return E})),r.d(t,"getPageScrollBarWidth",(function(){return T})),r.d(t,"getCurrentPageScrollBarWidth",(function(){return j})),r.d(t,"addScrollableTarget",(function(){return O})),r.d(t,"removeScrollableTarget",(function(){return G})),r.d(t,"addScrollableSelector",(function(){return W})),r.d(t,"removeScrollableSelector",(function(){return F})),r.d(t,"addLockableTarget",(function(){return P})),r.d(t,"addLockableSelector",(function(){return Y})),r.d(t,"setFillGapMethod",(function(){return q})),r.d(t,"addFillGapTarget",(function(){return M})),r.d(t,"removeFillGapTarget",(function(){return C})),r.d(t,"addFillGapSelector",(function(){return N})),r.d(t,"removeFillGapSelector",(function(){return U})),r.d(t,"refillGaps",(function(){return B}));var y=["padding","margin","width","max-width","none"],S={scroll:!0,queue:0,scrollableSelectors:["[data-scroll-lock-scrollable]"],lockableSelectors:["body","[data-scroll-lock-lockable]"],fillGapSelectors:["body","[data-scroll-lock-fill-gap]","[data-scroll-lock-lockable]"],fillGapMethod:y[0],startTouchY:0,startTouchX:0},w=function(e){S.queue<=0&&(S.scroll=!1,K(),$()),O(e),S.queue++},A=function(e){S.queue>0&&S.queue--,S.queue<=0&&(S.scroll=!0,R(),D()),G(e)},k=function(){return S.scroll},L=function(){S.queue=0},x=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(o(e)){var r=e.style.overflowY;t?k()||(e.style.overflowY=e.getAttribute("data-scroll-lock-saved-overflow-y-property")):e.style.overflowY="scroll";var n=E(e);return e.style.overflowY=r,n}return 0},E=function(e){if(o(e)){if(e===document.body){var t=document.documentElement.clientWidth;return window.innerWidth-t}var r=e.style.borderLeftWidth,n=e.style.borderRightWidth;e.style.borderLeftWidth="0px",e.style.borderRightWidth="0px";var l=e.offsetWidth-e.clientWidth;return e.style.borderLeftWidth=r,e.style.borderRightWidth=n,l}return 0},T=function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return x(document.body,e)},j=function(){return E(document.body)},O=function(e){e&&n(e).map((function(e){l(e,(function(e){o(e)?e.setAttribute("data-scroll-lock-scrollable",""):i('"'.concat(e,'" is not a Element.'))}))}))},G=function(e){e&&n(e).map((function(e){l(e,(function(e){o(e)?e.removeAttribute("data-scroll-lock-scrollable"):i('"'.concat(e,'" is not a Element.'))}))}))},W=function(e){e&&n(e).map((function(e){S.scrollableSelectors.push(e)}))},F=function(e){e&&n(e).map((function(e){S.scrollableSelectors=S.scrollableSelectors.filter((function(t){return t!==e}))}))},P=function(e){e&&(n(e).map((function(e){l(e,(function(e){o(e)?e.setAttribute("data-scroll-lock-lockable",""):i('"'.concat(e,'" is not a Element.'))}))})),k()||K())},Y=function(e){e&&(n(e).map((function(e){S.lockableSelectors.push(e)})),k()||K(),N(e))},q=function(e){if(e)if(-1!==y.indexOf(e))S.fillGapMethod=e,B();else{var t=y.join(", ");i('"'.concat(e,'" method is not available!\nAvailable fill gap methods: ').concat(t,"."))}},M=function(e){e&&n(e).map((function(e){l(e,(function(e){o(e)?(e.setAttribute("data-scroll-lock-fill-gap",""),S.scroll||z(e)):i('"'.concat(e,'" is not a Element.'))}))}))},C=function(e){e&&n(e).map((function(e){l(e,(function(e){o(e)?(e.removeAttribute("data-scroll-lock-fill-gap"),S.scroll||J(e)):i('"'.concat(e,'" is not a Element.'))}))}))},N=function(e){e&&n(e).map((function(e){-1===S.fillGapSelectors.indexOf(e)&&(S.fillGapSelectors.push(e),S.scroll||Q(e))}))},U=function(e){e&&n(e).map((function(e){S.fillGapSelectors=S.fillGapSelectors.filter((function(t){return t!==e})),S.scroll||V(e)}))},B=function(){S.scroll||$()},K=function(){var e=a(S.lockableSelectors);_(e)},R=function(){var e=a(S.lockableSelectors);I(e)},_=function(e){var t=document.querySelectorAll(e);l(t,(function(e){H(e)}))},I=function(e){var t=document.querySelectorAll(e);l(t,(function(e){X(e)}))},H=function(e){if(o(e)&&"true"!==e.getAttribute("data-scroll-lock-locked")){var t=window.getComputedStyle(e);e.setAttribute("data-scroll-lock-saved-overflow-y-property",t.overflowY),e.setAttribute("data-scroll-lock-saved-inline-overflow-property",e.style.overflow),e.setAttribute("data-scroll-lock-saved-inline-overflow-y-property",e.style.overflowY),e.style.overflow="hidden",e.setAttribute("data-scroll-lock-locked","true")}},X=function(e){o(e)&&"true"===e.getAttribute("data-scroll-lock-locked")&&(e.style.overflow=e.getAttribute("data-scroll-lock-saved-inline-overflow-property"),e.style.overflowY=e.getAttribute("data-scroll-lock-saved-inline-overflow-y-property"),e.removeAttribute("data-scroll-lock-saved-overflow-property"),e.removeAttribute("data-scroll-lock-saved-inline-overflow-property"),e.removeAttribute("data-scroll-lock-saved-inline-overflow-y-property"),e.removeAttribute("data-scroll-lock-locked"))},$=function(){S.fillGapSelectors.map((function(e){Q(e)}))},D=function(){S.fillGapSelectors.map((function(e){V(e)}))},Q=function(e){var t=document.querySelectorAll(e),r=-1!==S.lockableSelectors.indexOf(e);l(t,(function(e){z(e,r)}))},z=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(o(e)){var r;if(""===e.getAttribute("data-scroll-lock-lockable")||t)r=x(e,!0);else{var n=u(e,a(S.lockableSelectors));r=x(n,!0)}"true"===e.getAttribute("data-scroll-lock-filled-gap")&&J(e);var l=window.getComputedStyle(e);if(e.setAttribute("data-scroll-lock-filled-gap","true"),e.setAttribute("data-scroll-lock-current-fill-gap-method",S.fillGapMethod),"margin"===S.fillGapMethod){var i=parseFloat(l.marginRight);e.style.marginRight="".concat(i+r,"px")}else if("width"===S.fillGapMethod)e.style.width="calc(100% - ".concat(r,"px)");else if("max-width"===S.fillGapMethod)e.style.maxWidth="calc(100% - ".concat(r,"px)");else if("padding"===S.fillGapMethod){var c=parseFloat(l.paddingRight);e.style.paddingRight="".concat(c+r,"px")}}},V=function(e){var t=document.querySelectorAll(e);l(t,(function(e){J(e)}))},J=function(e){if(o(e)&&"true"===e.getAttribute("data-scroll-lock-filled-gap")){var t=e.getAttribute("data-scroll-lock-current-fill-gap-method");e.removeAttribute("data-scroll-lock-filled-gap"),e.removeAttribute("data-scroll-lock-current-fill-gap-method"),"margin"===t?e.style.marginRight="":"width"===t?e.style.width="":"max-width"===t?e.style.maxWidth="":"padding"===t&&(e.style.paddingRight="")}};"undefined"!=typeof window&&window.addEventListener("resize",(function(e){B()})),"undefined"!=typeof document&&(document.addEventListener("touchstart",(function(e){S.scroll||(S.startTouchY=e.touches[0].clientY,S.startTouchX=e.touches[0].clientX)})),document.addEventListener("touchmove",(function(e){if(!S.scroll){var t=S.startTouchY,r=S.startTouchX,n=e.touches[0].clientY,o=e.touches[0].clientX;if(e.touches.length<2){var l=a(S.scrollableSelectors),i={up:t<n,down:t>n,left:r<o,right:r>o},c={up:t+3<n,down:t-3>n,left:r+3<o,right:r-3>o};!function t(r){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(r){var o=u(r,l,!1);if(m(r))return!1;if(n||v(r)&&u(r,l)||s(r,l)){var a=!1;g(r)&&b(r)?(i.up&&f(r)||i.down&&p(r))&&(a=!0):f(r)&&p(r)?(i.left&&g(r)||i.right&&b(r))&&(a=!0):(c.up&&f(r)||c.down&&p(r)||c.left&&g(r)||c.right&&b(r))&&(a=!0),a&&(o?t(o,!0):e.cancelable&&e.preventDefault())}else t(o)}else e.cancelable&&e.preventDefault()}(e.target)}}}),{passive:!1}),document.addEventListener("touchend",(function(e){S.scroll||(S.startTouchY=0,S.startTouchX=0)})));var Z={hide:function(e){i('"hide" is deprecated! Use "disablePageScroll" instead. \n https://github.com/FL3NKEY/scroll-lock#disablepagescrollscrollabletarget'),w(e)},show:function(e){i('"show" is deprecated! Use "enablePageScroll" instead. \n https://github.com/FL3NKEY/scroll-lock#enablepagescrollscrollabletarget'),A(e)},toggle:function(e){i('"toggle" is deprecated! Do not use it.'),k()?w():A(e)},getState:function(){return i('"getState" is deprecated! Use "getScrollState" instead. \n https://github.com/FL3NKEY/scroll-lock#getscrollstate'),k()},getWidth:function(){return i('"getWidth" is deprecated! Use "getPageScrollBarWidth" instead. \n https://github.com/FL3NKEY/scroll-lock#getpagescrollbarwidth'),T()},getCurrentWidth:function(){return i('"getCurrentWidth" is deprecated! Use "getCurrentPageScrollBarWidth" instead. \n https://github.com/FL3NKEY/scroll-lock#getcurrentpagescrollbarwidth'),j()},setScrollableTargets:function(e){i('"setScrollableTargets" is deprecated! Use "addScrollableTarget" instead. \n https://github.com/FL3NKEY/scroll-lock#addscrollabletargetscrollabletarget'),O(e)},setFillGapSelectors:function(e){i('"setFillGapSelectors" is deprecated! Use "addFillGapSelector" instead. \n https://github.com/FL3NKEY/scroll-lock#addfillgapselectorfillgapselector'),N(e)},setFillGapTargets:function(e){i('"setFillGapTargets" is deprecated! Use "addFillGapTarget" instead. \n https://github.com/FL3NKEY/scroll-lock#addfillgaptargetfillgaptarget'),M(e)},clearQueue:function(){i('"clearQueue" is deprecated! Use "clearQueueScrollLocks" instead. \n https://github.com/FL3NKEY/scroll-lock#clearqueuescrolllocks'),L()}},ee=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter((function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable})))),n.forEach((function(t){h(e,t,r[t])}))}return e}({disablePageScroll:w,enablePageScroll:A,getScrollState:k,clearQueueScrollLocks:L,getTargetScrollBarWidth:x,getCurrentTargetScrollBarWidth:E,getPageScrollBarWidth:T,getCurrentPageScrollBarWidth:j,addScrollableSelector:W,removeScrollableSelector:F,addScrollableTarget:O,removeScrollableTarget:G,addLockableSelector:Y,addLockableTarget:P,addFillGapSelector:N,removeFillGapSelector:U,addFillGapTarget:M,removeFillGapTarget:C,setFillGapMethod:q,refillGaps:B,_state:S},Z);t.default=ee}]).default},e.exports=t()}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var l=t[n]={exports:{}};return e[n].call(l.exports,l,l.exports,r),l.exports}r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var n={};return(()=>{"use strict";r.d(n,{default:()=>g});var e=r(3096),t=r.n(e),o=r(9581),l=r(2498),i=r(1792),a=r(9552),c=r(7359);function u(e){return function(e){if(Array.isArray(e))return s(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return s(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?s(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var d=function(e){return window.onblur=function(){return e()},{teardown:function(){return window.onblur=null}}},f=function(e){var t=(0,o.A)("meganav"),r=function(r){t.contains(r.target)||e()};return document.addEventListener("click",r),{teardown:function(){return document.removeEventListener("click",r)}}},p=function(e){if("transparentToWhite"!==e)return{teardown:function(){}};var r=(0,o.A)("meganav"),n=(0,o.n)("meganav-link"),l=(0,o.A)("meganav-control-mobile-dropdown-menu"),i=(0,o.A)("meganav-control-mobile-dropdown-close"),a=(0,o.n)("meganav-control"),c=(0,o.A)("meganav-sign-up-btn"),s=[].concat(u(Array.from(a)),u(Array.from(n)),[(0,o.A)("meganav-logo")]),d=function(e){var t,r,n,o,a=["ui-icon-white","ui-icon-cool-black"],c=[].concat(a).reverse();e?(null==l||(t=l.classList).replace.apply(t,a),null==i||(r=i.classList).replace.apply(r,a)):(null==l||(n=l.classList).replace.apply(n,u(c)),null==i||(o=i.classList).replace.apply(o,u(c)))},f=function(e){e?(null==c||c.classList.replace("bg-white","bg-cool-black"),null==c||c.classList.replace("text-cool-black","text-white")):(null==c||c.classList.replace("bg-cool-black","bg-white"),null==c||c.classList.replace("text-white","text-cool-black"))},p=t()((function(){window.scrollY>5?(r.classList.replace("bg-transparent","bg-white"),f(!0),d(!0),s.forEach((function(e){return e.classList.replace("text-white","text-cool-black")}))):(r.classList.replace("bg-white","bg-transparent"),f(!1),d(!1),s.forEach((function(e){return e.classList.replace("text-cool-black","text-white")})))}),150);return document.addEventListener("scroll",p),{teardown:function(){return document.removeEventListener("scroll",p)}}};function g(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{themeName:null},t=e.themeName,r=(0,l.default)(),n=(0,a.default)(),o=(0,c.default)(),s=(0,i.default)({clearPanels:function(){return[].concat(u(n),u(o)).forEach((function(e){return e.clear()}))}}),g=function(){return[s].concat(u(n),u(o),u(r)).forEach((function(e){return e.clear()}))},b=[p(t),f(g),d(g),s].concat(u(r),u(n),u(o)).map((function(e){return e.teardown}));return function(){return b.forEach((function(e){return e()}))}}})(),n.default})()}));
1
+ /*! For license information please see component.js.LICENSE.txt */
2
+ !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.AblyUi=e():(t.AblyUi=t.AblyUi||{},t.AblyUi.Core=t.AblyUi.Core||{},t.AblyUi.Core.Meganav=e())}(this,(function(){return(()=>{var t={727:(t,e,n)=>{"use strict";t.exports=n(5647)},493:(t,e,n)=>{"use strict";n(2702).polyfill();const r=n(9669).default;var i=function(t,e,n,o,s,a,c){var u=function(t,e){return t||!1===t?"&"+e+"="+t:""};if("search"===n||"suggest"===n||"autocomplete"===n){var l="",f="",d=null;if("search"===n){d=n,l=o.keyword,l=o.enableLogicalOperators?l.replace(/ and /g," AND ").replace(/ or /g," OR ").replace(/ not /g," NOT "):l.replace(/ AND /g," and ").replace(/ OR /g," or ").replace(/ NOT /g," not "),l=encodeURIComponent(l);var h=o.fuzzy;if("retry"===h&&(h=!0===a),"search"===n){if(f=u(o.lang,"lang")+u(h,"fuzzy")+u(o.collectAnalytics,"collectAnalytics")+u(o.postfixWildcard,"postfixWildcard")+u(o.categories,"categories")+u(o.priceFromCents,"priceFromCents")+u(o.priceToCents,"priceToCents")+u(o.dateFrom,"dateFrom")+u(o.dateTo,"dateTo")+u(o.paging.page,"page")+u(o.paging.pageSize,"limit")+u(o.paging.sortBy,"sort")+u(o.paging.sortOrder,"order")+u(o.shuffleAndLimitTo,"shuffleAndLimitTo")+u(o.jwt,"jwt")+u(o.resultType,"resultType")+u(o.userToken,"userToken")+u(o.numFacets,"numFacets")+u(o.cacheResponseTime,"cacheResponseWithTtlSeconds")+u(o.searchOperator,"defaultOperator")+u(o.analyticsTag,"analyticsTag")+u(o.hierarchicalFacetSetting,"hierarchicalFacets"),o.customFieldFilters)for(var p=0;p<o.customFieldFilters.length;p++)f=f+"&customField="+o.customFieldFilters[p];if(o.facetFields)for(p=0;p<o.facetFields.length;p++)f=f+"&facet="+o.facetFields[p];if(o.rangeFacets&&(f=f+"&rangeFacets="+JSON.stringify(o.rangeFacets)),o.statsFields)for(p=0;p<o.statsFields.length;p++)f=f+"&fieldStat="+o.statsFields[p];if(o.personalizationEvents&&Array.isArray(o.personalizationEvents))for(p=0;p<o.personalizationEvents.length;p++){var g=o.personalizationEvents[p],m=Object.keys(g);f=f+"&personalizationEvent="+encodeURIComponent(m+"="+g[m])}c?f=f+"&filter="+encodeURIComponent(JSON.stringify(c)):o.filterObject&&(f=f+"&filter="+encodeURIComponent(JSON.stringify(o.filterObject)))}}else"suggest"===n?(d=n,f=u(o.suggestionsSize,"size")+u(o.lang,"lang"),l=o.suggestionsPrefix):"autocomplete"===n&&(d="autocomplete/document-field",f=u(o.autocomplete.field,"source")+u(o.autocomplete.size,"size"),l=o.autocomplete.prefix);r.get("https://"+t+"/v1/"+d+"/"+e+"?term="+l+f).then((function(r){var c=r.data;if("search"===n&&"retry"===o.fuzzy&&0===c.total_hits&&!0!==a)i(t,e,n,o,s,!0);else{if(!0===a){var u=o.paging.pageSize;c.total_hits>=u&&(c.total_hits=u)}s(c)}})).catch((function(t){console.log(t),s({error:{response:500,message:"invalid server response"}})}))}else s({error:{response:400,message:"invalid query type"}})};t.exports=i},5647:(t,e,n)=>{"use strict";var r=n(493),i=n(9610),o=n(3716),s=n(7585),a=n(5159),c=n(4508);t.exports=function(t,e){this.sitekey=t,this.privatekey=e,this.apiHostname="api.addsearch.com",this.settings=new s,this.sessionId=("a-"+1e8*Math.random()).substring(0,10),this.search=function(t,e){var n=null,i=null;if(t&&a.isFunction(e))n=t,i=e;else if(!e&&a.isFunction(t))n=this.settings.getSettings().keyword,i=t;else{if(!this.settings.getSettings().callback)throw"Illegal search parameters. Should be (keyword, callbackFunction) or (callbackFunction)";n=this.settings.getSettings().keyword,i=this.settings.getSettings().callback}this.settings.setCallback(i),this.settings.setKeyword(n),this.throttledSearchFetch||(this.throttledSearchFetch=c(this.settings.getSettings().throttleTimeMs,r)),this.throttledSearchFetch(this.apiHostname,this.sitekey,"search",this.settings.getSettings(),i)},this.suggestions=function(t,e){if(!t||!e||!a.isFunction(e))throw"Illegal suggestions parameters. Should be (prefix, callbackFunction)";this.settings.setSuggestionsPrefix(t),this.throttledSuggestionsFetch||(this.throttledSuggestionsFetch=c(this.settings.getSettings().throttleTimeMs,r)),this.throttledSuggestionsFetch(this.apiHostname,this.sitekey,"suggest",this.settings.getSettings(),e)},this.autocomplete=function(t,e,n){if(!(t&&e&&n&&a.isFunction(n)))throw"Illegal autocomplete parameters. Should be (field, prefix, callbackFunction)";this.settings.setAutocompleteParams(t,e),this.throttledAutocompleteFetch||(this.throttledAutocompleteFetch=c(this.settings.getSettings().throttleTimeMs,r)),this.throttledAutocompleteFetch(this.apiHostname,this.sitekey,"autocomplete",this.settings.getSettings(),n)},this.fetchCustomApi=function(t,e,n){var i=Object.assign({},this.settings.getSettings());i.facetFields=i.facetFields.filter((e=>t===e)),r(this.apiHostname,this.sitekey,"search",i,n,null,e)},this.fetchRangeFacets=function(t,e,n){var i=Object.assign({},this.settings.getSettings());i.rangeFacets||(i.rangeFacets=[]),i.rangeFacets.push({field:t.field,ranges:t.ranges}),r(this.apiHostname,this.sitekey,"search",i,n,null,e)},this.getDocument=function(t){return i.getDocument(this.apiHostname,this.sitekey,this.privatekey,t)},this.saveDocument=function(t){return i.saveDocument(this.apiHostname,this.sitekey,this.privatekey,t)},this.saveDocumentsBatch=function(t){if(!t||!t.documents||!Array.isArray(t.documents))throw"Please provide an array of documents: {documents: []}";return i.saveDocumentsBatch(this.apiHostname,this.sitekey,this.privatekey,t)},this.deleteDocument=function(t){return i.deleteDocument(this.apiHostname,this.sitekey,this.privatekey,t)},this.deleteDocumentsBatch=function(t){if(!t||!t.documents||!Array.isArray(t.documents))throw"Please provide an array of document ids: {documents: []}";return i.deleteDocumentsBatch(this.apiHostname,this.sitekey,this.privatekey,t)},this.setApiHostname=function(t){this.apiHostname=t},this.getSettings=function(){return this.settings.getSettings()},this.setLanguage=function(t){this.settings.setLanguage(t)},this.setCategoryFilters=function(t){this.settings.setCategoryFilters(t)},this.addCustomFieldFilter=function(t,e){this.settings.addCustomFieldFilter(t,e)},this.removeCustomFieldFilter=function(t,e){this.settings.removeCustomFieldFilter(t,e)},this.setPriceRangeFilter=function(t,e){this.settings.setPriceRangeFilter(t,e)},this.setDateFilter=function(t,e){this.settings.setDateFilter(t,e)},this.setJWT=function(t){this.settings.setJWT(t)},this.setUserToken=function(t){this.settings.setUserToken(t)},this.setPaging=function(t,e,n,r){this.settings.setPaging(t,e,n,r)},this.nextPage=function(){this.settings.nextPage()},this.previousPage=function(){this.settings.previousPage()},this.setSuggestionsSize=function(t){this.settings.setSuggestionsSize(t)},this.setAutocompleteSize=function(t){this.settings.setAutocompleteSize(t)},this.addFacetField=function(t){this.settings.addFacetField(t)},this.addHierarchicalFacetSetting=function(t){this.settings.addHierarchicalFacetSetting(t)},this.addRangeFacet=function(t,e){this.settings.addRangeFacet(t,e)},this.addStatsField=function(t){this.settings.addStatsField(t)},this.setNumberOfFacets=function(t){this.settings.setNumberOfFacets(t)},this.setResultType=function(t){this.settings.setResultType(t)},this.setPersonalizationEvents=function(t){this.settings.setPersonalizationEvents(t)},this.setFilterObject=function(t){this.settings.setFilterObject(t)},this.setShuffleAndLimitTo=function(t){this.settings.setShuffleAndLimitTo(t)},this.setFuzzyMatch=function(t){this.settings.setFuzzyMatch(t)},this.setPostfixWildcard=function(t){this.settings.setPostfixWildcard(t)},this.setCacheResponseTime=function(t){this.settings.setCacheResponseTime(t)},this.setCollectAnalytics=function(t){this.settings.setCollectAnalytics(t)},this.setAnalyticsTag=function(t){this.settings.setAnalyticsTag(t)},this.setThrottleTime=function(t){this.settings.setThrottleTime(t)},this.setStatsSessionId=function(t){this.sessionId=t},this.getStatsSessionId=function(){return this.sessionId},this.enableLogicalOperators=function(t){this.settings.enableLogicalOperators(t)},this.setSearchOperator=function(t){this.settings.setSearchOperator(t)},this.sendStatsEvent=function(t,e,n){if("search"===t){var r={action:"search",session:this.sessionId,keyword:e,numberOfResults:n.numberOfResults,analyticsTag:this.getSettings().analyticsTag};o(this.apiHostname,this.sitekey,r)}else{if("click"!==t)throw"Illegal sendStatsEvent type parameters. Should be search or click)";r={action:"click",session:this.sessionId,keyword:e,docid:n.documentId,position:n.position,analyticsTag:this.getSettings().analyticsTag},o(this.apiHostname,this.sitekey,r)}},this.searchResultClicked=function(t,e){this.sendStatsEvent("click",this.settings.getSettings().keyword,{documentId:t,position:e})}}},9610:(t,e,n)=>{"use strict";const r=n(5159),i=n(2702).Promise,o=n(9669).default,s=function(t,e){return{Authorization:"Basic "+r.base64(t+":"+e),"Content-Type":"application/json"}};t.exports={getDocument:function(t,e,n,r){return new i(((i,a)=>{o.get("https://"+t+"/v2/indices/"+e+"/documents/"+r,{headers:s(e,n)}).then((t=>{200==t.status?i(t.data):a({status:t.status,text:t.statusText})})).catch((t=>{a({status:400,text:t})}))}))},saveDocument:function(t,e,n,r){const a=r.id||r.url;return new i(((i,c)=>{o({url:"https://"+t+"/v2/indices/"+e+"/documents/",method:a?"put":"post",headers:s(e,n),data:r}).then((t=>{202==t.status?i({status:t.status,text:t.statusText}):c({status:t.status,text:t.statusText})})).catch((t=>{c({status:400,text:t})}))}))},saveDocumentsBatch:function(t,e,n,r){return new i(((i,a)=>{o({method:"put",url:"https://"+t+"/v2/indices/"+e+"/documents:batch",headers:s(e,n),data:r}).then((t=>{202==t.status?i({status:t.status,text:t.statusText}):a({status:t.status,text:t.statusText})})).catch((t=>{a({status:400,text:t})}))}))},deleteDocument:function(t,e,n,r){return new i(((i,a)=>{o.delete("https://"+t+"/v2/indices/"+e+"/documents/"+r,{headers:s(e,n)}).then((t=>{202==t.status?i({status:t.status,text:t.statusText}):a({status:t.status,text:t.statusText})})).catch((t=>{a({status:400,text:t})}))}))},deleteDocumentsBatch:function(t,e,n,r){return new i(((i,a)=>{o.delete("https://"+t+"/v2/indices/"+e+"/documents:batch",{headers:s(e,n),data:r}).then((t=>{202==t.status?i({status:t.status,text:t.statusText}):a({status:t.status,text:t.statusText})})).catch((t=>{a({status:400,text:t})}))}))}}},7585:t=>{"use strict";t.exports=function(){this.settings={keyword:"*",callback:null,throttleTimeMs:200,fuzzy:"auto",paging:{page:1,pageSize:10,sortBy:"relevance",sortOrder:"desc"},customFieldFilters:[],userToken:null,suggestionsSize:10,facetFields:[],autocomplete:{size:10},searchOperator:null,enableLogicalOperators:!1,cacheResponseTime:null},this.getSettings=function(){return this.settings},this.setKeyword=function(t){this.settings.keyword=t||"*"},this.setCallback=function(t){this.settings.callback=t},this.setThrottleTime=function(t){this.settings.throttleTimeMs=t},this.setSuggestionsPrefix=function(t){this.settings.suggestionsPrefix=t},this.setSuggestionsSize=function(t){this.settings.suggestionsSize=t},this.setAutocompleteSize=function(t){this.settings.autocomplete.size=t},this.setAutocompleteParams=function(t,e){this.settings.autocomplete.field=t,this.settings.autocomplete.prefix=e},this.setLanguage=function(t){if(t&&2!==t.length)throw'use 2-char language code (e.g. "en")';this.settings.lang=t},this.setFuzzyMatch=function(t){if(!0!==t&&!1!==t&&"auto"!==t&&"retry"!==t)throw"fuzzy matching can be true, false, 'auto', or 'retry'";this.settings.fuzzy=t},this.enableLogicalOperators=function(t){this.settings.enableLogicalOperators=t},this.setCacheResponseTime=function(t){this.settings.cacheResponseTime=t},this.setPostfixWildcard=function(t){this.settings.postfixWildcard=t},this.setCollectAnalytics=function(t){this.settings.collectAnalytics=t},this.setAnalyticsTag=function(t){this.settings.analyticsTag=t},this.setCategoryFilters=function(t){this.settings.categories=t},this.setFilterObject=function(t){this.settings.filterObject=t},this.setPriceRangeFilter=function(t,e){this.settings.priceFromCents=t,this.settings.priceToCents=e},this.addCustomFieldFilter=function(t,e){var n=encodeURIComponent(t+"="+e);-1===this.settings.customFieldFilters.indexOf(n)&&this.settings.customFieldFilters.push(n)},this.removeCustomFieldFilter=function(t,e){var n=!1,r=encodeURIComponent(t+"="+e);e||(n=!0,r=encodeURIComponent(t+"="));for(var i=this.settings.customFieldFilters.length;i>0;i--){var o=this.settings.customFieldFilters[i-1];(n&&0===o.indexOf(r)||o===r)&&this.settings.customFieldFilters.splice(i-1,1)}},this.setDateFilter=function(t,e){this.settings.dateFrom=t,this.settings.dateTo=e},this.setKeyword=function(t){this.settings.keyword=t||"*"},this.setJWT=function(t){this.settings.jwt=t},this.setUserToken=function(t){this.settings.userToken=t},this.setPersonalizationEvents=function(t){this.settings.personalizationEvents=t},this.setResultType=function(t){this.settings.resultType=t},this.addFacetField=function(t){-1===this.settings.facetFields.indexOf(t)&&this.settings.facetFields.push(t)},this.addHierarchicalFacetSetting=function(t){this.settings.hierarchicalFacetSetting=JSON.stringify(t)},this.addRangeFacet=function(t,e){this.settings.rangeFacets||(this.settings.rangeFacets=[]),this.settings.rangeFacets.push({field:t,ranges:e})},this.addStatsField=function(t){this.settings.statsFields||(this.settings.statsFields=[]),-1===this.settings.statsFields.indexOf(t)&&this.settings.statsFields.push(t)},this.setNumberOfFacets=function(t){this.settings.numFacets=t},this.setPaging=function(t,e,n,r){if(t<1)throw"page must be 1 or bigger";if(e<1||e>300)throw"pageSize must be 1-300";if("asc"!==r&&"desc"!==r)throw"sortOrder must be asc or desc";this.settings.paging.page=t,this.settings.paging.pageSize=e,this.settings.paging.sortBy=n,this.settings.paging.sortOrder=r},this.setShuffleAndLimitTo=function(t){this.settings.shuffleAndLimitTo=t},this.nextPage=function(){this.settings.paging.page=this.settings.paging.page+1},this.previousPage=function(){this.settings.paging.page>0&&(this.settings.paging.page=this.settings.paging.page-1)},this.setSearchOperator=function(t){if("and"!==t&&"or"!==t)throw"operator must be 'and' || 'or'";this.settings.searchOperator=t}}},3716:(t,e,n)=>{"use strict";n(2702).polyfill();const r=n(9669).default;t.exports=function(t,e,n){"undefined"!=typeof window&&window.navigator&&window.navigator.sendBeacon?navigator.sendBeacon("https://"+t+"/v1/stats/"+e+"/",JSON.stringify(n)):r.post("https://"+t+"/v1/stats/"+e+"/",n,{headers:{"Content-Type":"text/plain"}})}},4508:t=>{t.exports=function(t,e){var n,r=0;function i(){n&&clearTimeout(n)}return function(){var o=this,s=Date.now()-r,a=arguments;function c(){r=Date.now(),e.apply(o,a)}i(),s>t?c():n=setTimeout(c,t-s)}}},5159:(t,e,n)=>{t.exports={isFunction:function(t){return t&&"[object Function]"==={}.toString.call(t)},base64:function(t){return n.g.window={},window&&window.btoa?window.btoa(t):Buffer?Buffer.from(t).toString("base64"):void 0}}},9669:(t,e,n)=>{t.exports=n(1609)},5448:(t,e,n)=>{"use strict";var r=n(4867),i=n(6026),o=n(4372),s=n(5327),a=n(4097),c=n(4109),u=n(7985),l=n(7874),f=n(2648),d=n(644),h=n(205);t.exports=function(t){return new Promise((function(e,n){var p,g=t.data,m=t.headers,v=t.responseType;function y(){t.cancelToken&&t.cancelToken.unsubscribe(p),t.signal&&t.signal.removeEventListener("abort",p)}r.isFormData(g)&&r.isStandardBrowserEnv()&&delete m["Content-Type"];var b=new XMLHttpRequest;if(t.auth){var w=t.auth.username||"",S=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";m.Authorization="Basic "+btoa(w+":"+S)}var A=a(t.baseURL,t.url);function x(){if(b){var r="getAllResponseHeaders"in b?c(b.getAllResponseHeaders()):null,o={data:v&&"text"!==v&&"json"!==v?b.response:b.responseText,status:b.status,statusText:b.statusText,headers:r,config:t,request:b};i((function(t){e(t),y()}),(function(t){n(t),y()}),o),b=null}}if(b.open(t.method.toUpperCase(),s(A,t.params,t.paramsSerializer),!0),b.timeout=t.timeout,"onloadend"in b?b.onloadend=x:b.onreadystatechange=function(){b&&4===b.readyState&&(0!==b.status||b.responseURL&&0===b.responseURL.indexOf("file:"))&&setTimeout(x)},b.onabort=function(){b&&(n(new f("Request aborted",f.ECONNABORTED,t,b)),b=null)},b.onerror=function(){n(new f("Network Error",f.ERR_NETWORK,t,b,b)),b=null},b.ontimeout=function(){var e=t.timeout?"timeout of "+t.timeout+"ms exceeded":"timeout exceeded",r=t.transitional||l;t.timeoutErrorMessage&&(e=t.timeoutErrorMessage),n(new f(e,r.clarifyTimeoutError?f.ETIMEDOUT:f.ECONNABORTED,t,b)),b=null},r.isStandardBrowserEnv()){var E=(t.withCredentials||u(A))&&t.xsrfCookieName?o.read(t.xsrfCookieName):void 0;E&&(m[t.xsrfHeaderName]=E)}"setRequestHeader"in b&&r.forEach(m,(function(t,e){void 0===g&&"content-type"===e.toLowerCase()?delete m[e]:b.setRequestHeader(e,t)})),r.isUndefined(t.withCredentials)||(b.withCredentials=!!t.withCredentials),v&&"json"!==v&&(b.responseType=t.responseType),"function"==typeof t.onDownloadProgress&&b.addEventListener("progress",t.onDownloadProgress),"function"==typeof t.onUploadProgress&&b.upload&&b.upload.addEventListener("progress",t.onUploadProgress),(t.cancelToken||t.signal)&&(p=function(t){b&&(n(!t||t&&t.type?new d:t),b.abort(),b=null)},t.cancelToken&&t.cancelToken.subscribe(p),t.signal&&(t.signal.aborted?p():t.signal.addEventListener("abort",p))),g||(g=null);var T=h(A);T&&-1===["http","https","file"].indexOf(T)?n(new f("Unsupported protocol "+T+":",f.ERR_BAD_REQUEST,t)):b.send(g)}))}},1609:(t,e,n)=>{"use strict";var r=n(4867),i=n(1849),o=n(321),s=n(7185),a=function t(e){var n=new o(e),a=i(o.prototype.request,n);return r.extend(a,o.prototype,n),r.extend(a,n),a.create=function(n){return t(s(e,n))},a}(n(5546));a.Axios=o,a.CanceledError=n(644),a.CancelToken=n(4972),a.isCancel=n(6502),a.VERSION=n(7288).version,a.toFormData=n(7675),a.AxiosError=n(2648),a.Cancel=a.CanceledError,a.all=function(t){return Promise.all(t)},a.spread=n(8713),a.isAxiosError=n(6268),t.exports=a,t.exports.default=a},4972:(t,e,n)=>{"use strict";var r=n(644);function i(t){if("function"!=typeof t)throw new TypeError("executor must be a function.");var e;this.promise=new Promise((function(t){e=t}));var n=this;this.promise.then((function(t){if(n._listeners){var e,r=n._listeners.length;for(e=0;e<r;e++)n._listeners[e](t);n._listeners=null}})),this.promise.then=function(t){var e,r=new Promise((function(t){n.subscribe(t),e=t})).then(t);return r.cancel=function(){n.unsubscribe(e)},r},t((function(t){n.reason||(n.reason=new r(t),e(n.reason))}))}i.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},i.prototype.subscribe=function(t){this.reason?t(this.reason):this._listeners?this._listeners.push(t):this._listeners=[t]},i.prototype.unsubscribe=function(t){if(this._listeners){var e=this._listeners.indexOf(t);-1!==e&&this._listeners.splice(e,1)}},i.source=function(){var t;return{token:new i((function(e){t=e})),cancel:t}},t.exports=i},644:(t,e,n)=>{"use strict";var r=n(2648);function i(t){r.call(this,null==t?"canceled":t,r.ERR_CANCELED),this.name="CanceledError"}n(4867).inherits(i,r,{__CANCEL__:!0}),t.exports=i},6502:t=>{"use strict";t.exports=function(t){return!(!t||!t.__CANCEL__)}},321:(t,e,n)=>{"use strict";var r=n(4867),i=n(5327),o=n(782),s=n(3572),a=n(7185),c=n(4097),u=n(4875),l=u.validators;function f(t){this.defaults=t,this.interceptors={request:new o,response:new o}}f.prototype.request=function(t,e){"string"==typeof t?(e=e||{}).url=t:e=t||{},(e=a(this.defaults,e)).method?e.method=e.method.toLowerCase():this.defaults.method?e.method=this.defaults.method.toLowerCase():e.method="get";var n=e.transitional;void 0!==n&&u.assertOptions(n,{silentJSONParsing:l.transitional(l.boolean),forcedJSONParsing:l.transitional(l.boolean),clarifyTimeoutError:l.transitional(l.boolean)},!1);var r=[],i=!0;this.interceptors.request.forEach((function(t){"function"==typeof t.runWhen&&!1===t.runWhen(e)||(i=i&&t.synchronous,r.unshift(t.fulfilled,t.rejected))}));var o,c=[];if(this.interceptors.response.forEach((function(t){c.push(t.fulfilled,t.rejected)})),!i){var f=[s,void 0];for(Array.prototype.unshift.apply(f,r),f=f.concat(c),o=Promise.resolve(e);f.length;)o=o.then(f.shift(),f.shift());return o}for(var d=e;r.length;){var h=r.shift(),p=r.shift();try{d=h(d)}catch(t){p(t);break}}try{o=s(d)}catch(t){return Promise.reject(t)}for(;c.length;)o=o.then(c.shift(),c.shift());return o},f.prototype.getUri=function(t){t=a(this.defaults,t);var e=c(t.baseURL,t.url);return i(e,t.params,t.paramsSerializer)},r.forEach(["delete","get","head","options"],(function(t){f.prototype[t]=function(e,n){return this.request(a(n||{},{method:t,url:e,data:(n||{}).data}))}})),r.forEach(["post","put","patch"],(function(t){function e(e){return function(n,r,i){return this.request(a(i||{},{method:t,headers:e?{"Content-Type":"multipart/form-data"}:{},url:n,data:r}))}}f.prototype[t]=e(),f.prototype[t+"Form"]=e(!0)})),t.exports=f},2648:(t,e,n)=>{"use strict";var r=n(4867);function i(t,e,n,r,i){Error.call(this),this.message=t,this.name="AxiosError",e&&(this.code=e),n&&(this.config=n),r&&(this.request=r),i&&(this.response=i)}r.inherits(i,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code,status:this.response&&this.response.status?this.response.status:null}}});var o=i.prototype,s={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED"].forEach((function(t){s[t]={value:t}})),Object.defineProperties(i,s),Object.defineProperty(o,"isAxiosError",{value:!0}),i.from=function(t,e,n,s,a,c){var u=Object.create(o);return r.toFlatObject(t,u,(function(t){return t!==Error.prototype})),i.call(u,t.message,e,n,s,a),u.name=t.name,c&&Object.assign(u,c),u},t.exports=i},782:(t,e,n)=>{"use strict";var r=n(4867);function i(){this.handlers=[]}i.prototype.use=function(t,e,n){return this.handlers.push({fulfilled:t,rejected:e,synchronous:!!n&&n.synchronous,runWhen:n?n.runWhen:null}),this.handlers.length-1},i.prototype.eject=function(t){this.handlers[t]&&(this.handlers[t]=null)},i.prototype.forEach=function(t){r.forEach(this.handlers,(function(e){null!==e&&t(e)}))},t.exports=i},4097:(t,e,n)=>{"use strict";var r=n(1793),i=n(7303);t.exports=function(t,e){return t&&!r(e)?i(t,e):e}},3572:(t,e,n)=>{"use strict";var r=n(4867),i=n(8527),o=n(6502),s=n(5546),a=n(644);function c(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new a}t.exports=function(t){return c(t),t.headers=t.headers||{},t.data=i.call(t,t.data,t.headers,t.transformRequest),t.headers=r.merge(t.headers.common||{},t.headers[t.method]||{},t.headers),r.forEach(["delete","get","head","post","put","patch","common"],(function(e){delete t.headers[e]})),(t.adapter||s.adapter)(t).then((function(e){return c(t),e.data=i.call(t,e.data,e.headers,t.transformResponse),e}),(function(e){return o(e)||(c(t),e&&e.response&&(e.response.data=i.call(t,e.response.data,e.response.headers,t.transformResponse))),Promise.reject(e)}))}},7185:(t,e,n)=>{"use strict";var r=n(4867);t.exports=function(t,e){e=e||{};var n={};function i(t,e){return r.isPlainObject(t)&&r.isPlainObject(e)?r.merge(t,e):r.isPlainObject(e)?r.merge({},e):r.isArray(e)?e.slice():e}function o(n){return r.isUndefined(e[n])?r.isUndefined(t[n])?void 0:i(void 0,t[n]):i(t[n],e[n])}function s(t){if(!r.isUndefined(e[t]))return i(void 0,e[t])}function a(n){return r.isUndefined(e[n])?r.isUndefined(t[n])?void 0:i(void 0,t[n]):i(void 0,e[n])}function c(n){return n in e?i(t[n],e[n]):n in t?i(void 0,t[n]):void 0}var u={url:s,method:s,data:s,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:c};return r.forEach(Object.keys(t).concat(Object.keys(e)),(function(t){var e=u[t]||o,i=e(t);r.isUndefined(i)&&e!==c||(n[t]=i)})),n}},6026:(t,e,n)=>{"use strict";var r=n(2648);t.exports=function(t,e,n){var i=n.config.validateStatus;n.status&&i&&!i(n.status)?e(new r("Request failed with status code "+n.status,[r.ERR_BAD_REQUEST,r.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n)):t(n)}},8527:(t,e,n)=>{"use strict";var r=n(4867),i=n(5546);t.exports=function(t,e,n){var o=this||i;return r.forEach(n,(function(n){t=n.call(o,t,e)})),t}},5546:(t,e,n)=>{"use strict";var r=n(4867),i=n(6016),o=n(2648),s=n(7874),a=n(7675),c={"Content-Type":"application/x-www-form-urlencoded"};function u(t,e){!r.isUndefined(t)&&r.isUndefined(t["Content-Type"])&&(t["Content-Type"]=e)}var l,f={transitional:s,adapter:(("undefined"!=typeof XMLHttpRequest||"undefined"!=typeof process&&"[object process]"===Object.prototype.toString.call(process))&&(l=n(5448)),l),transformRequest:[function(t,e){if(i(e,"Accept"),i(e,"Content-Type"),r.isFormData(t)||r.isArrayBuffer(t)||r.isBuffer(t)||r.isStream(t)||r.isFile(t)||r.isBlob(t))return t;if(r.isArrayBufferView(t))return t.buffer;if(r.isURLSearchParams(t))return u(e,"application/x-www-form-urlencoded;charset=utf-8"),t.toString();var n,o=r.isObject(t),s=e&&e["Content-Type"];if((n=r.isFileList(t))||o&&"multipart/form-data"===s){var c=this.env&&this.env.FormData;return a(n?{"files[]":t}:t,c&&new c)}return o||"application/json"===s?(u(e,"application/json"),function(t,e,n){if(r.isString(t))try{return(0,JSON.parse)(t),r.trim(t)}catch(t){if("SyntaxError"!==t.name)throw t}return(0,JSON.stringify)(t)}(t)):t}],transformResponse:[function(t){var e=this.transitional||f.transitional,n=e&&e.silentJSONParsing,i=e&&e.forcedJSONParsing,s=!n&&"json"===this.responseType;if(s||i&&r.isString(t)&&t.length)try{return JSON.parse(t)}catch(t){if(s){if("SyntaxError"===t.name)throw o.from(t,o.ERR_BAD_RESPONSE,this,null,this.response);throw t}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:n(1623)},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};r.forEach(["delete","get","head"],(function(t){f.headers[t]={}})),r.forEach(["post","put","patch"],(function(t){f.headers[t]=r.merge(c)})),t.exports=f},7874:t=>{"use strict";t.exports={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1}},7288:t=>{t.exports={version:"0.27.2"}},1849:t=>{"use strict";t.exports=function(t,e){return function(){for(var n=new Array(arguments.length),r=0;r<n.length;r++)n[r]=arguments[r];return t.apply(e,n)}}},5327:(t,e,n)=>{"use strict";var r=n(4867);function i(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}t.exports=function(t,e,n){if(!e)return t;var o;if(n)o=n(e);else if(r.isURLSearchParams(e))o=e.toString();else{var s=[];r.forEach(e,(function(t,e){null!=t&&(r.isArray(t)?e+="[]":t=[t],r.forEach(t,(function(t){r.isDate(t)?t=t.toISOString():r.isObject(t)&&(t=JSON.stringify(t)),s.push(i(e)+"="+i(t))})))})),o=s.join("&")}if(o){var a=t.indexOf("#");-1!==a&&(t=t.slice(0,a)),t+=(-1===t.indexOf("?")?"?":"&")+o}return t}},7303:t=>{"use strict";t.exports=function(t,e){return e?t.replace(/\/+$/,"")+"/"+e.replace(/^\/+/,""):t}},4372:(t,e,n)=>{"use strict";var r=n(4867);t.exports=r.isStandardBrowserEnv()?{write:function(t,e,n,i,o,s){var a=[];a.push(t+"="+encodeURIComponent(e)),r.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),r.isString(i)&&a.push("path="+i),r.isString(o)&&a.push("domain="+o),!0===s&&a.push("secure"),document.cookie=a.join("; ")},read:function(t){var e=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove:function(t){this.write(t,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}}},1793:t=>{"use strict";t.exports=function(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}},6268:(t,e,n)=>{"use strict";var r=n(4867);t.exports=function(t){return r.isObject(t)&&!0===t.isAxiosError}},7985:(t,e,n)=>{"use strict";var r=n(4867);t.exports=r.isStandardBrowserEnv()?function(){var t,e=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");function i(t){var r=t;return e&&(n.setAttribute("href",r),r=n.href),n.setAttribute("href",r),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:"/"===n.pathname.charAt(0)?n.pathname:"/"+n.pathname}}return t=i(window.location.href),function(e){var n=r.isString(e)?i(e):e;return n.protocol===t.protocol&&n.host===t.host}}():function(){return!0}},6016:(t,e,n)=>{"use strict";var r=n(4867);t.exports=function(t,e){r.forEach(t,(function(n,r){r!==e&&r.toUpperCase()===e.toUpperCase()&&(t[e]=n,delete t[r])}))}},1623:t=>{t.exports=null},4109:(t,e,n)=>{"use strict";var r=n(4867),i=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];t.exports=function(t){var e,n,o,s={};return t?(r.forEach(t.split("\n"),(function(t){if(o=t.indexOf(":"),e=r.trim(t.substr(0,o)).toLowerCase(),n=r.trim(t.substr(o+1)),e){if(s[e]&&i.indexOf(e)>=0)return;s[e]="set-cookie"===e?(s[e]?s[e]:[]).concat([n]):s[e]?s[e]+", "+n:n}})),s):s}},205:t=>{"use strict";t.exports=function(t){var e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}},8713:t=>{"use strict";t.exports=function(t){return function(e){return t.apply(null,e)}}},7675:(t,e,n)=>{"use strict";var r=n(4867);t.exports=function(t,e){e=e||new FormData;var n=[];function i(t){return null===t?"":r.isDate(t)?t.toISOString():r.isArrayBuffer(t)||r.isTypedArray(t)?"function"==typeof Blob?new Blob([t]):Buffer.from(t):t}return function t(o,s){if(r.isPlainObject(o)||r.isArray(o)){if(-1!==n.indexOf(o))throw Error("Circular reference detected in "+s);n.push(o),r.forEach(o,(function(n,o){if(!r.isUndefined(n)){var a,c=s?s+"."+o:o;if(n&&!s&&"object"==typeof n)if(r.endsWith(o,"{}"))n=JSON.stringify(n);else if(r.endsWith(o,"[]")&&(a=r.toArray(n)))return void a.forEach((function(t){!r.isUndefined(t)&&e.append(c,i(t))}));t(n,c)}})),n.pop()}else e.append(s,i(o))}(t),e}},4875:(t,e,n)=>{"use strict";var r=n(7288).version,i=n(2648),o={};["object","boolean","number","function","string","symbol"].forEach((function(t,e){o[t]=function(n){return typeof n===t||"a"+(e<1?"n ":" ")+t}}));var s={};o.transitional=function(t,e,n){function o(t,e){return"[Axios v"+r+"] Transitional option '"+t+"'"+e+(n?". "+n:"")}return function(n,r,a){if(!1===t)throw new i(o(r," has been removed"+(e?" in "+e:"")),i.ERR_DEPRECATED);return e&&!s[r]&&(s[r]=!0,console.warn(o(r," has been deprecated since v"+e+" and will be removed in the near future"))),!t||t(n,r,a)}},t.exports={assertOptions:function(t,e,n){if("object"!=typeof t)throw new i("options must be an object",i.ERR_BAD_OPTION_VALUE);for(var r=Object.keys(t),o=r.length;o-- >0;){var s=r[o],a=e[s];if(a){var c=t[s],u=void 0===c||a(c,s,t);if(!0!==u)throw new i("option "+s+" must be "+u,i.ERR_BAD_OPTION_VALUE)}else if(!0!==n)throw new i("Unknown option "+s,i.ERR_BAD_OPTION)}},validators:o}},4867:(t,e,n)=>{"use strict";var r,i=n(1849),o=Object.prototype.toString,s=(r=Object.create(null),function(t){var e=o.call(t);return r[e]||(r[e]=e.slice(8,-1).toLowerCase())});function a(t){return t=t.toLowerCase(),function(e){return s(e)===t}}function c(t){return Array.isArray(t)}function u(t){return void 0===t}var l=a("ArrayBuffer");function f(t){return null!==t&&"object"==typeof t}function d(t){if("object"!==s(t))return!1;var e=Object.getPrototypeOf(t);return null===e||e===Object.prototype}var h=a("Date"),p=a("File"),g=a("Blob"),m=a("FileList");function v(t){return"[object Function]"===o.call(t)}var y=a("URLSearchParams");function b(t,e){if(null!=t)if("object"!=typeof t&&(t=[t]),c(t))for(var n=0,r=t.length;n<r;n++)e.call(null,t[n],n,t);else for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&e.call(null,t[i],i,t)}var w,S=(w="undefined"!=typeof Uint8Array&&Object.getPrototypeOf(Uint8Array),function(t){return w&&t instanceof w});t.exports={isArray:c,isArrayBuffer:l,isBuffer:function(t){return null!==t&&!u(t)&&null!==t.constructor&&!u(t.constructor)&&"function"==typeof t.constructor.isBuffer&&t.constructor.isBuffer(t)},isFormData:function(t){var e="[object FormData]";return t&&("function"==typeof FormData&&t instanceof FormData||o.call(t)===e||v(t.toString)&&t.toString()===e)},isArrayBufferView:function(t){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(t):t&&t.buffer&&l(t.buffer)},isString:function(t){return"string"==typeof t},isNumber:function(t){return"number"==typeof t},isObject:f,isPlainObject:d,isUndefined:u,isDate:h,isFile:p,isBlob:g,isFunction:v,isStream:function(t){return f(t)&&v(t.pipe)},isURLSearchParams:y,isStandardBrowserEnv:function(){return("undefined"==typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&"undefined"!=typeof window&&"undefined"!=typeof document},forEach:b,merge:function t(){var e={};function n(n,r){d(e[r])&&d(n)?e[r]=t(e[r],n):d(n)?e[r]=t({},n):c(n)?e[r]=n.slice():e[r]=n}for(var r=0,i=arguments.length;r<i;r++)b(arguments[r],n);return e},extend:function(t,e,n){return b(e,(function(e,r){t[r]=n&&"function"==typeof e?i(e,n):e})),t},trim:function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")},stripBOM:function(t){return 65279===t.charCodeAt(0)&&(t=t.slice(1)),t},inherits:function(t,e,n,r){t.prototype=Object.create(e.prototype,r),t.prototype.constructor=t,n&&Object.assign(t.prototype,n)},toFlatObject:function(t,e,n){var r,i,o,s={};e=e||{};do{for(i=(r=Object.getOwnPropertyNames(t)).length;i-- >0;)s[o=r[i]]||(e[o]=t[o],s[o]=!0);t=Object.getPrototypeOf(t)}while(t&&(!n||n(t,e))&&t!==Object.prototype);return e},kindOf:s,kindOfTest:a,endsWith:function(t,e,n){t=String(t),(void 0===n||n>t.length)&&(n=t.length),n-=e.length;var r=t.indexOf(e,n);return-1!==r&&r===n},toArray:function(t){if(!t)return null;var e=t.length;if(u(e))return null;for(var n=new Array(e);e-- >0;)n[e]=t[e];return n},isTypedArray:S,isFileList:m}},2498:(t,e,n)=>{"use strict";n.d(e,{default:()=>o});var r=n(9581);function i(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}const o=function(){var t=Array.from((0,r.n)("meganav-control")),e=Array.from((0,r.n)("meganav-panel")),n=getComputedStyle(document.documentElement).getPropertyValue("--bp-md"),o=function(t){return"search"===t.dataset.control},s=function(e,r,o){if(window.matchMedia("(hover: hover) and (pointer: fine) and (min-width: ".concat(n,")")).matches&&!t.some((function(t){return t===document.activeElement}))&&!function(){var t=document.querySelector('[data-id="meganav-panel"]#panel-search');if(t)return!t.classList.contains("invisible")}()){var s,a=["invisible","visible"];(s=r.classList).replace.apply(s,function(t){if(Array.isArray(t))return i(t)}(c=o?a:a.reverse())||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(c)||function(t,e){if(t){if("string"==typeof t)return i(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(t,e):void 0}}(c)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),e.setAttribute("aria-expanded",o)}var c};return t.map((function(n){var i,a,c=n.parentNode,u=document.querySelector("#".concat(n.getAttribute("aria-controls"))),l=function(n,i){return function(){if(t.forEach((function(t){return t!==n&&t.setAttribute("aria-expanded",!1)})),e.forEach((function(t){return t!==i&&t.classList.replace("visible","invisible")})),"true"===n.getAttribute("aria-expanded")?(n.setAttribute("aria-expanded",!1),i.classList.replace("visible","invisible")):(n.setAttribute("aria-expanded",!0),i.classList.replace("invisible","visible")),o(n)){var s=(0,r.A)("meganav-search-input",i);if(!s)return;s.focus()}else n.focus()}}(n,u);return n.addEventListener("click",l),o(n)||(i=function(t,e){return function(){return s(t,e,!0)}}(n,u),a=function(t,e){return function(){return s(t,e,!1)}}(n,u),c.addEventListener("mouseenter",i),c.addEventListener("mouseleave",a)),[{teardown:function(){i&&a&&(c.removeEventListener("mouseenter",i),c.removeEventListener("mouseleave",a)),n.removeEventListener("click",l)},clear:function(){n.setAttribute("aria-expanded",!1),u.classList.replace("visible","invisible")}}]})).flat()}},1792:(t,e,n)=>{"use strict";n.d(e,{default:()=>s});var r=n(6265),i=n.n(r),o=n(9581);const s=function(t){var e=t.clearPanels,n=(0,o.A)("meganav-control-mobile-dropdown"),r=(0,o.A)("meganav-mobile-dropdown"),s=(0,o.A)("meganav-control-mobile-dropdown-menu"),a=(0,o.A)("meganav-control-mobile-dropdown-close"),c=function(){"false"===n.getAttribute("aria-expanded")?(r.classList.replace("invisible","visible"),n.setAttribute("aria-expanded",!0),i().disablePageScroll()):(r.classList.replace("visible","invisible"),n.setAttribute("aria-expanded",!1),i().enablePageScroll(),e()),s.classList.toggle("hidden"),a.classList.toggle("hidden")};return n.addEventListener("click",c),{teardown:function(){n.removeEventListener("click",c),i().enablePageScroll()},clear:function(){r.classList.replace("visible","invisible"),n.setAttribute("aria-expanded",!1),s.classList.remove("hidden"),a.classList.add("hidden"),i().enablePageScroll()}}}},7359:(t,e,n)=>{"use strict";n.d(e,{default:()=>i});var r=n(9581);const i=function(){var t=Array.from((0,r.n)("meganav-control-mobile-panel-close")),e=Array.from((0,r.n)("meganav-control-mobile-panel-open"));return t.map((function(t){var n=e.find((function(e){return e.getAttribute("aria-controls")===t.getAttribute("aria-controls")})),r=document.querySelector("#".concat(t.getAttribute("aria-controls"))),i=function(t,e,n){return function(){t.setAttribute("aria-expanded",!1),e.setAttribute("aria-expanded",!1),n.classList.replace("block","hidden"),n.style.height=null}}(t,n,r);return t.addEventListener("click",i),{teardown:function(){return t.removeEventListener("click",i)},clear:function(){return t.setAttribute("aria-expanded",!1)}}}))}},9552:(t,e,n)=>{"use strict";n.d(e,{default:()=>i});var r=n(9581);const i=function(){var t,e=Array.from((0,r.n)("meganav-control-mobile-panel-close")),n=Array.from((0,r.n)("meganav-control-mobile-panel-open")),i=(0,r.A)("meganav-mobile-dropdown"),o=(t=getComputedStyle(document.documentElement).getPropertyValue("--ui-meganav-height"),parseFloat(t)*parseFloat(getComputedStyle(document.documentElement).fontSize));return n.map((function(t){var n=e.find((function(e){return e.getAttribute("aria-controls")===t.getAttribute("aria-controls")})),r=document.querySelector("#".concat(t.getAttribute("aria-controls"))),s=function(t,e,n){return function(){t.setAttribute("aria-expanded",!0),e.setAttribute("aria-expanded",!0),n.classList.replace("hidden","block"),n.style.height="".concat(window.innerHeight-o>n.offsetHeight?n.offsetHeight:window.innerHeight-o,"px")}}(t,n,r);return t.addEventListener("click",s),{teardown:function(){return t.removeEventListener("click",s)},clear:function(){r.classList.replace("block","hidden"),i.classList.remove("ui-meganav-mobile-dropdown-expand"),t.setAttribute("aria-expanded",!1),r.style.height=null}}}))}},6364:(t,e,n)=>{"use strict";n.d(e,{default:()=>s});var r=n(9581),i=n(727),o=n.n(i);const s=function(t){if(!t)return console.log("No AddSearch API key provided, skipping search suggestions."),[];var e=new(o())(t);return[(0,r.A)("meganav-search-input"),(0,r.A)("meganav-mobile-search-input")].filter((function(t){return t})).map((function(t){var n=t.parentNode,i=(0,r.A)("meganav-search-autocomplete-container",n),o=(0,r.A)("meganav-search-autocomplete-list",n),s=(0,r.A)("meganav-search-input-clear",n);return function(t){var e=t.input,n=t.container,r=t.listContainer,i=t.clear,o=t.client;o.setAnalyticsTag("Meganav autocomplete"),o.setThrottleTime(400);var s,a=function(){n.classList.add("hidden"),r.innerHTML=""},c=function(t){(t||"").length>0&&i?i.classList.remove("invisible"):i&&i.classList.add("invisible")},u=function(t,e){return t.replace(e.toLowerCase(),'<span class="font-light">'.concat(e,"</span>"))},l=function(t){return window.location="/search?q=".concat(t)},f=function(t){var e=r.querySelector('[data-suggestion-index="'.concat(t+1,'"]'));e&&e.focus()},d=function(t){var e=t-1,n=r.querySelector('[data-suggestion-index="'.concat(e,'"]'));n&&n.focus()},h=function(t){var i=t.target.value;"ArrowDown"!==t.key?i?o.suggestions(i,function(t){return function(){var i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(c(t),Array.isArray(i.suggestions))if(0!==i.suggestions.length){var o=i.suggestions.map((function(n,r){var i=document.createElement("li"),o=document.createElement("button");return o.type="button",o.classList.add("ui-text-menu2","font-medium","p-8","w-full","text-left","rounded","hover:text-gui-hover","focus:outline-gui-focus","hover:bg-light-grey"),o.innerHTML=u(n.value,t),o.dataset.suggestionIndex=r,o.addEventListener("click",(function(){l(n.value)})),o.addEventListener("keydown",(function(t){var i=t.key;"ArrowDown"===i?f(r):"ArrowUp"===i&&r-1<0?e.focus():"ArrowUp"===i&&r-1>=0?d(r):"Enter"!==i&&"Space"!==i||l(n.value)})),i.appendChild(o),i}));r.innerHTML="",o.forEach((function(t){return r.appendChild(t)})),n.classList.remove("hidden")}else a();else a()}}(i)):a():f(0)};return i&&(s=function(){e.value="",i.classList.add("invisible"),a()},i.addEventListener("click",s)),e.addEventListener("keyup",h),{teardown:function(){e.removeEventListener("keyup",h),i&&i.removeEventListener("click",s)},clear:function(){e.value="",a()}}}({input:t,container:i,listContainer:o,client:e,clear:s})}))}},3169:(t,e,n)=>{"use strict";n.d(e,{default:()=>l});var r=n(9581),i=function(t){return new DOMMatrix(window.getComputedStyle(t).transform).e},o=function(t,e){return t.style.transform="translateX(".concat(e,"px)")},s=function(t,e){return t>=e},a=function(t,e,n,r){return Math.abs(t-n+r)>e},c=function(t,e){var n;return(null===(n=t.changedTouches[0])||void 0===n?void 0:n.clientX)-e},u=function(t){return Math.abs(t)<5};const l=function(){var t,e=(0,r.A)("meganav-mobile-search-input"),n=(0,r.A)("meganav-mobile-search-suggestions"),l=n.querySelector("ul"),f=l.querySelectorAll("li"),d=Array.from(f).map((function(t){return t.getBoundingClientRect().width})).reduce((function(t,e){return t+e}),0),h=function(e){var n;t=null===(n=e.touches[0])||void 0===n?void 0:n.clientX},p=function(e){var n=c(e,t);u(n)||(n>0?function(t,e){var n=i(l),r=Math.round(n+t);s(r,24)||o(l,r)}(n):function(t,e){var n=l.getBoundingClientRect().width,r=i(l),s=Math.round(r+t);a(s,d,n,96)||o(l,s)}(n))},g=function(e){var n=c(e,t);u(n)||(n>0?function(t,e){var n=i(l),r=Math.round(n+t);s(r,24)&&(r=0),o(l,r)}(n):function(t,e){var n=l.getBoundingClientRect().width,r=i(l),s=Math.round(r+t);a(s,d,n,48)&&(s=-(d-n+48)),o(l,s)}(n))},m=function(){n.classList.add("max-h-96")},v=function(t){t.relatedTarget!==n.querySelectorAll("a")[0]&&n.classList.remove("max-h-96")};return e.addEventListener("focus",m),e.addEventListener("blur",v),n.addEventListener("touchstart",h),n.addEventListener("touchmove",p),n.addEventListener("touchend",g),{teardown:function(){e.removeEventListener("focus",m),e.removeEventListener("blur",v),n.removeEventListener("touchstart",h),n.removeEventListener("touchmove",p),n.removeEventListener("touchend",g)},clear:function(){n.classList.remove("max-h-96"),l.style.transform="translateX(0px)"}}}},9581:(t,e,n)=>{"use strict";n.d(e,{A:()=>r,n:()=>i});var r=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;return e.querySelector("[data-id=".concat(t,"]"))},i=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;return e.querySelectorAll("[data-id=".concat(t,"]"))}},2702:function(t,e,n){t.exports=function(){"use strict";function t(t){return"function"==typeof t}var e=Array.isArray?Array.isArray:function(t){return"[object Array]"===Object.prototype.toString.call(t)},r=0,i=void 0,o=void 0,s=function(t,e){h[r]=t,h[r+1]=e,2===(r+=2)&&(o?o(p):b())};var a="undefined"!=typeof window?window:void 0,c=a||{},u=c.MutationObserver||c.WebKitMutationObserver,l="undefined"==typeof self&&"undefined"!=typeof process&&"[object process]"==={}.toString.call(process),f="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;function d(){var t=setTimeout;return function(){return t(p,1)}}var h=new Array(1e3);function p(){for(var t=0;t<r;t+=2)(0,h[t])(h[t+1]),h[t]=void 0,h[t+1]=void 0;r=0}var g,m,v,y,b=void 0;function w(t,e){var n=this,r=new this.constructor(x);void 0===r[A]&&P(r);var i=n._state;if(i){var o=arguments[i-1];s((function(){return C(i,r,o,n._result)}))}else R(n,r,t,e);return r}function S(t){if(t&&"object"==typeof t&&t.constructor===this)return t;var e=new this(x);return F(e,t),e}b=l?function(){return process.nextTick(p)}:u?(m=0,v=new u(p),y=document.createTextNode(""),v.observe(y,{characterData:!0}),function(){y.data=m=++m%2}):f?((g=new MessageChannel).port1.onmessage=p,function(){return g.port2.postMessage(0)}):void 0===a?function(){try{var t=Function("return this")().require("vertx");return void 0!==(i=t.runOnLoop||t.runOnContext)?function(){i(p)}:d()}catch(t){return d()}}():d();var A=Math.random().toString(36).substring(2);function x(){}var E=void 0;function T(e,n,r){n.constructor===e.constructor&&r===w&&n.constructor.resolve===S?function(t,e){1===e._state?k(t,e._result):2===e._state?L(t,e._result):R(e,void 0,(function(e){return F(t,e)}),(function(e){return L(t,e)}))}(e,n):void 0===r?k(e,n):t(r)?function(t,e,n){s((function(t){var r=!1,i=function(t,e,n,r){try{t.call(e,n,r)}catch(t){return t}}(n,e,(function(n){r||(r=!0,e!==n?F(t,n):k(t,n))}),(function(e){r||(r=!0,L(t,e))}),t._label);!r&&i&&(r=!0,L(t,i))}),t)}(e,n,r):k(e,n)}function F(t,e){if(t===e)L(t,new TypeError("You cannot resolve a promise with itself"));else if(i=typeof(r=e),null===r||"object"!==i&&"function"!==i)k(t,e);else{var n=void 0;try{n=e.then}catch(e){return void L(t,e)}T(t,e,n)}var r,i}function O(t){t._onerror&&t._onerror(t._result),_(t)}function k(t,e){t._state===E&&(t._result=e,t._state=1,0!==t._subscribers.length&&s(_,t))}function L(t,e){t._state===E&&(t._state=2,t._result=e,s(O,t))}function R(t,e,n,r){var i=t._subscribers,o=i.length;t._onerror=null,i[o]=e,i[o+1]=n,i[o+2]=r,0===o&&t._state&&s(_,t)}function _(t){var e=t._subscribers,n=t._state;if(0!==e.length){for(var r=void 0,i=void 0,o=t._result,s=0;s<e.length;s+=3)r=e[s],i=e[s+n],r?C(n,r,i,o):i(o);t._subscribers.length=0}}function C(e,n,r,i){var o=t(r),s=void 0,a=void 0,c=!0;if(o){try{s=r(i)}catch(t){c=!1,a=t}if(n===s)return void L(n,new TypeError("A promises callback cannot return that same promise."))}else s=i;n._state!==E||(o&&c?F(n,s):!1===c?L(n,a):1===e?k(n,s):2===e&&L(n,s))}var j=0;function P(t){t[A]=j++,t._state=void 0,t._result=void 0,t._subscribers=[]}var N=function(){function t(t,n){this._instanceConstructor=t,this.promise=new t(x),this.promise[A]||P(this.promise),e(n)?(this.length=n.length,this._remaining=n.length,this._result=new Array(this.length),0===this.length?k(this.promise,this._result):(this.length=this.length||0,this._enumerate(n),0===this._remaining&&k(this.promise,this._result))):L(this.promise,new Error("Array Methods must be provided an Array"))}return t.prototype._enumerate=function(t){for(var e=0;this._state===E&&e<t.length;e++)this._eachEntry(t[e],e)},t.prototype._eachEntry=function(t,e){var n=this._instanceConstructor,r=n.resolve;if(r===S){var i=void 0,o=void 0,s=!1;try{i=t.then}catch(t){s=!0,o=t}if(i===w&&t._state!==E)this._settledAt(t._state,e,t._result);else if("function"!=typeof i)this._remaining--,this._result[e]=t;else if(n===D){var a=new n(x);s?L(a,o):T(a,t,i),this._willSettleAt(a,e)}else this._willSettleAt(new n((function(e){return e(t)})),e)}else this._willSettleAt(r(t),e)},t.prototype._settledAt=function(t,e,n){var r=this.promise;r._state===E&&(this._remaining--,2===t?L(r,n):this._result[e]=n),0===this._remaining&&k(r,this._result)},t.prototype._willSettleAt=function(t,e){var n=this;R(t,void 0,(function(t){return n._settledAt(1,e,t)}),(function(t){return n._settledAt(2,e,t)}))},t}();var D=function(){function e(t){this[A]=j++,this._result=this._state=void 0,this._subscribers=[],x!==t&&("function"!=typeof t&&function(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}(),this instanceof e?function(t,e){try{e((function(e){F(t,e)}),(function(e){L(t,e)}))}catch(e){L(t,e)}}(this,t):function(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}())}return e.prototype.catch=function(t){return this.then(null,t)},e.prototype.finally=function(e){var n=this,r=n.constructor;return t(e)?n.then((function(t){return r.resolve(e()).then((function(){return t}))}),(function(t){return r.resolve(e()).then((function(){throw t}))})):n.then(e,e)},e}();return D.prototype.then=w,D.all=function(t){return new N(this,t).promise},D.race=function(t){var n=this;return e(t)?new n((function(e,r){for(var i=t.length,o=0;o<i;o++)n.resolve(t[o]).then(e,r)})):new n((function(t,e){return e(new TypeError("You must pass an array to race."))}))},D.resolve=S,D.reject=function(t){var e=new this(x);return L(e,t),e},D._setScheduler=function(t){o=t},D._setAsap=function(t){s=t},D._asap=s,D.polyfill=function(){var t=void 0;if(void 0!==n.g)t=n.g;else if("undefined"!=typeof self)t=self;else try{t=Function("return this")()}catch(t){throw new Error("polyfill failed because global object is unavailable in this environment")}var e=t.Promise;if(e){var r=null;try{r=Object.prototype.toString.call(e.resolve())}catch(t){}if("[object Promise]"===r&&!e.cast)return}t.Promise=D},D.Promise=D,D}()},3096:(t,e,n)=>{var r="Expected a function",i=/^\s+|\s+$/g,o=/^[-+]0x[0-9a-f]+$/i,s=/^0b[01]+$/i,a=/^0o[0-7]+$/i,c=parseInt,u="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,l="object"==typeof self&&self&&self.Object===Object&&self,f=u||l||Function("return this")(),d=Object.prototype.toString,h=Math.max,p=Math.min,g=function(){return f.Date.now()};function m(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}function v(t){if("number"==typeof t)return t;if(function(t){return"symbol"==typeof t||function(t){return!!t&&"object"==typeof t}(t)&&"[object Symbol]"==d.call(t)}(t))return NaN;if(m(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=m(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=t.replace(i,"");var n=s.test(t);return n||a.test(t)?c(t.slice(2),n?2:8):o.test(t)?NaN:+t}t.exports=function(t,e,n){var i=!0,o=!0;if("function"!=typeof t)throw new TypeError(r);return m(n)&&(i="leading"in n?!!n.leading:i,o="trailing"in n?!!n.trailing:o),function(t,e,n){var i,o,s,a,c,u,l=0,f=!1,d=!1,y=!0;if("function"!=typeof t)throw new TypeError(r);function b(e){var n=i,r=o;return i=o=void 0,l=e,a=t.apply(r,n)}function w(t){return l=t,c=setTimeout(A,e),f?b(t):a}function S(t){var n=t-u;return void 0===u||n>=e||n<0||d&&t-l>=s}function A(){var t=g();if(S(t))return x(t);c=setTimeout(A,function(t){var n=e-(t-u);return d?p(n,s-(t-l)):n}(t))}function x(t){return c=void 0,y&&i?b(t):(i=o=void 0,a)}function E(){var t=g(),n=S(t);if(i=arguments,o=this,u=t,n){if(void 0===c)return w(u);if(d)return c=setTimeout(A,e),b(u)}return void 0===c&&(c=setTimeout(A,e)),a}return e=v(e)||0,m(n)&&(f=!!n.leading,s=(d="maxWait"in n)?h(v(n.maxWait)||0,e):s,y="trailing"in n?!!n.trailing:y),E.cancel=function(){void 0!==c&&clearTimeout(c),l=0,i=u=o=c=void 0},E.flush=function(){return void 0===c?a:x(g())},E}(t,e,{leading:i,maxWait:e,trailing:o})}},6265:function(t){var e;e=function(){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=0)}([function(t,e,n){"use strict";n.r(e);var r=function(t){return Array.isArray(t)?t:[t]},i=function(t){return t instanceof Node},o=function(t,e){if(t&&e){t=function(t){return t instanceof NodeList}(t)?t:[t];for(var n=0;n<t.length&&!0!==e(t[n],n,t.length);n++);}},s=function(t){return console.error("[scroll-lock] ".concat(t))},a=function(t){if(Array.isArray(t))return t.join(", ")},c=function(t){var e=[];return o(t,(function(t){return e.push(t)})),e},u=function(t,e){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:document;if(n&&-1!==c(r.querySelectorAll(e)).indexOf(t))return t;for(;(t=t.parentElement)&&-1===c(r.querySelectorAll(e)).indexOf(t););return t},l=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:document,r=-1!==c(n.querySelectorAll(e)).indexOf(t);return r},f=function(t){if(t)return"hidden"===getComputedStyle(t).overflow},d=function(t){if(t)return!!f(t)||t.scrollTop<=0},h=function(t){if(t){if(f(t))return!0;var e=t.scrollTop,n=t.scrollHeight;return e+t.offsetHeight>=n}},p=function(t){if(t)return!!f(t)||t.scrollLeft<=0},g=function(t){if(t){if(f(t))return!0;var e=t.scrollLeft,n=t.scrollWidth;return e+t.offsetWidth>=n}},m=function(t){return l(t,'textarea, [contenteditable="true"]')},v=function(t){return l(t,'input[type="range"]')};function y(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}n.d(e,"disablePageScroll",(function(){return S})),n.d(e,"enablePageScroll",(function(){return A})),n.d(e,"getScrollState",(function(){return x})),n.d(e,"clearQueueScrollLocks",(function(){return E})),n.d(e,"getTargetScrollBarWidth",(function(){return T})),n.d(e,"getCurrentTargetScrollBarWidth",(function(){return F})),n.d(e,"getPageScrollBarWidth",(function(){return O})),n.d(e,"getCurrentPageScrollBarWidth",(function(){return k})),n.d(e,"addScrollableTarget",(function(){return L})),n.d(e,"removeScrollableTarget",(function(){return R})),n.d(e,"addScrollableSelector",(function(){return _})),n.d(e,"removeScrollableSelector",(function(){return C})),n.d(e,"addLockableTarget",(function(){return j})),n.d(e,"addLockableSelector",(function(){return P})),n.d(e,"setFillGapMethod",(function(){return N})),n.d(e,"addFillGapTarget",(function(){return D})),n.d(e,"removeFillGapTarget",(function(){return U})),n.d(e,"addFillGapSelector",(function(){return B})),n.d(e,"removeFillGapSelector",(function(){return M})),n.d(e,"refillGaps",(function(){return z}));var b=["padding","margin","width","max-width","none"],w={scroll:!0,queue:0,scrollableSelectors:["[data-scroll-lock-scrollable]"],lockableSelectors:["body","[data-scroll-lock-lockable]"],fillGapSelectors:["body","[data-scroll-lock-fill-gap]","[data-scroll-lock-lockable]"],fillGapMethod:b[0],startTouchY:0,startTouchX:0},S=function(t){w.queue<=0&&(w.scroll=!1,W(),J()),L(t),w.queue++},A=function(t){w.queue>0&&w.queue--,w.queue<=0&&(w.scroll=!0,q(),K()),R(t)},x=function(){return w.scroll},E=function(){w.queue=0},T=function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(i(t)){var n=t.style.overflowY;e?x()||(t.style.overflowY=t.getAttribute("data-scroll-lock-saved-overflow-y-property")):t.style.overflowY="scroll";var r=F(t);return t.style.overflowY=n,r}return 0},F=function(t){if(i(t)){if(t===document.body){var e=document.documentElement.clientWidth;return window.innerWidth-e}var n=t.style.borderLeftWidth,r=t.style.borderRightWidth;t.style.borderLeftWidth="0px",t.style.borderRightWidth="0px";var o=t.offsetWidth-t.clientWidth;return t.style.borderLeftWidth=n,t.style.borderRightWidth=r,o}return 0},O=function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return T(document.body,t)},k=function(){return F(document.body)},L=function(t){t&&r(t).map((function(t){o(t,(function(t){i(t)?t.setAttribute("data-scroll-lock-scrollable",""):s('"'.concat(t,'" is not a Element.'))}))}))},R=function(t){t&&r(t).map((function(t){o(t,(function(t){i(t)?t.removeAttribute("data-scroll-lock-scrollable"):s('"'.concat(t,'" is not a Element.'))}))}))},_=function(t){t&&r(t).map((function(t){w.scrollableSelectors.push(t)}))},C=function(t){t&&r(t).map((function(t){w.scrollableSelectors=w.scrollableSelectors.filter((function(e){return e!==t}))}))},j=function(t){t&&(r(t).map((function(t){o(t,(function(t){i(t)?t.setAttribute("data-scroll-lock-lockable",""):s('"'.concat(t,'" is not a Element.'))}))})),x()||W())},P=function(t){t&&(r(t).map((function(t){w.lockableSelectors.push(t)})),x()||W(),B(t))},N=function(t){if(t)if(-1!==b.indexOf(t))w.fillGapMethod=t,z();else{var e=b.join(", ");s('"'.concat(t,'" method is not available!\nAvailable fill gap methods: ').concat(e,"."))}},D=function(t){t&&r(t).map((function(t){o(t,(function(t){i(t)?(t.setAttribute("data-scroll-lock-fill-gap",""),w.scroll||V(t)):s('"'.concat(t,'" is not a Element.'))}))}))},U=function(t){t&&r(t).map((function(t){o(t,(function(t){i(t)?(t.removeAttribute("data-scroll-lock-fill-gap"),w.scroll||Q(t)):s('"'.concat(t,'" is not a Element.'))}))}))},B=function(t){t&&r(t).map((function(t){-1===w.fillGapSelectors.indexOf(t)&&(w.fillGapSelectors.push(t),w.scroll||X(t))}))},M=function(t){t&&r(t).map((function(t){w.fillGapSelectors=w.fillGapSelectors.filter((function(e){return e!==t})),w.scroll||$(t)}))},z=function(){w.scroll||J()},W=function(){var t=a(w.lockableSelectors);I(t)},q=function(){var t=a(w.lockableSelectors);H(t)},I=function(t){var e=document.querySelectorAll(t);o(e,(function(t){G(t)}))},H=function(t){var e=document.querySelectorAll(t);o(e,(function(t){Y(t)}))},G=function(t){if(i(t)&&"true"!==t.getAttribute("data-scroll-lock-locked")){var e=window.getComputedStyle(t);t.setAttribute("data-scroll-lock-saved-overflow-y-property",e.overflowY),t.setAttribute("data-scroll-lock-saved-inline-overflow-property",t.style.overflow),t.setAttribute("data-scroll-lock-saved-inline-overflow-y-property",t.style.overflowY),t.style.overflow="hidden",t.setAttribute("data-scroll-lock-locked","true")}},Y=function(t){i(t)&&"true"===t.getAttribute("data-scroll-lock-locked")&&(t.style.overflow=t.getAttribute("data-scroll-lock-saved-inline-overflow-property"),t.style.overflowY=t.getAttribute("data-scroll-lock-saved-inline-overflow-y-property"),t.removeAttribute("data-scroll-lock-saved-overflow-property"),t.removeAttribute("data-scroll-lock-saved-inline-overflow-property"),t.removeAttribute("data-scroll-lock-saved-inline-overflow-y-property"),t.removeAttribute("data-scroll-lock-locked"))},J=function(){w.fillGapSelectors.map((function(t){X(t)}))},K=function(){w.fillGapSelectors.map((function(t){$(t)}))},X=function(t){var e=document.querySelectorAll(t),n=-1!==w.lockableSelectors.indexOf(t);o(e,(function(t){V(t,n)}))},V=function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(i(t)){var n;if(""===t.getAttribute("data-scroll-lock-lockable")||e)n=T(t,!0);else{var r=u(t,a(w.lockableSelectors));n=T(r,!0)}"true"===t.getAttribute("data-scroll-lock-filled-gap")&&Q(t);var o=window.getComputedStyle(t);if(t.setAttribute("data-scroll-lock-filled-gap","true"),t.setAttribute("data-scroll-lock-current-fill-gap-method",w.fillGapMethod),"margin"===w.fillGapMethod){var s=parseFloat(o.marginRight);t.style.marginRight="".concat(s+n,"px")}else if("width"===w.fillGapMethod)t.style.width="calc(100% - ".concat(n,"px)");else if("max-width"===w.fillGapMethod)t.style.maxWidth="calc(100% - ".concat(n,"px)");else if("padding"===w.fillGapMethod){var c=parseFloat(o.paddingRight);t.style.paddingRight="".concat(c+n,"px")}}},$=function(t){var e=document.querySelectorAll(t);o(e,(function(t){Q(t)}))},Q=function(t){if(i(t)&&"true"===t.getAttribute("data-scroll-lock-filled-gap")){var e=t.getAttribute("data-scroll-lock-current-fill-gap-method");t.removeAttribute("data-scroll-lock-filled-gap"),t.removeAttribute("data-scroll-lock-current-fill-gap-method"),"margin"===e?t.style.marginRight="":"width"===e?t.style.width="":"max-width"===e?t.style.maxWidth="":"padding"===e&&(t.style.paddingRight="")}};"undefined"!=typeof window&&window.addEventListener("resize",(function(t){z()})),"undefined"!=typeof document&&(document.addEventListener("touchstart",(function(t){w.scroll||(w.startTouchY=t.touches[0].clientY,w.startTouchX=t.touches[0].clientX)})),document.addEventListener("touchmove",(function(t){if(!w.scroll){var e=w.startTouchY,n=w.startTouchX,r=t.touches[0].clientY,i=t.touches[0].clientX;if(t.touches.length<2){var o=a(w.scrollableSelectors),s={up:e<r,down:e>r,left:n<i,right:n>i},c={up:e+3<r,down:e-3>r,left:n+3<i,right:n-3>i};!function e(n){var r=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(n){var i=u(n,o,!1);if(v(n))return!1;if(r||m(n)&&u(n,o)||l(n,o)){var a=!1;p(n)&&g(n)?(s.up&&d(n)||s.down&&h(n))&&(a=!0):d(n)&&h(n)?(s.left&&p(n)||s.right&&g(n))&&(a=!0):(c.up&&d(n)||c.down&&h(n)||c.left&&p(n)||c.right&&g(n))&&(a=!0),a&&(i?e(i,!0):t.cancelable&&t.preventDefault())}else e(i)}else t.cancelable&&t.preventDefault()}(t.target)}}}),{passive:!1}),document.addEventListener("touchend",(function(t){w.scroll||(w.startTouchY=0,w.startTouchX=0)})));var Z={hide:function(t){s('"hide" is deprecated! Use "disablePageScroll" instead. \n https://github.com/FL3NKEY/scroll-lock#disablepagescrollscrollabletarget'),S(t)},show:function(t){s('"show" is deprecated! Use "enablePageScroll" instead. \n https://github.com/FL3NKEY/scroll-lock#enablepagescrollscrollabletarget'),A(t)},toggle:function(t){s('"toggle" is deprecated! Do not use it.'),x()?S():A(t)},getState:function(){return s('"getState" is deprecated! Use "getScrollState" instead. \n https://github.com/FL3NKEY/scroll-lock#getscrollstate'),x()},getWidth:function(){return s('"getWidth" is deprecated! Use "getPageScrollBarWidth" instead. \n https://github.com/FL3NKEY/scroll-lock#getpagescrollbarwidth'),O()},getCurrentWidth:function(){return s('"getCurrentWidth" is deprecated! Use "getCurrentPageScrollBarWidth" instead. \n https://github.com/FL3NKEY/scroll-lock#getcurrentpagescrollbarwidth'),k()},setScrollableTargets:function(t){s('"setScrollableTargets" is deprecated! Use "addScrollableTarget" instead. \n https://github.com/FL3NKEY/scroll-lock#addscrollabletargetscrollabletarget'),L(t)},setFillGapSelectors:function(t){s('"setFillGapSelectors" is deprecated! Use "addFillGapSelector" instead. \n https://github.com/FL3NKEY/scroll-lock#addfillgapselectorfillgapselector'),B(t)},setFillGapTargets:function(t){s('"setFillGapTargets" is deprecated! Use "addFillGapTarget" instead. \n https://github.com/FL3NKEY/scroll-lock#addfillgaptargetfillgaptarget'),D(t)},clearQueue:function(){s('"clearQueue" is deprecated! Use "clearQueueScrollLocks" instead. \n https://github.com/FL3NKEY/scroll-lock#clearqueuescrolllocks'),E()}},tt=function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(t){return Object.getOwnPropertyDescriptor(n,t).enumerable})))),r.forEach((function(e){y(t,e,n[e])}))}return t}({disablePageScroll:S,enablePageScroll:A,getScrollState:x,clearQueueScrollLocks:E,getTargetScrollBarWidth:T,getCurrentTargetScrollBarWidth:F,getPageScrollBarWidth:O,getCurrentPageScrollBarWidth:k,addScrollableSelector:_,removeScrollableSelector:C,addScrollableTarget:L,removeScrollableTarget:R,addLockableSelector:P,addLockableTarget:j,addFillGapSelector:B,removeFillGapSelector:M,addFillGapTarget:D,removeFillGapTarget:U,setFillGapMethod:N,refillGaps:z,_state:w},Z);e.default=tt}]).default},t.exports=e()}},e={};function n(r){var i=e[r];if(void 0!==i)return i.exports;var o=e[r]={exports:{}};return t[r].call(o.exports,o,o.exports,n),o.exports}n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e);var r={};return(()=>{"use strict";n.d(r,{default:()=>m});var t=n(3096),e=n.n(t),i=n(9581),o=n(2498),s=n(1792),a=n(9552),c=n(7359),u=n(6364),l=n(3169);function f(t){return function(t){if(Array.isArray(t))return d(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return d(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?d(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function d(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}var h=function(t){return window.onblur=function(){return t()},{teardown:function(){return window.onblur=null}}},p=function(t){var e=(0,i.A)("meganav"),n=function(n){e.contains(n.target)||t()};return document.addEventListener("click",n),{teardown:function(){return document.removeEventListener("click",n)}}},g=function(t){if("transparentToWhite"!==t)return{teardown:function(){}};var n=(0,i.A)("meganav"),r=(0,i.n)("meganav-link"),o=(0,i.A)("meganav-control-mobile-dropdown-menu"),s=(0,i.A)("meganav-control-mobile-dropdown-close"),a=(0,i.n)("meganav-control"),c=(0,i.A)("meganav-sign-up-btn"),u=[].concat(f(Array.from(a)),f(Array.from(r)),[(0,i.A)("meganav-logo")]),l=function(t){var e,n,r,i,a=["ui-icon-white","ui-icon-cool-black"],c=[].concat(a).reverse();t?(null==o||(e=o.classList).replace.apply(e,a),null==s||(n=s.classList).replace.apply(n,a)):(null==o||(r=o.classList).replace.apply(r,f(c)),null==s||(i=s.classList).replace.apply(i,f(c)))},d=function(t){t?(null==c||c.classList.replace("bg-white","bg-cool-black"),null==c||c.classList.replace("text-cool-black","text-white")):(null==c||c.classList.replace("bg-cool-black","bg-white"),null==c||c.classList.replace("text-white","text-cool-black"))},h=e()((function(){window.scrollY>5?(n.classList.replace("bg-transparent","bg-white"),d(!0),l(!0),u.forEach((function(t){return t.classList.replace("text-white","text-cool-black")}))):(n.classList.replace("bg-white","bg-transparent"),d(!1),l(!1),u.forEach((function(t){return t.classList.replace("text-cool-black","text-white")})))}),150);return document.addEventListener("scroll",h),{teardown:function(){return document.removeEventListener("scroll",h)}}};function m(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{themeName:null},e=t.themeName,n=t.addSearchApiKey,r=(0,o.default)(),i=(0,a.default)(),d=(0,c.default)(),m=(0,u.default)(n),v=(0,l.default)(),y=(0,s.default)({clearPanels:function(){return[].concat(f(i),f(d)).forEach((function(t){return t.clear()}))}}),b=function(){return[y,v].concat(f(i),f(d),f(r),f(m)).forEach((function(t){return t.clear()}))},w=[g(e),p(b),h(b),y,v].concat(f(r),f(i),f(d),f(m)).map((function(t){return t.teardown}));return function(){return w.forEach((function(t){return t()}))}}})(),r.default})()}));
@@ -2,20 +2,25 @@
2
2
  <%= notice %>
3
3
 
4
4
  <div class="ui-meganav ui-grid-px">
5
- <%= render(AblyUi::Core::Logo.new(data_id: "meganav-logo", href: logo_link)) %>
5
+ <div className="mr-24">
6
+ <%= render(AblyUi::Core::Logo.new(data_id: "meganav-logo", href: logo_link)) %>
7
+ </div>
6
8
  <%= render(AblyUi::Core::MeganavItemsDesktop.new(theme_name: @theme_name, url_base: url_base)) %>
7
9
 
8
10
  <% if @session_data[:signedIn] %>
9
11
  <%= render(AblyUi::Core::MeganavItemsSignedIn.new(session_data: @session_data, theme_name: @theme_name, url_base: url_base)) %>
10
12
  <% else %>
11
13
  <ul class="hidden md:flex items-center">
12
- <li>
14
+ <li class="ui-meganav-item">
13
15
  <%= link_to "Contact us", abs_url("/contact"), data: { id: "meganav-link" }, class: ["ui-meganav-link", theme(:text_color)] %>
14
16
  </li>
15
- <li>
16
- <%= link_to "Login", abs_url(login_link), data: { id: "meganav-link" }, class: ["ui-meganav-link", theme(:text_color)] %>
17
+ <li class="ui-meganav-item">
18
+ <%= link_to "Login", abs_url(login_link), data: { id: "meganav-link" }, class: ["ui-meganav-link", "mr-0", theme(:text_color)] %>
17
19
  </li>
18
- <li class="ml-16">
20
+ <li class="ui-meganav-item">
21
+ <%= render(AblyUi::Core::MeganavSearch.new(url_base: url_base)) %>
22
+ </li>
23
+ <li class="ui-meganav-item">
19
24
  <%= link_to "Sign up free", abs_url("/sign-up"), data: { id: "meganav-sign-up-btn" }, class: ["ui-btn", "p-btn-small", theme(:button_background_color), theme(:button_text_color)] %>
20
25
  </li>
21
26
  </ul>
@@ -14,41 +14,47 @@
14
14
  </div>
15
15
 
16
16
  <div>
17
- <h3 class="ui-meganav-overline" id="meganav-platform-panel-list-our-features">Our features</h3>
18
- <ul aria-labelledby="meganav-platform-panel-list-our-features">
17
+ <h3 class="ui-meganav-overline" id="meganav-platform-panel-list-examples">Examples</h3>
18
+ <ul aria-labelledby="meganav-platform-panel-list-examples">
19
19
  <li>
20
- <%= link_to abs_url("/pub-sub-messaging"), class: "ui-meganav-media group" do %>
21
- <p class="ui-meganav-media-heading">Publish/subscribe messaging</p>
22
- <p class="ui-meganav-media-copy">Feature-rich pub/sub messaging to power any realtime requirement.</p>
20
+ <%= link_to abs_url("/examples/avatar-stack"), class: "ui-meganav-media group" do %>
21
+ <p class="ui-meganav-media-heading">Avatar Stack</p>
22
+ <p class="ui-meganav-media-copy">See who is connected in a digital space.</p>
23
23
  <% end %>
24
24
  </li>
25
25
  <li>
26
- <%= link_to abs_url("/push-notifications"), class: "ui-meganav-media group" do %>
27
- <p class="ui-meganav-media-heading">Push notifications</p>
28
- <p class="ui-meganav-media-copy">Deliver native notifications at scale with our unified API.</p>
26
+ <%= link_to abs_url("/examples/emoji-reactions"), class: "ui-meganav-media group" do %>
27
+ <p class="ui-meganav-media-heading">Emoji Reactions</p>
28
+ <p class="ui-meganav-media-copy">React with an emoji to a message.</p>
29
29
  <% end %>
30
30
  </li>
31
31
  <li>
32
- <%= link_to abs_url("/integrations"), class: "ui-meganav-media group" do %>
33
- <p class="ui-meganav-media-heading">Third-party integrations</p>
34
- <p class="ui-meganav-media-copy">Integrate and extend Ably with cloud services like AWS Kinesis.</p>
32
+ <%= link_to abs_url("/examples/activity-feed"), class: "ui-meganav-media group" do %>
33
+ <p class="ui-meganav-media-heading">Activity Feed</p>
34
+ <p class="ui-meganav-media-copy">Display a list of user actions in realtime.</p>
35
35
  <% end %>
36
36
  </li>
37
37
  <li>
38
- <%= link_to abs_url("/protocols"), class: "ui-meganav-media group" do %>
39
- <p class="ui-meganav-media-heading">Multi-protocol messaging</p>
40
- <p class="ui-meganav-media-copy">We support pub/sub over WebSockets, MQTT, SSE, and more.</p>
38
+ <%= link_to abs_url("/examples/live-charts"), class: "ui-meganav-media group" do %>
39
+ <p class="ui-meganav-media-heading">Live Charts</p>
40
+ <p class="ui-meganav-media-copy">Visualise live metrics and data in a chart.</p>
41
41
  <% end %>
42
42
  </li>
43
43
  <li>
44
- <%= link_to abs_url("/hub"), class: "ui-meganav-media group" do %>
45
- <p class="ui-meganav-media-heading">Streaming data sources</p>
46
- <p class="ui-meganav-media-copy">Augment your apps with realtime updates like weather or transit.</p>
44
+ <%= link_to abs_url("/examples/live-cursors"), class: "ui-meganav-media group" do %>
45
+ <p class="ui-meganav-media-heading">Live Cursors</p>
46
+ <p class="ui-meganav-media-copy">Track all cursors in realtime.</p>
47
+ <% end %>
48
+ </li>
49
+ <li>
50
+ <%= link_to abs_url("/examples/typing-indicator"), class: "ui-meganav-media group" do %>
51
+ <p class="ui-meganav-media-heading">Typing Indicator</p>
52
+ <p class="ui-meganav-media-copy">See when a user is typing a message.</p>
47
53
  <% end %>
48
54
  </li>
49
55
  </ul>
50
56
 
51
- <%= render(AblyUi::Core::FeaturedLink.new(url: abs_url("/platform"))) do %>Explore all platform features<% end %>
57
+ <%= render(AblyUi::Core::FeaturedLink.new(url: abs_url("/examples"))) do %>Explore all live examples<% end %>
52
58
  </div>
53
59
 
54
60
  <div>
@@ -1 +1 @@
1
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.AblyUi=t():(e.AblyUi=e.AblyUi||{},e.AblyUi.Core=e.AblyUi.Core||{},e.AblyUi.Core.MeganavControl=t())}(this,(function(){return(()=>{"use strict";var e={9581:(e,t,r)=>{r.d(t,{n:()=>n});var n=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;return t.querySelectorAll("[data-id=".concat(e,"]"))}}},t={};function r(n){var i=t[n];if(void 0!==i)return i.exports;var o=t[n]={exports:{}};return e[n](o,o.exports,r),o.exports}r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var n={};return(()=>{r.d(n,{default:()=>i});var e=r(9581);function t(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}const i=function(){var r=Array.from((0,e.n)("meganav-control")),n=Array.from((0,e.n)("meganav-panel")),i=getComputedStyle(document.documentElement).getPropertyValue("--bp-md"),o=function(e,n,o){if(window.matchMedia("(hover: hover) and (pointer: fine) and (min-width: ".concat(i,")")).matches&&!r.some((function(e){return e===document.activeElement}))){var a,u=["invisible","visible"];(a=n.classList).replace.apply(a,function(e){if(Array.isArray(e))return t(e)}(c=o?u:u.reverse())||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(c)||function(e,r){if(e){if("string"==typeof e)return t(e,r);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?t(e,r):void 0}}(c)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),e.setAttribute("aria-expanded",o)}var c};return r.map((function(e){var t=e.parentNode,i=document.querySelector("#".concat(e.getAttribute("aria-controls"))),a=function(e,t){return function(){r.forEach((function(t){return t!==e&&t.setAttribute("aria-expanded",!1)})),n.forEach((function(e){return e!==t&&e.classList.replace("visible","invisible")})),e.getAttribute("aria-expanded")?(e.setAttribute("aria-expanded",!0),t.classList.replace("invisible","visible")):(e.setAttribute("aria-expanded",!1),t.classList.replace("visible","invisible"))}}(e,i),u=function(e,t){return function(){return o(e,t,!0)}}(e,i),c=function(e,t){return function(){return o(e,t,!1)}}(e,i);return t.addEventListener("mouseenter",u),t.addEventListener("mouseleave",c),e.addEventListener("click",a),[{teardown:function(){t.removeEventListener("mouseenter",u),t.removeEventListener("mouseleave",c),e.removeEventListener("click",a)},clear:function(){e.setAttribute("aria-expanded",!1),i.classList.replace("visible","invisible")}}]})).flat()}})(),n.default})()}));
1
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.AblyUi=t():(e.AblyUi=e.AblyUi||{},e.AblyUi.Core=e.AblyUi.Core||{},e.AblyUi.Core.MeganavControl=t())}(this,(function(){return(()=>{"use strict";var e={9581:(e,t,r)=>{r.d(t,{A:()=>n,n:()=>i});var n=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;return t.querySelector("[data-id=".concat(e,"]"))},i=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;return t.querySelectorAll("[data-id=".concat(e,"]"))}}},t={};function r(n){var i=t[n];if(void 0!==i)return i.exports;var o=t[n]={exports:{}};return e[n](o,o.exports,r),o.exports}r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var n={};return(()=>{r.d(n,{default:()=>i});var e=r(9581);function t(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}const i=function(){var r=Array.from((0,e.n)("meganav-control")),n=Array.from((0,e.n)("meganav-panel")),i=getComputedStyle(document.documentElement).getPropertyValue("--bp-md"),o=function(e){return"search"===e.dataset.control},a=function(e,n,o){if(window.matchMedia("(hover: hover) and (pointer: fine) and (min-width: ".concat(i,")")).matches&&!r.some((function(e){return e===document.activeElement}))&&!function(){var e=document.querySelector('[data-id="meganav-panel"]#panel-search');if(e)return!e.classList.contains("invisible")}()){var a,c=["invisible","visible"];(a=n.classList).replace.apply(a,function(e){if(Array.isArray(e))return t(e)}(u=o?c:c.reverse())||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(u)||function(e,r){if(e){if("string"==typeof e)return t(e,r);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?t(e,r):void 0}}(u)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),e.setAttribute("aria-expanded",o)}var u};return r.map((function(t){var i,c,u=t.parentNode,l=document.querySelector("#".concat(t.getAttribute("aria-controls"))),s=function(t,i){return function(){if(r.forEach((function(e){return e!==t&&e.setAttribute("aria-expanded",!1)})),n.forEach((function(e){return e!==i&&e.classList.replace("visible","invisible")})),"true"===t.getAttribute("aria-expanded")?(t.setAttribute("aria-expanded",!1),i.classList.replace("visible","invisible")):(t.setAttribute("aria-expanded",!0),i.classList.replace("invisible","visible")),o(t)){var a=(0,e.A)("meganav-search-input",i);if(!a)return;a.focus()}else t.focus()}}(t,l);return t.addEventListener("click",s),o(t)||(i=function(e,t){return function(){return a(e,t,!0)}}(t,l),c=function(e,t){return function(){return a(e,t,!1)}}(t,l),u.addEventListener("mouseenter",i),u.addEventListener("mouseleave",c)),[{teardown:function(){i&&c&&(u.removeEventListener("mouseenter",i),u.removeEventListener("mouseleave",c)),t.removeEventListener("click",s)},clear:function(){t.setAttribute("aria-expanded",!1),l.classList.replace("visible","invisible")}}]})).flat()}})(),n.default})()}));
@@ -1,6 +1,6 @@
1
1
  <%= button_tag(type: "button",
2
- class: ["ui-meganav-link", "h-64", "flex", "items-center", "group", theme(:text_color)],
2
+ class: ["ui-meganav-link", "h-64", "flex", "items-center", "group", theme(:text_color), additional_css],
3
3
  data: { id: "meganav-control" },
4
- aria: { expanded: false, controls: @aria_controls, label: "Show #{content}" }) do -%>
4
+ aria: { expanded: false, controls: aria_controls, label: "Show #{content}" }) do -%>
5
5
  <%= content -%><%= render(AblyUi::Core::Icon.new(name: "icon-gui-disclosure-arrow", size: "1.5rem", color: "text-cool-black", additional_css: "transform rotate-90 group-hover:text-gui-hover group-focus:text-gui-focus")) %>
6
6
  <% end %>
@@ -2,9 +2,11 @@ module AblyUi
2
2
  module Core
3
3
  class MeganavControl < ViewComponent::Base
4
4
  include AblyUi::Core::MeganavConfig
5
+ attr_reader :aria_controls, :additional_css
5
6
 
6
- def initialize(aria_controls:, theme_name:)
7
+ def initialize(aria_controls:, theme_name:, additional_css: '')
7
8
  @aria_controls = aria_controls
9
+ @additional_css = additional_css
8
10
  theme_setup(theme_name)
9
11
  end
10
12
  end
@@ -11,8 +11,36 @@
11
11
  <%= render(AblyUi::Core::MeganavControlMobileDropdown.new(theme_name: @theme_name)) %>
12
12
 
13
13
  <div class="ui-meganav-mobile-dropdown invisible" id="meganav-mobile-dropdown" data-id="meganav-mobile-dropdown">
14
- <div class="py-16 ui-grid-px bg-white">
15
- <ul class="mb-16">
14
+ <div class="pt-24 pb-16 ui-grid-px bg-white">
15
+ <%= tag.form class: "mb-16", action: abs_url("/search"), method: "get" do %>
16
+ <div class="relative w-full">
17
+ <%= render(AblyUi::Core::Icon.new(name: "icon-gui-search", size: "1.5rem", color: "text-cool-black", additional_css: "absolute top-12 left-16 hover:text-gui-hover")) %>
18
+ <button
19
+ type="button"
20
+ class="absolute top-12 right-16 p-0 focus:outline-gui-focus m-0 md:hidden invisible"
21
+ data-id="meganav-search-input-clear"
22
+ >
23
+ <%= render(AblyUi::Core::Icon.new(name: "icon-gui-cross-circled-fill", size: "1.5rem", color: "text-dark-grey")) %>
24
+ </button>
25
+ <input
26
+ type="search"
27
+ name="q"
28
+ class="ui-input px-48 h-48"
29
+ style={{ maxWidth: "none" }}
30
+ placeholder="Search"
31
+ autocomplete="off"
32
+ data-id="meganav-mobile-search-input"
33
+ />
34
+
35
+ <%= render(AblyUi::Core::MeganavSearchAutocomplete.new) %>
36
+ </div>
37
+ <% end %>
38
+
39
+ <div class="max-h-0 overflow-hidden transition-all" data-id="meganav-mobile-search-suggestions">
40
+ <%= render(AblyUi::Core::MeganavSearchSuggestions.new(url_base: url_base, display_support_link: false)) %>
41
+ </div>
42
+
43
+ <ul class="mb-16" data-id="meganav-mobile-panel-controls">
16
44
  <% panels.each do |panel| %>
17
45
  <li class="ui-meganav-mobile-item">
18
46
  <%= render(AblyUi::Core::MeganavControlMobilePanelOpen.new(aria_controls: "#{panel[:id]}-mobile")) do %>
@@ -1,6 +1,6 @@
1
1
  <ul class="hidden md:flex items-center">
2
2
  <li class="ui-meganav-item relative">
3
- <%= render(AblyUi::Core::MeganavControl.new(aria_controls: "account-panel", theme_name: @theme_name)) do %>
3
+ <%= render(AblyUi::Core::MeganavControl.new(aria_controls: "account-panel", theme_name: @theme_name, additional_css: "mr-0")) do %>
4
4
  <%= account_name %>
5
5
  <% end %>
6
6
 
@@ -41,8 +41,12 @@
41
41
  </div>
42
42
  </li>
43
43
 
44
+ <li>
45
+ <%= render(AblyUi::Core::MeganavSearch.new(url_base: url_base)) %>
46
+ </li>
47
+
44
48
  <% if account? %>
45
- <li class="ml-16">
49
+ <li>
46
50
  <%= link_to "Dashboard", @session_data[:account][:links][:dashboard][:href], class: "ui-btn-secondary p-btn-small" %>
47
51
  </li>
48
52
  <% end %>
@@ -0,0 +1 @@
1
+ !function(e,o){"object"==typeof exports&&"object"==typeof module?module.exports=o():"function"==typeof define&&define.amd?define([],o):"object"==typeof exports?exports.AblyUi=o():(e.AblyUi=e.AblyUi||{},e.AblyUi.Core=e.AblyUi.Core||{},e.AblyUi.Core.MeganavSearch=o())}(this,(function(){return{}.default}));
@@ -0,0 +1,15 @@
1
+ <button
2
+ type="button"
3
+ data-id="meganav-control"
4
+ data-control="search"
5
+ class="h-64 w-24 px-24 pr-48 py-20 group focus:outline-none"
6
+ aria-expanded="false"
7
+ aria-controls="panel-search"
8
+ aria-label="Show Search Panel"
9
+ >
10
+ <%= render(AblyUi::Core::Icon.new(name: "icon-gui-search", size: "1.5rem", color: "text-cool-black", additional_css: "group-hover:text-gui-hover group-focus:text-gui-focus")) %>
11
+ </button>
12
+
13
+ <div class="ui-meganav-panel invisible" id="panel-search" data-id="meganav-panel">
14
+ <%= render(AblyUi::Core::MeganavSearchPanel.new(url_base: url_base)) %>
15
+ </div>
@@ -0,0 +1,13 @@
1
+ module AblyUi
2
+ module Core
3
+ class MeganavSearch < ViewComponent::Base
4
+ include Util
5
+
6
+ attr_reader :url_base
7
+
8
+ def initialize(url_base:)
9
+ @url_base = url_base
10
+ end
11
+ end
12
+ end
13
+ end
@@ -0,0 +1,2 @@
1
+ /*! For license information please see component.js.LICENSE.txt */
2
+ !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.AblyUi=e():(t.AblyUi=t.AblyUi||{},t.AblyUi.Core=t.AblyUi.Core||{},t.AblyUi.Core.MeganavSearchAutocomplete=e())}(this,(function(){return(()=>{var t={727:(t,e,n)=>{"use strict";t.exports=n(5647)},493:(t,e,n)=>{"use strict";n(2702).polyfill();const s=n(9669).default;var i=function(t,e,n,r,o,a,c){var u=function(t,e){return t||!1===t?"&"+e+"="+t:""};if("search"===n||"suggest"===n||"autocomplete"===n){var l="",f="",h=null;if("search"===n){h=n,l=r.keyword,l=r.enableLogicalOperators?l.replace(/ and /g," AND ").replace(/ or /g," OR ").replace(/ not /g," NOT "):l.replace(/ AND /g," and ").replace(/ OR /g," or ").replace(/ NOT /g," not "),l=encodeURIComponent(l);var d=r.fuzzy;if("retry"===d&&(d=!0===a),"search"===n){if(f=u(r.lang,"lang")+u(d,"fuzzy")+u(r.collectAnalytics,"collectAnalytics")+u(r.postfixWildcard,"postfixWildcard")+u(r.categories,"categories")+u(r.priceFromCents,"priceFromCents")+u(r.priceToCents,"priceToCents")+u(r.dateFrom,"dateFrom")+u(r.dateTo,"dateTo")+u(r.paging.page,"page")+u(r.paging.pageSize,"limit")+u(r.paging.sortBy,"sort")+u(r.paging.sortOrder,"order")+u(r.shuffleAndLimitTo,"shuffleAndLimitTo")+u(r.jwt,"jwt")+u(r.resultType,"resultType")+u(r.userToken,"userToken")+u(r.numFacets,"numFacets")+u(r.cacheResponseTime,"cacheResponseWithTtlSeconds")+u(r.searchOperator,"defaultOperator")+u(r.analyticsTag,"analyticsTag")+u(r.hierarchicalFacetSetting,"hierarchicalFacets"),r.customFieldFilters)for(var p=0;p<r.customFieldFilters.length;p++)f=f+"&customField="+r.customFieldFilters[p];if(r.facetFields)for(p=0;p<r.facetFields.length;p++)f=f+"&facet="+r.facetFields[p];if(r.rangeFacets&&(f=f+"&rangeFacets="+JSON.stringify(r.rangeFacets)),r.statsFields)for(p=0;p<r.statsFields.length;p++)f=f+"&fieldStat="+r.statsFields[p];if(r.personalizationEvents&&Array.isArray(r.personalizationEvents))for(p=0;p<r.personalizationEvents.length;p++){var g=r.personalizationEvents[p],m=Object.keys(g);f=f+"&personalizationEvent="+encodeURIComponent(m+"="+g[m])}c?f=f+"&filter="+encodeURIComponent(JSON.stringify(c)):r.filterObject&&(f=f+"&filter="+encodeURIComponent(JSON.stringify(r.filterObject)))}}else"suggest"===n?(h=n,f=u(r.suggestionsSize,"size")+u(r.lang,"lang"),l=r.suggestionsPrefix):"autocomplete"===n&&(h="autocomplete/document-field",f=u(r.autocomplete.field,"source")+u(r.autocomplete.size,"size"),l=r.autocomplete.prefix);s.get("https://"+t+"/v1/"+h+"/"+e+"?term="+l+f).then((function(s){var c=s.data;if("search"===n&&"retry"===r.fuzzy&&0===c.total_hits&&!0!==a)i(t,e,n,r,o,!0);else{if(!0===a){var u=r.paging.pageSize;c.total_hits>=u&&(c.total_hits=u)}o(c)}})).catch((function(t){console.log(t),o({error:{response:500,message:"invalid server response"}})}))}else o({error:{response:400,message:"invalid query type"}})};t.exports=i},5647:(t,e,n)=>{"use strict";var s=n(493),i=n(9610),r=n(3716),o=n(7585),a=n(5159),c=n(4508);t.exports=function(t,e){this.sitekey=t,this.privatekey=e,this.apiHostname="api.addsearch.com",this.settings=new o,this.sessionId=("a-"+1e8*Math.random()).substring(0,10),this.search=function(t,e){var n=null,i=null;if(t&&a.isFunction(e))n=t,i=e;else if(!e&&a.isFunction(t))n=this.settings.getSettings().keyword,i=t;else{if(!this.settings.getSettings().callback)throw"Illegal search parameters. Should be (keyword, callbackFunction) or (callbackFunction)";n=this.settings.getSettings().keyword,i=this.settings.getSettings().callback}this.settings.setCallback(i),this.settings.setKeyword(n),this.throttledSearchFetch||(this.throttledSearchFetch=c(this.settings.getSettings().throttleTimeMs,s)),this.throttledSearchFetch(this.apiHostname,this.sitekey,"search",this.settings.getSettings(),i)},this.suggestions=function(t,e){if(!t||!e||!a.isFunction(e))throw"Illegal suggestions parameters. Should be (prefix, callbackFunction)";this.settings.setSuggestionsPrefix(t),this.throttledSuggestionsFetch||(this.throttledSuggestionsFetch=c(this.settings.getSettings().throttleTimeMs,s)),this.throttledSuggestionsFetch(this.apiHostname,this.sitekey,"suggest",this.settings.getSettings(),e)},this.autocomplete=function(t,e,n){if(!(t&&e&&n&&a.isFunction(n)))throw"Illegal autocomplete parameters. Should be (field, prefix, callbackFunction)";this.settings.setAutocompleteParams(t,e),this.throttledAutocompleteFetch||(this.throttledAutocompleteFetch=c(this.settings.getSettings().throttleTimeMs,s)),this.throttledAutocompleteFetch(this.apiHostname,this.sitekey,"autocomplete",this.settings.getSettings(),n)},this.fetchCustomApi=function(t,e,n){var i=Object.assign({},this.settings.getSettings());i.facetFields=i.facetFields.filter((e=>t===e)),s(this.apiHostname,this.sitekey,"search",i,n,null,e)},this.fetchRangeFacets=function(t,e,n){var i=Object.assign({},this.settings.getSettings());i.rangeFacets||(i.rangeFacets=[]),i.rangeFacets.push({field:t.field,ranges:t.ranges}),s(this.apiHostname,this.sitekey,"search",i,n,null,e)},this.getDocument=function(t){return i.getDocument(this.apiHostname,this.sitekey,this.privatekey,t)},this.saveDocument=function(t){return i.saveDocument(this.apiHostname,this.sitekey,this.privatekey,t)},this.saveDocumentsBatch=function(t){if(!t||!t.documents||!Array.isArray(t.documents))throw"Please provide an array of documents: {documents: []}";return i.saveDocumentsBatch(this.apiHostname,this.sitekey,this.privatekey,t)},this.deleteDocument=function(t){return i.deleteDocument(this.apiHostname,this.sitekey,this.privatekey,t)},this.deleteDocumentsBatch=function(t){if(!t||!t.documents||!Array.isArray(t.documents))throw"Please provide an array of document ids: {documents: []}";return i.deleteDocumentsBatch(this.apiHostname,this.sitekey,this.privatekey,t)},this.setApiHostname=function(t){this.apiHostname=t},this.getSettings=function(){return this.settings.getSettings()},this.setLanguage=function(t){this.settings.setLanguage(t)},this.setCategoryFilters=function(t){this.settings.setCategoryFilters(t)},this.addCustomFieldFilter=function(t,e){this.settings.addCustomFieldFilter(t,e)},this.removeCustomFieldFilter=function(t,e){this.settings.removeCustomFieldFilter(t,e)},this.setPriceRangeFilter=function(t,e){this.settings.setPriceRangeFilter(t,e)},this.setDateFilter=function(t,e){this.settings.setDateFilter(t,e)},this.setJWT=function(t){this.settings.setJWT(t)},this.setUserToken=function(t){this.settings.setUserToken(t)},this.setPaging=function(t,e,n,s){this.settings.setPaging(t,e,n,s)},this.nextPage=function(){this.settings.nextPage()},this.previousPage=function(){this.settings.previousPage()},this.setSuggestionsSize=function(t){this.settings.setSuggestionsSize(t)},this.setAutocompleteSize=function(t){this.settings.setAutocompleteSize(t)},this.addFacetField=function(t){this.settings.addFacetField(t)},this.addHierarchicalFacetSetting=function(t){this.settings.addHierarchicalFacetSetting(t)},this.addRangeFacet=function(t,e){this.settings.addRangeFacet(t,e)},this.addStatsField=function(t){this.settings.addStatsField(t)},this.setNumberOfFacets=function(t){this.settings.setNumberOfFacets(t)},this.setResultType=function(t){this.settings.setResultType(t)},this.setPersonalizationEvents=function(t){this.settings.setPersonalizationEvents(t)},this.setFilterObject=function(t){this.settings.setFilterObject(t)},this.setShuffleAndLimitTo=function(t){this.settings.setShuffleAndLimitTo(t)},this.setFuzzyMatch=function(t){this.settings.setFuzzyMatch(t)},this.setPostfixWildcard=function(t){this.settings.setPostfixWildcard(t)},this.setCacheResponseTime=function(t){this.settings.setCacheResponseTime(t)},this.setCollectAnalytics=function(t){this.settings.setCollectAnalytics(t)},this.setAnalyticsTag=function(t){this.settings.setAnalyticsTag(t)},this.setThrottleTime=function(t){this.settings.setThrottleTime(t)},this.setStatsSessionId=function(t){this.sessionId=t},this.getStatsSessionId=function(){return this.sessionId},this.enableLogicalOperators=function(t){this.settings.enableLogicalOperators(t)},this.setSearchOperator=function(t){this.settings.setSearchOperator(t)},this.sendStatsEvent=function(t,e,n){if("search"===t){var s={action:"search",session:this.sessionId,keyword:e,numberOfResults:n.numberOfResults,analyticsTag:this.getSettings().analyticsTag};r(this.apiHostname,this.sitekey,s)}else{if("click"!==t)throw"Illegal sendStatsEvent type parameters. Should be search or click)";s={action:"click",session:this.sessionId,keyword:e,docid:n.documentId,position:n.position,analyticsTag:this.getSettings().analyticsTag},r(this.apiHostname,this.sitekey,s)}},this.searchResultClicked=function(t,e){this.sendStatsEvent("click",this.settings.getSettings().keyword,{documentId:t,position:e})}}},9610:(t,e,n)=>{"use strict";const s=n(5159),i=n(2702).Promise,r=n(9669).default,o=function(t,e){return{Authorization:"Basic "+s.base64(t+":"+e),"Content-Type":"application/json"}};t.exports={getDocument:function(t,e,n,s){return new i(((i,a)=>{r.get("https://"+t+"/v2/indices/"+e+"/documents/"+s,{headers:o(e,n)}).then((t=>{200==t.status?i(t.data):a({status:t.status,text:t.statusText})})).catch((t=>{a({status:400,text:t})}))}))},saveDocument:function(t,e,n,s){const a=s.id||s.url;return new i(((i,c)=>{r({url:"https://"+t+"/v2/indices/"+e+"/documents/",method:a?"put":"post",headers:o(e,n),data:s}).then((t=>{202==t.status?i({status:t.status,text:t.statusText}):c({status:t.status,text:t.statusText})})).catch((t=>{c({status:400,text:t})}))}))},saveDocumentsBatch:function(t,e,n,s){return new i(((i,a)=>{r({method:"put",url:"https://"+t+"/v2/indices/"+e+"/documents:batch",headers:o(e,n),data:s}).then((t=>{202==t.status?i({status:t.status,text:t.statusText}):a({status:t.status,text:t.statusText})})).catch((t=>{a({status:400,text:t})}))}))},deleteDocument:function(t,e,n,s){return new i(((i,a)=>{r.delete("https://"+t+"/v2/indices/"+e+"/documents/"+s,{headers:o(e,n)}).then((t=>{202==t.status?i({status:t.status,text:t.statusText}):a({status:t.status,text:t.statusText})})).catch((t=>{a({status:400,text:t})}))}))},deleteDocumentsBatch:function(t,e,n,s){return new i(((i,a)=>{r.delete("https://"+t+"/v2/indices/"+e+"/documents:batch",{headers:o(e,n),data:s}).then((t=>{202==t.status?i({status:t.status,text:t.statusText}):a({status:t.status,text:t.statusText})})).catch((t=>{a({status:400,text:t})}))}))}}},7585:t=>{"use strict";t.exports=function(){this.settings={keyword:"*",callback:null,throttleTimeMs:200,fuzzy:"auto",paging:{page:1,pageSize:10,sortBy:"relevance",sortOrder:"desc"},customFieldFilters:[],userToken:null,suggestionsSize:10,facetFields:[],autocomplete:{size:10},searchOperator:null,enableLogicalOperators:!1,cacheResponseTime:null},this.getSettings=function(){return this.settings},this.setKeyword=function(t){this.settings.keyword=t||"*"},this.setCallback=function(t){this.settings.callback=t},this.setThrottleTime=function(t){this.settings.throttleTimeMs=t},this.setSuggestionsPrefix=function(t){this.settings.suggestionsPrefix=t},this.setSuggestionsSize=function(t){this.settings.suggestionsSize=t},this.setAutocompleteSize=function(t){this.settings.autocomplete.size=t},this.setAutocompleteParams=function(t,e){this.settings.autocomplete.field=t,this.settings.autocomplete.prefix=e},this.setLanguage=function(t){if(t&&2!==t.length)throw'use 2-char language code (e.g. "en")';this.settings.lang=t},this.setFuzzyMatch=function(t){if(!0!==t&&!1!==t&&"auto"!==t&&"retry"!==t)throw"fuzzy matching can be true, false, 'auto', or 'retry'";this.settings.fuzzy=t},this.enableLogicalOperators=function(t){this.settings.enableLogicalOperators=t},this.setCacheResponseTime=function(t){this.settings.cacheResponseTime=t},this.setPostfixWildcard=function(t){this.settings.postfixWildcard=t},this.setCollectAnalytics=function(t){this.settings.collectAnalytics=t},this.setAnalyticsTag=function(t){this.settings.analyticsTag=t},this.setCategoryFilters=function(t){this.settings.categories=t},this.setFilterObject=function(t){this.settings.filterObject=t},this.setPriceRangeFilter=function(t,e){this.settings.priceFromCents=t,this.settings.priceToCents=e},this.addCustomFieldFilter=function(t,e){var n=encodeURIComponent(t+"="+e);-1===this.settings.customFieldFilters.indexOf(n)&&this.settings.customFieldFilters.push(n)},this.removeCustomFieldFilter=function(t,e){var n=!1,s=encodeURIComponent(t+"="+e);e||(n=!0,s=encodeURIComponent(t+"="));for(var i=this.settings.customFieldFilters.length;i>0;i--){var r=this.settings.customFieldFilters[i-1];(n&&0===r.indexOf(s)||r===s)&&this.settings.customFieldFilters.splice(i-1,1)}},this.setDateFilter=function(t,e){this.settings.dateFrom=t,this.settings.dateTo=e},this.setKeyword=function(t){this.settings.keyword=t||"*"},this.setJWT=function(t){this.settings.jwt=t},this.setUserToken=function(t){this.settings.userToken=t},this.setPersonalizationEvents=function(t){this.settings.personalizationEvents=t},this.setResultType=function(t){this.settings.resultType=t},this.addFacetField=function(t){-1===this.settings.facetFields.indexOf(t)&&this.settings.facetFields.push(t)},this.addHierarchicalFacetSetting=function(t){this.settings.hierarchicalFacetSetting=JSON.stringify(t)},this.addRangeFacet=function(t,e){this.settings.rangeFacets||(this.settings.rangeFacets=[]),this.settings.rangeFacets.push({field:t,ranges:e})},this.addStatsField=function(t){this.settings.statsFields||(this.settings.statsFields=[]),-1===this.settings.statsFields.indexOf(t)&&this.settings.statsFields.push(t)},this.setNumberOfFacets=function(t){this.settings.numFacets=t},this.setPaging=function(t,e,n,s){if(t<1)throw"page must be 1 or bigger";if(e<1||e>300)throw"pageSize must be 1-300";if("asc"!==s&&"desc"!==s)throw"sortOrder must be asc or desc";this.settings.paging.page=t,this.settings.paging.pageSize=e,this.settings.paging.sortBy=n,this.settings.paging.sortOrder=s},this.setShuffleAndLimitTo=function(t){this.settings.shuffleAndLimitTo=t},this.nextPage=function(){this.settings.paging.page=this.settings.paging.page+1},this.previousPage=function(){this.settings.paging.page>0&&(this.settings.paging.page=this.settings.paging.page-1)},this.setSearchOperator=function(t){if("and"!==t&&"or"!==t)throw"operator must be 'and' || 'or'";this.settings.searchOperator=t}}},3716:(t,e,n)=>{"use strict";n(2702).polyfill();const s=n(9669).default;t.exports=function(t,e,n){"undefined"!=typeof window&&window.navigator&&window.navigator.sendBeacon?navigator.sendBeacon("https://"+t+"/v1/stats/"+e+"/",JSON.stringify(n)):s.post("https://"+t+"/v1/stats/"+e+"/",n,{headers:{"Content-Type":"text/plain"}})}},4508:t=>{t.exports=function(t,e){var n,s=0;function i(){n&&clearTimeout(n)}return function(){var r=this,o=Date.now()-s,a=arguments;function c(){s=Date.now(),e.apply(r,a)}i(),o>t?c():n=setTimeout(c,t-o)}}},5159:(t,e,n)=>{t.exports={isFunction:function(t){return t&&"[object Function]"==={}.toString.call(t)},base64:function(t){return n.g.window={},window&&window.btoa?window.btoa(t):Buffer?Buffer.from(t).toString("base64"):void 0}}},9669:(t,e,n)=>{t.exports=n(1609)},5448:(t,e,n)=>{"use strict";var s=n(4867),i=n(6026),r=n(4372),o=n(5327),a=n(4097),c=n(4109),u=n(7985),l=n(7874),f=n(2648),h=n(644),d=n(205);t.exports=function(t){return new Promise((function(e,n){var p,g=t.data,m=t.headers,v=t.responseType;function y(){t.cancelToken&&t.cancelToken.unsubscribe(p),t.signal&&t.signal.removeEventListener("abort",p)}s.isFormData(g)&&s.isStandardBrowserEnv()&&delete m["Content-Type"];var b=new XMLHttpRequest;if(t.auth){var w=t.auth.username||"",S=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";m.Authorization="Basic "+btoa(w+":"+S)}var x=a(t.baseURL,t.url);function F(){if(b){var s="getAllResponseHeaders"in b?c(b.getAllResponseHeaders()):null,r={data:v&&"text"!==v&&"json"!==v?b.response:b.responseText,status:b.status,statusText:b.statusText,headers:s,config:t,request:b};i((function(t){e(t),y()}),(function(t){n(t),y()}),r),b=null}}if(b.open(t.method.toUpperCase(),o(x,t.params,t.paramsSerializer),!0),b.timeout=t.timeout,"onloadend"in b?b.onloadend=F:b.onreadystatechange=function(){b&&4===b.readyState&&(0!==b.status||b.responseURL&&0===b.responseURL.indexOf("file:"))&&setTimeout(F)},b.onabort=function(){b&&(n(new f("Request aborted",f.ECONNABORTED,t,b)),b=null)},b.onerror=function(){n(new f("Network Error",f.ERR_NETWORK,t,b,b)),b=null},b.ontimeout=function(){var e=t.timeout?"timeout of "+t.timeout+"ms exceeded":"timeout exceeded",s=t.transitional||l;t.timeoutErrorMessage&&(e=t.timeoutErrorMessage),n(new f(e,s.clarifyTimeoutError?f.ETIMEDOUT:f.ECONNABORTED,t,b)),b=null},s.isStandardBrowserEnv()){var E=(t.withCredentials||u(x))&&t.xsrfCookieName?r.read(t.xsrfCookieName):void 0;E&&(m[t.xsrfHeaderName]=E)}"setRequestHeader"in b&&s.forEach(m,(function(t,e){void 0===g&&"content-type"===e.toLowerCase()?delete m[e]:b.setRequestHeader(e,t)})),s.isUndefined(t.withCredentials)||(b.withCredentials=!!t.withCredentials),v&&"json"!==v&&(b.responseType=t.responseType),"function"==typeof t.onDownloadProgress&&b.addEventListener("progress",t.onDownloadProgress),"function"==typeof t.onUploadProgress&&b.upload&&b.upload.addEventListener("progress",t.onUploadProgress),(t.cancelToken||t.signal)&&(p=function(t){b&&(n(!t||t&&t.type?new h:t),b.abort(),b=null)},t.cancelToken&&t.cancelToken.subscribe(p),t.signal&&(t.signal.aborted?p():t.signal.addEventListener("abort",p))),g||(g=null);var A=d(x);A&&-1===["http","https","file"].indexOf(A)?n(new f("Unsupported protocol "+A+":",f.ERR_BAD_REQUEST,t)):b.send(g)}))}},1609:(t,e,n)=>{"use strict";var s=n(4867),i=n(1849),r=n(321),o=n(7185),a=function t(e){var n=new r(e),a=i(r.prototype.request,n);return s.extend(a,r.prototype,n),s.extend(a,n),a.create=function(n){return t(o(e,n))},a}(n(5546));a.Axios=r,a.CanceledError=n(644),a.CancelToken=n(4972),a.isCancel=n(6502),a.VERSION=n(7288).version,a.toFormData=n(7675),a.AxiosError=n(2648),a.Cancel=a.CanceledError,a.all=function(t){return Promise.all(t)},a.spread=n(8713),a.isAxiosError=n(6268),t.exports=a,t.exports.default=a},4972:(t,e,n)=>{"use strict";var s=n(644);function i(t){if("function"!=typeof t)throw new TypeError("executor must be a function.");var e;this.promise=new Promise((function(t){e=t}));var n=this;this.promise.then((function(t){if(n._listeners){var e,s=n._listeners.length;for(e=0;e<s;e++)n._listeners[e](t);n._listeners=null}})),this.promise.then=function(t){var e,s=new Promise((function(t){n.subscribe(t),e=t})).then(t);return s.cancel=function(){n.unsubscribe(e)},s},t((function(t){n.reason||(n.reason=new s(t),e(n.reason))}))}i.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},i.prototype.subscribe=function(t){this.reason?t(this.reason):this._listeners?this._listeners.push(t):this._listeners=[t]},i.prototype.unsubscribe=function(t){if(this._listeners){var e=this._listeners.indexOf(t);-1!==e&&this._listeners.splice(e,1)}},i.source=function(){var t;return{token:new i((function(e){t=e})),cancel:t}},t.exports=i},644:(t,e,n)=>{"use strict";var s=n(2648);function i(t){s.call(this,null==t?"canceled":t,s.ERR_CANCELED),this.name="CanceledError"}n(4867).inherits(i,s,{__CANCEL__:!0}),t.exports=i},6502:t=>{"use strict";t.exports=function(t){return!(!t||!t.__CANCEL__)}},321:(t,e,n)=>{"use strict";var s=n(4867),i=n(5327),r=n(782),o=n(3572),a=n(7185),c=n(4097),u=n(4875),l=u.validators;function f(t){this.defaults=t,this.interceptors={request:new r,response:new r}}f.prototype.request=function(t,e){"string"==typeof t?(e=e||{}).url=t:e=t||{},(e=a(this.defaults,e)).method?e.method=e.method.toLowerCase():this.defaults.method?e.method=this.defaults.method.toLowerCase():e.method="get";var n=e.transitional;void 0!==n&&u.assertOptions(n,{silentJSONParsing:l.transitional(l.boolean),forcedJSONParsing:l.transitional(l.boolean),clarifyTimeoutError:l.transitional(l.boolean)},!1);var s=[],i=!0;this.interceptors.request.forEach((function(t){"function"==typeof t.runWhen&&!1===t.runWhen(e)||(i=i&&t.synchronous,s.unshift(t.fulfilled,t.rejected))}));var r,c=[];if(this.interceptors.response.forEach((function(t){c.push(t.fulfilled,t.rejected)})),!i){var f=[o,void 0];for(Array.prototype.unshift.apply(f,s),f=f.concat(c),r=Promise.resolve(e);f.length;)r=r.then(f.shift(),f.shift());return r}for(var h=e;s.length;){var d=s.shift(),p=s.shift();try{h=d(h)}catch(t){p(t);break}}try{r=o(h)}catch(t){return Promise.reject(t)}for(;c.length;)r=r.then(c.shift(),c.shift());return r},f.prototype.getUri=function(t){t=a(this.defaults,t);var e=c(t.baseURL,t.url);return i(e,t.params,t.paramsSerializer)},s.forEach(["delete","get","head","options"],(function(t){f.prototype[t]=function(e,n){return this.request(a(n||{},{method:t,url:e,data:(n||{}).data}))}})),s.forEach(["post","put","patch"],(function(t){function e(e){return function(n,s,i){return this.request(a(i||{},{method:t,headers:e?{"Content-Type":"multipart/form-data"}:{},url:n,data:s}))}}f.prototype[t]=e(),f.prototype[t+"Form"]=e(!0)})),t.exports=f},2648:(t,e,n)=>{"use strict";var s=n(4867);function i(t,e,n,s,i){Error.call(this),this.message=t,this.name="AxiosError",e&&(this.code=e),n&&(this.config=n),s&&(this.request=s),i&&(this.response=i)}s.inherits(i,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code,status:this.response&&this.response.status?this.response.status:null}}});var r=i.prototype,o={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED"].forEach((function(t){o[t]={value:t}})),Object.defineProperties(i,o),Object.defineProperty(r,"isAxiosError",{value:!0}),i.from=function(t,e,n,o,a,c){var u=Object.create(r);return s.toFlatObject(t,u,(function(t){return t!==Error.prototype})),i.call(u,t.message,e,n,o,a),u.name=t.name,c&&Object.assign(u,c),u},t.exports=i},782:(t,e,n)=>{"use strict";var s=n(4867);function i(){this.handlers=[]}i.prototype.use=function(t,e,n){return this.handlers.push({fulfilled:t,rejected:e,synchronous:!!n&&n.synchronous,runWhen:n?n.runWhen:null}),this.handlers.length-1},i.prototype.eject=function(t){this.handlers[t]&&(this.handlers[t]=null)},i.prototype.forEach=function(t){s.forEach(this.handlers,(function(e){null!==e&&t(e)}))},t.exports=i},4097:(t,e,n)=>{"use strict";var s=n(1793),i=n(7303);t.exports=function(t,e){return t&&!s(e)?i(t,e):e}},3572:(t,e,n)=>{"use strict";var s=n(4867),i=n(8527),r=n(6502),o=n(5546),a=n(644);function c(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new a}t.exports=function(t){return c(t),t.headers=t.headers||{},t.data=i.call(t,t.data,t.headers,t.transformRequest),t.headers=s.merge(t.headers.common||{},t.headers[t.method]||{},t.headers),s.forEach(["delete","get","head","post","put","patch","common"],(function(e){delete t.headers[e]})),(t.adapter||o.adapter)(t).then((function(e){return c(t),e.data=i.call(t,e.data,e.headers,t.transformResponse),e}),(function(e){return r(e)||(c(t),e&&e.response&&(e.response.data=i.call(t,e.response.data,e.response.headers,t.transformResponse))),Promise.reject(e)}))}},7185:(t,e,n)=>{"use strict";var s=n(4867);t.exports=function(t,e){e=e||{};var n={};function i(t,e){return s.isPlainObject(t)&&s.isPlainObject(e)?s.merge(t,e):s.isPlainObject(e)?s.merge({},e):s.isArray(e)?e.slice():e}function r(n){return s.isUndefined(e[n])?s.isUndefined(t[n])?void 0:i(void 0,t[n]):i(t[n],e[n])}function o(t){if(!s.isUndefined(e[t]))return i(void 0,e[t])}function a(n){return s.isUndefined(e[n])?s.isUndefined(t[n])?void 0:i(void 0,t[n]):i(void 0,e[n])}function c(n){return n in e?i(t[n],e[n]):n in t?i(void 0,t[n]):void 0}var u={url:o,method:o,data:o,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:c};return s.forEach(Object.keys(t).concat(Object.keys(e)),(function(t){var e=u[t]||r,i=e(t);s.isUndefined(i)&&e!==c||(n[t]=i)})),n}},6026:(t,e,n)=>{"use strict";var s=n(2648);t.exports=function(t,e,n){var i=n.config.validateStatus;n.status&&i&&!i(n.status)?e(new s("Request failed with status code "+n.status,[s.ERR_BAD_REQUEST,s.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n)):t(n)}},8527:(t,e,n)=>{"use strict";var s=n(4867),i=n(5546);t.exports=function(t,e,n){var r=this||i;return s.forEach(n,(function(n){t=n.call(r,t,e)})),t}},5546:(t,e,n)=>{"use strict";var s=n(4867),i=n(6016),r=n(2648),o=n(7874),a=n(7675),c={"Content-Type":"application/x-www-form-urlencoded"};function u(t,e){!s.isUndefined(t)&&s.isUndefined(t["Content-Type"])&&(t["Content-Type"]=e)}var l,f={transitional:o,adapter:(("undefined"!=typeof XMLHttpRequest||"undefined"!=typeof process&&"[object process]"===Object.prototype.toString.call(process))&&(l=n(5448)),l),transformRequest:[function(t,e){if(i(e,"Accept"),i(e,"Content-Type"),s.isFormData(t)||s.isArrayBuffer(t)||s.isBuffer(t)||s.isStream(t)||s.isFile(t)||s.isBlob(t))return t;if(s.isArrayBufferView(t))return t.buffer;if(s.isURLSearchParams(t))return u(e,"application/x-www-form-urlencoded;charset=utf-8"),t.toString();var n,r=s.isObject(t),o=e&&e["Content-Type"];if((n=s.isFileList(t))||r&&"multipart/form-data"===o){var c=this.env&&this.env.FormData;return a(n?{"files[]":t}:t,c&&new c)}return r||"application/json"===o?(u(e,"application/json"),function(t,e,n){if(s.isString(t))try{return(0,JSON.parse)(t),s.trim(t)}catch(t){if("SyntaxError"!==t.name)throw t}return(0,JSON.stringify)(t)}(t)):t}],transformResponse:[function(t){var e=this.transitional||f.transitional,n=e&&e.silentJSONParsing,i=e&&e.forcedJSONParsing,o=!n&&"json"===this.responseType;if(o||i&&s.isString(t)&&t.length)try{return JSON.parse(t)}catch(t){if(o){if("SyntaxError"===t.name)throw r.from(t,r.ERR_BAD_RESPONSE,this,null,this.response);throw t}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:n(1623)},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};s.forEach(["delete","get","head"],(function(t){f.headers[t]={}})),s.forEach(["post","put","patch"],(function(t){f.headers[t]=s.merge(c)})),t.exports=f},7874:t=>{"use strict";t.exports={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1}},7288:t=>{t.exports={version:"0.27.2"}},1849:t=>{"use strict";t.exports=function(t,e){return function(){for(var n=new Array(arguments.length),s=0;s<n.length;s++)n[s]=arguments[s];return t.apply(e,n)}}},5327:(t,e,n)=>{"use strict";var s=n(4867);function i(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}t.exports=function(t,e,n){if(!e)return t;var r;if(n)r=n(e);else if(s.isURLSearchParams(e))r=e.toString();else{var o=[];s.forEach(e,(function(t,e){null!=t&&(s.isArray(t)?e+="[]":t=[t],s.forEach(t,(function(t){s.isDate(t)?t=t.toISOString():s.isObject(t)&&(t=JSON.stringify(t)),o.push(i(e)+"="+i(t))})))})),r=o.join("&")}if(r){var a=t.indexOf("#");-1!==a&&(t=t.slice(0,a)),t+=(-1===t.indexOf("?")?"?":"&")+r}return t}},7303:t=>{"use strict";t.exports=function(t,e){return e?t.replace(/\/+$/,"")+"/"+e.replace(/^\/+/,""):t}},4372:(t,e,n)=>{"use strict";var s=n(4867);t.exports=s.isStandardBrowserEnv()?{write:function(t,e,n,i,r,o){var a=[];a.push(t+"="+encodeURIComponent(e)),s.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),s.isString(i)&&a.push("path="+i),s.isString(r)&&a.push("domain="+r),!0===o&&a.push("secure"),document.cookie=a.join("; ")},read:function(t){var e=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove:function(t){this.write(t,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}}},1793:t=>{"use strict";t.exports=function(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}},6268:(t,e,n)=>{"use strict";var s=n(4867);t.exports=function(t){return s.isObject(t)&&!0===t.isAxiosError}},7985:(t,e,n)=>{"use strict";var s=n(4867);t.exports=s.isStandardBrowserEnv()?function(){var t,e=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");function i(t){var s=t;return e&&(n.setAttribute("href",s),s=n.href),n.setAttribute("href",s),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:"/"===n.pathname.charAt(0)?n.pathname:"/"+n.pathname}}return t=i(window.location.href),function(e){var n=s.isString(e)?i(e):e;return n.protocol===t.protocol&&n.host===t.host}}():function(){return!0}},6016:(t,e,n)=>{"use strict";var s=n(4867);t.exports=function(t,e){s.forEach(t,(function(n,s){s!==e&&s.toUpperCase()===e.toUpperCase()&&(t[e]=n,delete t[s])}))}},1623:t=>{t.exports=null},4109:(t,e,n)=>{"use strict";var s=n(4867),i=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];t.exports=function(t){var e,n,r,o={};return t?(s.forEach(t.split("\n"),(function(t){if(r=t.indexOf(":"),e=s.trim(t.substr(0,r)).toLowerCase(),n=s.trim(t.substr(r+1)),e){if(o[e]&&i.indexOf(e)>=0)return;o[e]="set-cookie"===e?(o[e]?o[e]:[]).concat([n]):o[e]?o[e]+", "+n:n}})),o):o}},205:t=>{"use strict";t.exports=function(t){var e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}},8713:t=>{"use strict";t.exports=function(t){return function(e){return t.apply(null,e)}}},7675:(t,e,n)=>{"use strict";var s=n(4867);t.exports=function(t,e){e=e||new FormData;var n=[];function i(t){return null===t?"":s.isDate(t)?t.toISOString():s.isArrayBuffer(t)||s.isTypedArray(t)?"function"==typeof Blob?new Blob([t]):Buffer.from(t):t}return function t(r,o){if(s.isPlainObject(r)||s.isArray(r)){if(-1!==n.indexOf(r))throw Error("Circular reference detected in "+o);n.push(r),s.forEach(r,(function(n,r){if(!s.isUndefined(n)){var a,c=o?o+"."+r:r;if(n&&!o&&"object"==typeof n)if(s.endsWith(r,"{}"))n=JSON.stringify(n);else if(s.endsWith(r,"[]")&&(a=s.toArray(n)))return void a.forEach((function(t){!s.isUndefined(t)&&e.append(c,i(t))}));t(n,c)}})),n.pop()}else e.append(o,i(r))}(t),e}},4875:(t,e,n)=>{"use strict";var s=n(7288).version,i=n(2648),r={};["object","boolean","number","function","string","symbol"].forEach((function(t,e){r[t]=function(n){return typeof n===t||"a"+(e<1?"n ":" ")+t}}));var o={};r.transitional=function(t,e,n){function r(t,e){return"[Axios v"+s+"] Transitional option '"+t+"'"+e+(n?". "+n:"")}return function(n,s,a){if(!1===t)throw new i(r(s," has been removed"+(e?" in "+e:"")),i.ERR_DEPRECATED);return e&&!o[s]&&(o[s]=!0,console.warn(r(s," has been deprecated since v"+e+" and will be removed in the near future"))),!t||t(n,s,a)}},t.exports={assertOptions:function(t,e,n){if("object"!=typeof t)throw new i("options must be an object",i.ERR_BAD_OPTION_VALUE);for(var s=Object.keys(t),r=s.length;r-- >0;){var o=s[r],a=e[o];if(a){var c=t[o],u=void 0===c||a(c,o,t);if(!0!==u)throw new i("option "+o+" must be "+u,i.ERR_BAD_OPTION_VALUE)}else if(!0!==n)throw new i("Unknown option "+o,i.ERR_BAD_OPTION)}},validators:r}},4867:(t,e,n)=>{"use strict";var s,i=n(1849),r=Object.prototype.toString,o=(s=Object.create(null),function(t){var e=r.call(t);return s[e]||(s[e]=e.slice(8,-1).toLowerCase())});function a(t){return t=t.toLowerCase(),function(e){return o(e)===t}}function c(t){return Array.isArray(t)}function u(t){return void 0===t}var l=a("ArrayBuffer");function f(t){return null!==t&&"object"==typeof t}function h(t){if("object"!==o(t))return!1;var e=Object.getPrototypeOf(t);return null===e||e===Object.prototype}var d=a("Date"),p=a("File"),g=a("Blob"),m=a("FileList");function v(t){return"[object Function]"===r.call(t)}var y=a("URLSearchParams");function b(t,e){if(null!=t)if("object"!=typeof t&&(t=[t]),c(t))for(var n=0,s=t.length;n<s;n++)e.call(null,t[n],n,t);else for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&e.call(null,t[i],i,t)}var w,S=(w="undefined"!=typeof Uint8Array&&Object.getPrototypeOf(Uint8Array),function(t){return w&&t instanceof w});t.exports={isArray:c,isArrayBuffer:l,isBuffer:function(t){return null!==t&&!u(t)&&null!==t.constructor&&!u(t.constructor)&&"function"==typeof t.constructor.isBuffer&&t.constructor.isBuffer(t)},isFormData:function(t){var e="[object FormData]";return t&&("function"==typeof FormData&&t instanceof FormData||r.call(t)===e||v(t.toString)&&t.toString()===e)},isArrayBufferView:function(t){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(t):t&&t.buffer&&l(t.buffer)},isString:function(t){return"string"==typeof t},isNumber:function(t){return"number"==typeof t},isObject:f,isPlainObject:h,isUndefined:u,isDate:d,isFile:p,isBlob:g,isFunction:v,isStream:function(t){return f(t)&&v(t.pipe)},isURLSearchParams:y,isStandardBrowserEnv:function(){return("undefined"==typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&"undefined"!=typeof window&&"undefined"!=typeof document},forEach:b,merge:function t(){var e={};function n(n,s){h(e[s])&&h(n)?e[s]=t(e[s],n):h(n)?e[s]=t({},n):c(n)?e[s]=n.slice():e[s]=n}for(var s=0,i=arguments.length;s<i;s++)b(arguments[s],n);return e},extend:function(t,e,n){return b(e,(function(e,s){t[s]=n&&"function"==typeof e?i(e,n):e})),t},trim:function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")},stripBOM:function(t){return 65279===t.charCodeAt(0)&&(t=t.slice(1)),t},inherits:function(t,e,n,s){t.prototype=Object.create(e.prototype,s),t.prototype.constructor=t,n&&Object.assign(t.prototype,n)},toFlatObject:function(t,e,n){var s,i,r,o={};e=e||{};do{for(i=(s=Object.getOwnPropertyNames(t)).length;i-- >0;)o[r=s[i]]||(e[r]=t[r],o[r]=!0);t=Object.getPrototypeOf(t)}while(t&&(!n||n(t,e))&&t!==Object.prototype);return e},kindOf:o,kindOfTest:a,endsWith:function(t,e,n){t=String(t),(void 0===n||n>t.length)&&(n=t.length),n-=e.length;var s=t.indexOf(e,n);return-1!==s&&s===n},toArray:function(t){if(!t)return null;var e=t.length;if(u(e))return null;for(var n=new Array(e);e-- >0;)n[e]=t[e];return n},isTypedArray:S,isFileList:m}},9581:(t,e,n)=>{"use strict";n.d(e,{A:()=>s});var s=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;return e.querySelector("[data-id=".concat(t,"]"))}},2702:function(t,e,n){t.exports=function(){"use strict";function t(t){return"function"==typeof t}var e=Array.isArray?Array.isArray:function(t){return"[object Array]"===Object.prototype.toString.call(t)},s=0,i=void 0,r=void 0,o=function(t,e){d[s]=t,d[s+1]=e,2===(s+=2)&&(r?r(p):b())};var a="undefined"!=typeof window?window:void 0,c=a||{},u=c.MutationObserver||c.WebKitMutationObserver,l="undefined"==typeof self&&"undefined"!=typeof process&&"[object process]"==={}.toString.call(process),f="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;function h(){var t=setTimeout;return function(){return t(p,1)}}var d=new Array(1e3);function p(){for(var t=0;t<s;t+=2)(0,d[t])(d[t+1]),d[t]=void 0,d[t+1]=void 0;s=0}var g,m,v,y,b=void 0;function w(t,e){var n=this,s=new this.constructor(F);void 0===s[x]&&N(s);var i=n._state;if(i){var r=arguments[i-1];o((function(){return j(i,s,r,n._result)}))}else C(n,s,t,e);return s}function S(t){if(t&&"object"==typeof t&&t.constructor===this)return t;var e=new this(F);return O(e,t),e}b=l?function(){return process.nextTick(p)}:u?(m=0,v=new u(p),y=document.createTextNode(""),v.observe(y,{characterData:!0}),function(){y.data=m=++m%2}):f?((g=new MessageChannel).port1.onmessage=p,function(){return g.port2.postMessage(0)}):void 0===a?function(){try{var t=Function("return this")().require("vertx");return void 0!==(i=t.runOnLoop||t.runOnContext)?function(){i(p)}:h()}catch(t){return h()}}():h();var x=Math.random().toString(36).substring(2);function F(){}var E=void 0;function A(e,n,s){n.constructor===e.constructor&&s===w&&n.constructor.resolve===S?function(t,e){1===e._state?_(t,e._result):2===e._state?R(t,e._result):C(e,void 0,(function(e){return O(t,e)}),(function(e){return R(t,e)}))}(e,n):void 0===s?_(e,n):t(s)?function(t,e,n){o((function(t){var s=!1,i=function(t,e,n,s){try{t.call(e,n,s)}catch(t){return t}}(n,e,(function(n){s||(s=!0,e!==n?O(t,n):_(t,n))}),(function(e){s||(s=!0,R(t,e))}),t._label);!s&&i&&(s=!0,R(t,i))}),t)}(e,n,s):_(e,n)}function O(t,e){if(t===e)R(t,new TypeError("You cannot resolve a promise with itself"));else if(i=typeof(s=e),null===s||"object"!==i&&"function"!==i)_(t,e);else{var n=void 0;try{n=e.then}catch(e){return void R(t,e)}A(t,e,n)}var s,i}function T(t){t._onerror&&t._onerror(t._result),k(t)}function _(t,e){t._state===E&&(t._result=e,t._state=1,0!==t._subscribers.length&&o(k,t))}function R(t,e){t._state===E&&(t._state=2,t._result=e,o(T,t))}function C(t,e,n,s){var i=t._subscribers,r=i.length;t._onerror=null,i[r]=e,i[r+1]=n,i[r+2]=s,0===r&&t._state&&o(k,t)}function k(t){var e=t._subscribers,n=t._state;if(0!==e.length){for(var s=void 0,i=void 0,r=t._result,o=0;o<e.length;o+=3)s=e[o],i=e[o+n],s?j(n,s,i,r):i(r);t._subscribers.length=0}}function j(e,n,s,i){var r=t(s),o=void 0,a=void 0,c=!0;if(r){try{o=s(i)}catch(t){c=!1,a=t}if(n===o)return void R(n,new TypeError("A promises callback cannot return that same promise."))}else o=i;n._state!==E||(r&&c?O(n,o):!1===c?R(n,a):1===e?_(n,o):2===e&&R(n,o))}var P=0;function N(t){t[x]=P++,t._state=void 0,t._result=void 0,t._subscribers=[]}var D=function(){function t(t,n){this._instanceConstructor=t,this.promise=new t(F),this.promise[x]||N(this.promise),e(n)?(this.length=n.length,this._remaining=n.length,this._result=new Array(this.length),0===this.length?_(this.promise,this._result):(this.length=this.length||0,this._enumerate(n),0===this._remaining&&_(this.promise,this._result))):R(this.promise,new Error("Array Methods must be provided an Array"))}return t.prototype._enumerate=function(t){for(var e=0;this._state===E&&e<t.length;e++)this._eachEntry(t[e],e)},t.prototype._eachEntry=function(t,e){var n=this._instanceConstructor,s=n.resolve;if(s===S){var i=void 0,r=void 0,o=!1;try{i=t.then}catch(t){o=!0,r=t}if(i===w&&t._state!==E)this._settledAt(t._state,e,t._result);else if("function"!=typeof i)this._remaining--,this._result[e]=t;else if(n===L){var a=new n(F);o?R(a,r):A(a,t,i),this._willSettleAt(a,e)}else this._willSettleAt(new n((function(e){return e(t)})),e)}else this._willSettleAt(s(t),e)},t.prototype._settledAt=function(t,e,n){var s=this.promise;s._state===E&&(this._remaining--,2===t?R(s,n):this._result[e]=n),0===this._remaining&&_(s,this._result)},t.prototype._willSettleAt=function(t,e){var n=this;C(t,void 0,(function(t){return n._settledAt(1,e,t)}),(function(t){return n._settledAt(2,e,t)}))},t}();var L=function(){function e(t){this[x]=P++,this._result=this._state=void 0,this._subscribers=[],F!==t&&("function"!=typeof t&&function(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}(),this instanceof e?function(t,e){try{e((function(e){O(t,e)}),(function(e){R(t,e)}))}catch(e){R(t,e)}}(this,t):function(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}())}return e.prototype.catch=function(t){return this.then(null,t)},e.prototype.finally=function(e){var n=this,s=n.constructor;return t(e)?n.then((function(t){return s.resolve(e()).then((function(){return t}))}),(function(t){return s.resolve(e()).then((function(){throw t}))})):n.then(e,e)},e}();return L.prototype.then=w,L.all=function(t){return new D(this,t).promise},L.race=function(t){var n=this;return e(t)?new n((function(e,s){for(var i=t.length,r=0;r<i;r++)n.resolve(t[r]).then(e,s)})):new n((function(t,e){return e(new TypeError("You must pass an array to race."))}))},L.resolve=S,L.reject=function(t){var e=new this(F);return R(e,t),e},L._setScheduler=function(t){r=t},L._setAsap=function(t){o=t},L._asap=o,L.polyfill=function(){var t=void 0;if(void 0!==n.g)t=n.g;else if("undefined"!=typeof self)t=self;else try{t=Function("return this")()}catch(t){throw new Error("polyfill failed because global object is unavailable in this environment")}var e=t.Promise;if(e){var s=null;try{s=Object.prototype.toString.call(e.resolve())}catch(t){}if("[object Promise]"===s&&!e.cast)return}t.Promise=L},L.Promise=L,L}()}},e={};function n(s){var i=e[s];if(void 0!==i)return i.exports;var r=e[s]={exports:{}};return t[s].call(r.exports,r,r.exports,n),r.exports}n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var s in e)n.o(e,s)&&!n.o(t,s)&&Object.defineProperty(t,s,{enumerable:!0,get:e[s]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e);var s={};return(()=>{"use strict";n.d(s,{default:()=>r});var t=n(9581),e=n(727),i=n.n(e);const r=function(e){if(!e)return console.log("No AddSearch API key provided, skipping search suggestions."),[];var n=new(i())(e);return[(0,t.A)("meganav-search-input"),(0,t.A)("meganav-mobile-search-input")].filter((function(t){return t})).map((function(e){var s=e.parentNode,i=(0,t.A)("meganav-search-autocomplete-container",s),r=(0,t.A)("meganav-search-autocomplete-list",s),o=(0,t.A)("meganav-search-input-clear",s);return function(t){var e=t.input,n=t.container,s=t.listContainer,i=t.clear,r=t.client;r.setAnalyticsTag("Meganav autocomplete"),r.setThrottleTime(400);var o,a=function(){n.classList.add("hidden"),s.innerHTML=""},c=function(t){(t||"").length>0&&i?i.classList.remove("invisible"):i&&i.classList.add("invisible")},u=function(t,e){return t.replace(e.toLowerCase(),'<span class="font-light">'.concat(e,"</span>"))},l=function(t){return window.location="/search?q=".concat(t)},f=function(t){var e=s.querySelector('[data-suggestion-index="'.concat(t+1,'"]'));e&&e.focus()},h=function(t){var e=t-1,n=s.querySelector('[data-suggestion-index="'.concat(e,'"]'));n&&n.focus()},d=function(t){var i=t.target.value;"ArrowDown"!==t.key?i?r.suggestions(i,function(t){return function(){var i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(c(t),Array.isArray(i.suggestions))if(0!==i.suggestions.length){var r=i.suggestions.map((function(n,s){var i=document.createElement("li"),r=document.createElement("button");return r.type="button",r.classList.add("ui-text-menu2","font-medium","p-8","w-full","text-left","rounded","hover:text-gui-hover","focus:outline-gui-focus","hover:bg-light-grey"),r.innerHTML=u(n.value,t),r.dataset.suggestionIndex=s,r.addEventListener("click",(function(){l(n.value)})),r.addEventListener("keydown",(function(t){var i=t.key;"ArrowDown"===i?f(s):"ArrowUp"===i&&s-1<0?e.focus():"ArrowUp"===i&&s-1>=0?h(s):"Enter"!==i&&"Space"!==i||l(n.value)})),i.appendChild(r),i}));s.innerHTML="",r.forEach((function(t){return s.appendChild(t)})),n.classList.remove("hidden")}else a();else a()}}(i)):a():f(0)};return i&&(o=function(){e.value="",i.classList.add("invisible"),a()},i.addEventListener("click",o)),e.addEventListener("keyup",d),{teardown:function(){e.removeEventListener("keyup",d),i&&i.removeEventListener("click",o)},clear:function(){e.value="",a()}}}({input:e,container:i,listContainer:r,client:n,clear:o})}))}})(),s.default})()}));
@@ -0,0 +1,6 @@
1
+ <div
2
+ class="absolute w-full mt-8 z-10 hidden shadow-container rounded-lg bg-white border border-mid-grey"
3
+ data-id="meganav-search-autocomplete-container"
4
+ >
5
+ <ol class="m-16" data-id="meganav-search-autocomplete-list"></ol>
6
+ </div>
@@ -0,0 +1,6 @@
1
+ module AblyUi
2
+ module Core
3
+ class MeganavSearchAutocomplete < ViewComponent::Base
4
+ end
5
+ end
6
+ end
@@ -0,0 +1 @@
1
+ !function(e,o){"object"==typeof exports&&"object"==typeof module?module.exports=o():"function"==typeof define&&define.amd?define([],o):"object"==typeof exports?exports.AblyUi=o():(e.AblyUi=e.AblyUi||{},e.AblyUi.Core=e.AblyUi.Core||{},e.AblyUi.Core.MeganavSearchPanel=o())}(this,(function(){return{}.default}));
@@ -0,0 +1,22 @@
1
+ <section class="ui-meganav-content grid-cols-12">
2
+ <div class="col-span-8">
3
+ <div class="mb-32">
4
+ <%= tag.form class: "flex items-start", action: abs_url("/search"), method: "get" do %>
5
+ <div class="relative w-full">
6
+ <%= render(AblyUi::Core::Icon.new(name: "icon-gui-search", size: "1.5rem", color: "text-cool-black", additional_css:"absolute top-12 left-16")) %>
7
+ <input type="search" name="q" class="ui-input pl-48 h-48" placeholder="Search" autocomplete="off" data-id="meganav-search-input" />
8
+
9
+ <%= render(AblyUi::Core::MeganavSearchAutocomplete.new) %>
10
+ </div>
11
+
12
+ <button type="submit" class="ui-btn-secondary flex-shrink-0 ml-8 sm:ml-16 md:ml-24 xl:ml-32">
13
+ Search
14
+ </button>
15
+ <% end %>
16
+ </div>
17
+ </div>
18
+
19
+ <div class="col-span-12">
20
+ <%= render(AblyUi::Core::MeganavSearchSuggestions.new(url_base: url_base)) %>
21
+ </div>
22
+ </section>
@@ -0,0 +1,13 @@
1
+ module AblyUi
2
+ module Core
3
+ class MeganavSearchPanel < ViewComponent::Base
4
+ include Util
5
+
6
+ attr_reader :url_base
7
+
8
+ def initialize(url_base:)
9
+ @url_base = url_base
10
+ end
11
+ end
12
+ end
13
+ end
@@ -0,0 +1 @@
1
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.AblyUi=t():(e.AblyUi=e.AblyUi||{},e.AblyUi.Core=e.AblyUi.Core||{},e.AblyUi.Core.MeganavSearchSuggestions=t())}(this,(function(){return(()=>{"use strict";var e={9581:(e,t,n)=>{n.d(t,{A:()=>r});var r=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;return t.querySelector("[data-id=".concat(e,"]"))}}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r](i,i.exports,n),i.exports}n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var r={};return(()=>{n.d(r,{default:()=>s});var e=n(9581),t=function(e){return new DOMMatrix(window.getComputedStyle(e).transform).e},o=function(e,t){return e.style.transform="translateX(".concat(t,"px)")},i=function(e,t){return e>=t},u=function(e,t,n,r){return Math.abs(e-n+r)>t},a=function(e,t){var n;return(null===(n=e.changedTouches[0])||void 0===n?void 0:n.clientX)-t},c=function(e){return Math.abs(e)<5};const s=function(){var n,r=(0,e.A)("meganav-mobile-search-input"),s=(0,e.A)("meganav-mobile-search-suggestions"),d=s.querySelector("ul"),l=d.querySelectorAll("li"),v=Array.from(l).map((function(e){return e.getBoundingClientRect().width})).reduce((function(e,t){return e+t}),0),f=function(e){var t;n=null===(t=e.touches[0])||void 0===t?void 0:t.clientX},h=function(e){var r=a(e,n);c(r)||(r>0?function(e,n){var r=t(d),u=Math.round(r+e);i(u,24)||o(d,u)}(r):function(e,n){var r=d.getBoundingClientRect().width,i=t(d),a=Math.round(i+e);u(a,v,r,96)||o(d,a)}(r))},m=function(e){var r=a(e,n);c(r)||(r>0?function(e,n){var r=t(d),u=Math.round(r+e);i(u,24)&&(u=0),o(d,u)}(r):function(e,n){var r=d.getBoundingClientRect().width,i=t(d),a=Math.round(i+e);u(a,v,r,48)&&(a=-(v-r+48)),o(d,a)}(r))},p=function(){s.classList.add("max-h-96")},y=function(e){e.relatedTarget!==s.querySelectorAll("a")[0]&&s.classList.remove("max-h-96")};return r.addEventListener("focus",p),r.addEventListener("blur",y),s.addEventListener("touchstart",f),s.addEventListener("touchmove",h),s.addEventListener("touchend",m),{teardown:function(){r.removeEventListener("focus",p),r.removeEventListener("blur",y),s.removeEventListener("touchstart",f),s.removeEventListener("touchmove",h),s.removeEventListener("touchend",m)},clear:function(){s.classList.remove("max-h-96"),d.style.transform="translateX(0px)"}}}})(),r.default})()}));
@@ -0,0 +1,22 @@
1
+ <p class="ui-text-overline2 text-cool-black py-12">Popular pages</p>
2
+
3
+ <div class="flex justify-between items-center overflow-hidden">
4
+ <ul class="flex transition-transform">
5
+ <li class="py-12 pr-8 flex-shrink-0">
6
+ <%= link_to 'How does Ably work?', abs_url("/docs/how-ably-works"), class: "ui-text-p2 hover:text-gui-hover active:text-gui-active focus:text-gui-focus" %>
7
+ </li>
8
+ <li class="py-12 px-8 flex-shrink-0">
9
+ <%= link_to 'Quickstart guide', abs_url("/docs/quick-start-guide"), class: "ui-text-p2 hover:text-gui-hover active:text-gui-active focus:text-gui-focus" %>
10
+ </li>
11
+ <li class="py-12 px-8 flex-shrink-0">
12
+ <%= link_to 'Publish/Subscribe Messaging', abs_url("/docs/core-features/pubsub"), class: "ui-text-p2 hover:text-gui-hover active:text-gui-active focus:text-gui-focus" %>
13
+ </li>
14
+ <li class="py-12 pl-8 flex-shrink-0">
15
+ <%= link_to 'Platform', abs_url("/docs/how-ably-works"), class: "ui-text-p2 hover:text-gui-hover active:text-gui-active focus:text-gui-focus" %>
16
+ </li>
17
+ </ul>
18
+
19
+ <% if display_support_link? %>
20
+ <%= render(AblyUi::Core::FeaturedLink.new(url: abs_url("/support"), text_size: "text-p2")) do %>Support<% end %>
21
+ <% end %>
22
+ </div>
@@ -0,0 +1,18 @@
1
+ module AblyUi
2
+ module Core
3
+ class MeganavSearchSuggestions < ViewComponent::Base
4
+ include Util
5
+
6
+ attr_reader :url_base
7
+
8
+ def initialize(url_base:, display_support_link: true)
9
+ @url_base = url_base
10
+ @display_support_link = display_support_link
11
+ end
12
+
13
+ def display_support_link?
14
+ @display_support_link
15
+ end
16
+ end
17
+ end
18
+ end
@@ -1 +1 @@
1
- !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("react"),require("react-dom")):"function"==typeof define&&define.amd?define([,],e):"object"==typeof exports?exports.AblyUi=e(require("react"),require("react-dom")):(t.AblyUi=t.AblyUi||{},t.AblyUi.Core=e(t[void 0],t[void 0]))}(this,(function(t,e){return(()=>{var r={757:(t,e,r)=>{t.exports=r(666)},666:t=>{var e=function(t){"use strict";var e,r=Object.prototype,n=r.hasOwnProperty,o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function f(t,e,r,n){var o=e&&e.prototype instanceof v?e:v,i=Object.create(o.prototype),a=new A(n||[]);return i._invoke=function(t,e,r){var n=l;return function(o,i){if(n===h)throw new Error("Generator is already running");if(n===d){if("throw"===o)throw i;return k()}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var c=P(a,r);if(c){if(c===y)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(n===l)throw n=d,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n=h;var u=s(t,e,r);if("normal"===u.type){if(n=r.done?d:p,u.arg===y)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n=d,r.method="throw",r.arg=u.arg)}}}(t,r,a),i}function s(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=f;var l="suspendedStart",p="suspendedYield",h="executing",d="completed",y={};function v(){}function b(){}function g(){}var w={};w[i]=function(){return this};var m=Object.getPrototypeOf,O=m&&m(m(N([])));O&&O!==r&&n.call(O,i)&&(w=O);var x=g.prototype=v.prototype=Object.create(w);function E(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function r(o,i,a,c){var u=s(t[o],t,i);if("throw"!==u.type){var f=u.arg,l=f.value;return l&&"object"==typeof l&&n.call(l,"__await")?e.resolve(l.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(l).then((function(t){f.value=t,a(f)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var o;this._invoke=function(t,n){function i(){return new e((function(e,o){r(t,n,e,o)}))}return o=o?o.then(i,i):i()}}function P(t,r){var n=t.iterator[r.method];if(n===e){if(r.delegate=null,"throw"===r.method){if(t.iterator.return&&(r.method="return",r.arg=e,P(t,r),"throw"===r.method))return y;r.method="throw",r.arg=new TypeError("The iterator does not provide a 'throw' method")}return y}var o=s(n,t.iterator,r.arg);if("throw"===o.type)return r.method="throw",r.arg=o.arg,r.delegate=null,y;var i=o.arg;return i?i.done?(r[t.resultName]=i.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,y):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,y)}function S(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function L(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function A(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(S,this),this.reset(!0)}function N(t){if(t){var r=t[i];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,a=function r(){for(;++o<t.length;)if(n.call(t,o))return r.value=t[o],r.done=!1,r;return r.value=e,r.done=!0,r};return a.next=a}}return{next:k}}function k(){return{value:e,done:!0}}return b.prototype=x.constructor=g,g.constructor=b,b.displayName=u(g,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===b||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,g):(t.__proto__=g,u(t,c,"GeneratorFunction")),t.prototype=Object.create(x),t},t.awrap=function(t){return{__await:t}},E(j.prototype),j.prototype[a]=function(){return this},t.AsyncIterator=j,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new j(f(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},E(x),u(x,c,"Generator"),x[i]=function(){return this},x.toString=function(){return"[object Generator]"},t.keys=function(t){var e=[];for(var r in t)e.push(r);return e.reverse(),function r(){for(;e.length;){var n=e.pop();if(n in t)return r.value=n,r.done=!1,r}return r.done=!0,r}},t.values=N,A.prototype={constructor:A,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(L),!t)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=e)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var r=this;function o(n,o){return c.type="throw",c.arg=t,r.next=n,o&&(r.method="next",r.arg=e),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),f=n.call(a,"finallyLoc");if(u&&f){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!f)throw new Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,y):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),y},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),L(r),y}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;L(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:N(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),y}},t}(t.exports);try{regeneratorRuntime=e}catch(t){Function("r","regeneratorRuntime = r")(e)}},281:e=>{"use strict";e.exports=t},645:t=>{"use strict";t.exports=e}},n={};function o(t){var e=n[t];if(void 0!==e)return e.exports;var i=n[t]={exports:{}};return r[t](i,i.exports,o),i.exports}o.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return o.d(e,{a:e}),e},o.d=(t,e)=>{for(var r in e)o.o(e,r)&&!o.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},o.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),o.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var i={};return(()=>{"use strict";o.r(i),o.d(i,{attachStoreToWindow:()=>O,connectState:()=>E,createRemoteDataStore:()=>j,fetchBlogPosts:()=>T,fetchSessionData:()=>M,getRemoteDataStore:()=>x,loadSprites:()=>u,queryId:()=>f,queryIdAll:()=>s,reactRenderer:()=>c,reducerBlogPosts:()=>D,reducerSessionData:()=>F,renderComponent:()=>a,selectRecentBlogPosts:()=>I,selectSessionData:()=>W,toggleChatWidget:()=>d}),Array.prototype.flat||Object.defineProperty(Array.prototype,"flat",{configurable:!0,value:function t(){var e=isNaN(arguments[0])?1:Number(arguments[0]);return e?Array.prototype.reduce.call(this,(function(r,n){return Array.isArray(n)?r.push.apply(r,t.call(n,e-1)):r.push(n),r}),[]):Array.prototype.slice.call(this)},writable:!0}),Array.prototype.flatMap||Object.defineProperty(Array.prototype,"flatMap",{configurable:!0,value:function(t){return Array.prototype.map.apply(this,arguments).flat()},writable:!0});var t=o(281),e=o.n(t),r=o(645),n=o.n(r),a=function(t,r,o){return n().render(e().createElement(t,r),o)};function c(t){var r=document.querySelectorAll("[data-react]");Array.from(r).forEach((function(r){var o=r.getAttribute("data-react"),i=t[o];if(i){var a=r.getAttribute("data-react-props"),c=a&&JSON.parse(a||{});n().render(e().createElement(i,c),r),r.removeAttribute("data-react"),r.removeAttribute("data-react-props")}}))}const u=function(t){fetch(t).then((function(t){return t.text()})).then((function(t){var e=document.createElement("div");e.style.display="none",e.innerHTML=t,document.body.appendChild(e)})).catch((function(t){return console.error(t)}))};var f=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;return e.querySelector("[data-id=".concat(t,"]"))},s=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;return e.querySelectorAll("[data-id=".concat(t,"]"))};function l(t,e){t.disabled=!1,t.innerText=e}function p(t,e){t.disabled=!0,t.innerText=e}var h=30;function d(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=t.dataId,r=f(e),n=f("open-chat-widget",r),o=n.dataset.enabledLabel,i=n.dataset.disabledLabel;if(e&&r){var a,c=f("open-chat-widget",r),u=function t(e){var r,n,i=null===(r=window)||void 0===r||null===(n=r.HubSpotConversations)||void 0===n?void 0:n.widget,u=document.querySelector("#hubspot-messages-iframe-container");a=function(t){t.preventDefault(),i.open()},i&&u?(c.addEventListener("click",a),l(c,o)):--h&&setTimeout((function(){return t(100)}),e)};return p(c,i),u(0),function(){p(c,i),c.removeEventListener("click",a)}}}function y(t){return"Minified Redux error #"+t+"; visit https://redux.js.org/Errors?code="+t+" for the full message or use the non-minified dev environment for full errors. "}var v="function"==typeof Symbol&&Symbol.observable||"@@observable",b=function(){return Math.random().toString(36).substring(7).split("").join(".")},g={INIT:"@@redux/INIT"+b(),REPLACE:"@@redux/REPLACE"+b(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+b()}};function w(t){if("object"!=typeof t||null===t)return!1;for(var e=t;null!==Object.getPrototypeOf(e);)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e}function m(t,e,r){var n;if("function"==typeof e&&"function"==typeof r||"function"==typeof r&&"function"==typeof arguments[3])throw new Error(y(0));if("function"==typeof e&&void 0===r&&(r=e,e=void 0),void 0!==r){if("function"!=typeof r)throw new Error(y(1));return r(m)(t,e)}if("function"!=typeof t)throw new Error(y(2));var o=t,i=e,a=[],c=a,u=!1;function f(){c===a&&(c=a.slice())}function s(){if(u)throw new Error(y(3));return i}function l(t){if("function"!=typeof t)throw new Error(y(4));if(u)throw new Error(y(5));var e=!0;return f(),c.push(t),function(){if(e){if(u)throw new Error(y(6));e=!1,f();var r=c.indexOf(t);c.splice(r,1),a=null}}}function p(t){if(!w(t))throw new Error(y(7));if(void 0===t.type)throw new Error(y(8));if(u)throw new Error(y(9));try{u=!0,i=o(i,t)}finally{u=!1}for(var e=a=c,r=0;r<e.length;r++)(0,e[r])();return t}function h(t){if("function"!=typeof t)throw new Error(y(10));o=t,p({type:g.REPLACE})}function d(){var t,e=l;return(t={subscribe:function(t){if("object"!=typeof t||null===t)throw new Error(y(11));function r(){t.next&&t.next(s())}return r(),{unsubscribe:e(r)}}})[v]=function(){return this},t}return p({type:g.INIT}),(n={dispatch:p,subscribe:l,getState:s,replaceReducer:h})[v]=d,n}var O=function(t){window.AblyUi=window.AblyUi||{},window.AblyUi.RemoteDataStore=t},x=function(){if(!window.AblyUi.RemoteDataStore)throw new Error("Remote store was called before one was created");return window.AblyUi.RemoteDataStore},E=function(t,e){var r=x(),n=t(r);r.subscribe((function(){var o=t(r);o!==n&&(n=o,e(o))}))},j=function(t){return m(function(t){for(var e=Object.keys(t),r={},n=0;n<e.length;n++){var o=e[n];"function"==typeof t[o]&&(r[o]=t[o])}var i,a=Object.keys(r);try{!function(t){Object.keys(t).forEach((function(e){var r=t[e];if(void 0===r(void 0,{type:g.INIT}))throw new Error(y(12));if(void 0===r(void 0,{type:g.PROBE_UNKNOWN_ACTION()}))throw new Error(y(13))}))}(r)}catch(t){i=t}return function(t,e){if(void 0===t&&(t={}),i)throw i;for(var n=!1,o={},c=0;c<a.length;c++){var u=a[c],f=r[u],s=t[u],l=f(s,e);if(void 0===l)throw e&&e.type,new Error(y(14));o[u]=l,n=n||l!==s}return(n=n||a.length!==Object.keys(t).length)?o:t}}(t))},P=o(757),S=o.n(P),L=function(t){return t&&t.includes("application/json")};function A(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function N(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?A(Object(r),!0).forEach((function(e){k(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):A(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function k(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function _(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}var T=function(){var t,e=(t=S().mark((function t(e,r){var n,o;return S().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(t.prev=0,r){t.next=4;break}return console.warn('Skipping fetching blog posts, invalid blogUrl: "'.concat(r,'"')),t.abrupt("return");case 4:return t.next=6,fetch(r);case 6:if(n=t.sent,!L(n.headers.get("content-type"))){t.next=14;break}return t.next=10,n.json();case 10:o=t.sent,e.dispatch({type:"blog/loaded",payload:o}),t.next=15;break;case 14:throw new Error("Blog posts url is not serving json");case 15:t.next=20;break;case 17:t.prev=17,t.t0=t.catch(0),console.warn("Could not fetch blog posts due to error:",t.t0);case 20:case"end":return t.stop()}}),t,null,[[0,17]])})),function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){_(i,n,o,a,c,"next",t)}function c(t){_(i,n,o,a,c,"throw",t)}a(void 0)}))});return function(t,r){return e.apply(this,arguments)}}(),R={recent:null},D=k({},"blogPosts",(function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:R,e=arguments.length>1?arguments[1]:void 0;switch(e.type){case"blog/loaded":return N(N({},t),{},{recent:e.payload});default:return t}})),I=function(t){var e;return null===(e=t.getState().blogPosts)||void 0===e?void 0:e.recent};function U(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function C(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?U(Object(r),!0).forEach((function(e){q(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):U(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function q(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function G(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}var M=function(){var t,e=(t=S().mark((function t(e,r){var n,o,i;return S().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(n=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return e.dispatch({type:"session/loaded",payload:t})},t.prev=1,r){t.next=6;break}return console.warn('Skipping fetching session, invalid sessionUrl: "'.concat(r,'"')),n(),t.abrupt("return");case 6:return t.next=8,fetch(r,{cache:"no-cache"});case 8:if(o=t.sent,L(o.headers.get("content-type"))){t.next=12;break}throw new Error("Session endpoint is not serving json");case 12:return t.next=14,o.json();case 14:"not-found"===(i=t.sent).error?n():n(i),t.next=22;break;case 18:t.prev=18,t.t0=t.catch(1),n(),console.warn("Could not fetch session data due to error:",t.t0);case 22:case"end":return t.stop()}}),t,null,[[1,18]])})),function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){G(i,n,o,a,c,"next",t)}function c(t){G(i,n,o,a,c,"throw",t)}a(void 0)}))});return function(t,r){return e.apply(this,arguments)}}(),B={data:null},F=q({},"session",(function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:B,e=arguments.length>1?arguments[1]:void 0;switch(e.type){case"session/loaded":return C(C({},t),{},{data:e.payload});default:return t}})),W=function(t){var e;return null===(e=t.getState().session)||void 0===e?void 0:e.data}})(),i})()}));
1
+ !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("react"),require("react-dom")):"function"==typeof define&&define.amd?define([,],e):"object"==typeof exports?exports.AblyUi=e(require("react"),require("react-dom")):(t.AblyUi=t.AblyUi||{},t.AblyUi.Core=e(t[void 0],t[void 0]))}(this,(function(t,e){return(()=>{var r={757:(t,e,r)=>{t.exports=r(666)},666:t=>{var e=function(t){"use strict";var e,r=Object.prototype,n=r.hasOwnProperty,o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function f(t,e,r,n){var o=e&&e.prototype instanceof v?e:v,i=Object.create(o.prototype),a=new A(n||[]);return i._invoke=function(t,e,r){var n=l;return function(o,i){if(n===h)throw new Error("Generator is already running");if(n===d){if("throw"===o)throw i;return k()}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var c=P(a,r);if(c){if(c===y)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(n===l)throw n=d,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n=h;var u=s(t,e,r);if("normal"===u.type){if(n=r.done?d:p,u.arg===y)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n=d,r.method="throw",r.arg=u.arg)}}}(t,r,a),i}function s(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=f;var l="suspendedStart",p="suspendedYield",h="executing",d="completed",y={};function v(){}function b(){}function g(){}var w={};w[i]=function(){return this};var m=Object.getPrototypeOf,O=m&&m(m(N([])));O&&O!==r&&n.call(O,i)&&(w=O);var x=g.prototype=v.prototype=Object.create(w);function E(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function r(o,i,a,c){var u=s(t[o],t,i);if("throw"!==u.type){var f=u.arg,l=f.value;return l&&"object"==typeof l&&n.call(l,"__await")?e.resolve(l.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(l).then((function(t){f.value=t,a(f)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var o;this._invoke=function(t,n){function i(){return new e((function(e,o){r(t,n,e,o)}))}return o=o?o.then(i,i):i()}}function P(t,r){var n=t.iterator[r.method];if(n===e){if(r.delegate=null,"throw"===r.method){if(t.iterator.return&&(r.method="return",r.arg=e,P(t,r),"throw"===r.method))return y;r.method="throw",r.arg=new TypeError("The iterator does not provide a 'throw' method")}return y}var o=s(n,t.iterator,r.arg);if("throw"===o.type)return r.method="throw",r.arg=o.arg,r.delegate=null,y;var i=o.arg;return i?i.done?(r[t.resultName]=i.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,y):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,y)}function S(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function L(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function A(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(S,this),this.reset(!0)}function N(t){if(t){var r=t[i];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,a=function r(){for(;++o<t.length;)if(n.call(t,o))return r.value=t[o],r.done=!1,r;return r.value=e,r.done=!0,r};return a.next=a}}return{next:k}}function k(){return{value:e,done:!0}}return b.prototype=x.constructor=g,g.constructor=b,b.displayName=u(g,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===b||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,g):(t.__proto__=g,u(t,c,"GeneratorFunction")),t.prototype=Object.create(x),t},t.awrap=function(t){return{__await:t}},E(j.prototype),j.prototype[a]=function(){return this},t.AsyncIterator=j,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new j(f(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},E(x),u(x,c,"Generator"),x[i]=function(){return this},x.toString=function(){return"[object Generator]"},t.keys=function(t){var e=[];for(var r in t)e.push(r);return e.reverse(),function r(){for(;e.length;){var n=e.pop();if(n in t)return r.value=n,r.done=!1,r}return r.done=!0,r}},t.values=N,A.prototype={constructor:A,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(L),!t)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=e)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var r=this;function o(n,o){return c.type="throw",c.arg=t,r.next=n,o&&(r.method="next",r.arg=e),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),f=n.call(a,"finallyLoc");if(u&&f){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!f)throw new Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,y):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),y},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),L(r),y}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;L(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:N(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),y}},t}(t.exports);try{regeneratorRuntime=e}catch(t){Function("r","regeneratorRuntime = r")(e)}},281:e=>{"use strict";e.exports=t},645:t=>{"use strict";t.exports=e}},n={};function o(t){var e=n[t];if(void 0!==e)return e.exports;var i=n[t]={exports:{}};return r[t](i,i.exports,o),i.exports}o.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return o.d(e,{a:e}),e},o.d=(t,e)=>{for(var r in e)o.o(e,r)&&!o.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},o.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),o.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var i={};return(()=>{"use strict";o.r(i),o.d(i,{attachStoreToWindow:()=>O,connectState:()=>E,createRemoteDataStore:()=>j,fetchBlogPosts:()=>T,fetchSessionData:()=>M,getRemoteDataStore:()=>x,loadSprites:()=>u,queryId:()=>f,queryIdAll:()=>s,reactRenderer:()=>c,reducerBlogPosts:()=>D,reducerSessionData:()=>F,renderComponent:()=>a,selectRecentBlogPosts:()=>I,selectSessionData:()=>W,toggleChatWidget:()=>d}),Array.prototype.flat||Object.defineProperty(Array.prototype,"flat",{configurable:!0,value:function t(){var e=isNaN(arguments[0])?1:Number(arguments[0]);return e?Array.prototype.reduce.call(this,(function(r,n){return Array.isArray(n)?r.push.apply(r,t.call(n,e-1)):r.push(n),r}),[]):Array.prototype.slice.call(this)},writable:!0}),Array.prototype.flatMap||Object.defineProperty(Array.prototype,"flatMap",{configurable:!0,value:function(t){return Array.prototype.map.apply(this,arguments).flat()},writable:!0});var t=o(281),e=o.n(t),r=o(645),n=o.n(r),a=function(t,r,o){return n().render(e().createElement(t,r),o)};function c(t){var r=document.querySelectorAll("[data-react]");Array.from(r).forEach((function(r){var o=r.getAttribute("data-react"),i=t[o];if(i){var a=r.getAttribute("data-react-props"),c=a&&JSON.parse(a||{});n().render(e().createElement(i,c),r),r.removeAttribute("data-react"),r.removeAttribute("data-react-props")}}))}const u=function(t){fetch(t).then((function(t){return t.text()})).then((function(t){var e=document.createElement("div");e.style.display="none",e.innerHTML=t,document.body.appendChild(e)})).catch((function(t){return console.error(t)}))};var f=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;return e.querySelector("[data-id=".concat(t,"]"))},s=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document;return e.querySelectorAll("[data-id=".concat(t,"]"))};function l(t,e){t.disabled=!1,t.innerText=e}function p(t,e){t.disabled=!0,t.innerText=e}var h=30;function d(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=t.dataId,r=f(e),n=f("open-chat-widget",r),o=n.dataset.enabledLabel,i=n.dataset.disabledLabel;if(e&&r){var a,c=f("open-chat-widget",r),u=function t(e){var r,n,i=null===(r=window)||void 0===r||null===(n=r.HubSpotConversations)||void 0===n?void 0:n.widget,u=document.querySelector("#hubspot-messages-iframe-container");a=function(t){t.preventDefault(),i.open()},i&&u?(c.addEventListener("click",a),l(c,o)):--h&&setTimeout((function(){return t(100)}),e)};return p(c,i),u(0),function(){p(c,i),c.removeEventListener("click",a)}}}function y(t){return"Minified Redux error #"+t+"; visit https://redux.js.org/Errors?code="+t+" for the full message or use the non-minified dev environment for full errors. "}var v="function"==typeof Symbol&&Symbol.observable||"@@observable",b=function(){return Math.random().toString(36).substring(7).split("").join(".")},g={INIT:"@@redux/INIT"+b(),REPLACE:"@@redux/REPLACE"+b(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+b()}};function w(t){if("object"!=typeof t||null===t)return!1;for(var e=t;null!==Object.getPrototypeOf(e);)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e}function m(t,e,r){var n;if("function"==typeof e&&"function"==typeof r||"function"==typeof r&&"function"==typeof arguments[3])throw new Error(y(0));if("function"==typeof e&&void 0===r&&(r=e,e=void 0),void 0!==r){if("function"!=typeof r)throw new Error(y(1));return r(m)(t,e)}if("function"!=typeof t)throw new Error(y(2));var o=t,i=e,a=[],c=a,u=!1;function f(){c===a&&(c=a.slice())}function s(){if(u)throw new Error(y(3));return i}function l(t){if("function"!=typeof t)throw new Error(y(4));if(u)throw new Error(y(5));var e=!0;return f(),c.push(t),function(){if(e){if(u)throw new Error(y(6));e=!1,f();var r=c.indexOf(t);c.splice(r,1),a=null}}}function p(t){if(!w(t))throw new Error(y(7));if(void 0===t.type)throw new Error(y(8));if(u)throw new Error(y(9));try{u=!0,i=o(i,t)}finally{u=!1}for(var e=a=c,r=0;r<e.length;r++)(0,e[r])();return t}function h(t){if("function"!=typeof t)throw new Error(y(10));o=t,p({type:g.REPLACE})}function d(){var t,e=l;return(t={subscribe:function(t){if("object"!=typeof t||null===t)throw new Error(y(11));function r(){t.next&&t.next(s())}return r(),{unsubscribe:e(r)}}})[v]=function(){return this},t}return p({type:g.INIT}),(n={dispatch:p,subscribe:l,getState:s,replaceReducer:h})[v]=d,n}var O=function(t){window.AblyUi=window.AblyUi||{},window.AblyUi.RemoteDataStore=t},x=function(){if(!window.AblyUi.RemoteDataStore)throw new Error("Remote store was called before one was created");return window.AblyUi.RemoteDataStore},E=function(t,e){var r=x(),n=t(r);r.subscribe((function(){var o=t(r);o!==n&&(n=o,e(o))}))},j=function(t){return m(function(t){for(var e=Object.keys(t),r={},n=0;n<e.length;n++){var o=e[n];"function"==typeof t[o]&&(r[o]=t[o])}var i,a=Object.keys(r);try{!function(t){Object.keys(t).forEach((function(e){var r=t[e];if(void 0===r(void 0,{type:g.INIT}))throw new Error(y(12));if(void 0===r(void 0,{type:g.PROBE_UNKNOWN_ACTION()}))throw new Error(y(13))}))}(r)}catch(t){i=t}return function(t,e){if(void 0===t&&(t={}),i)throw i;for(var n=!1,o={},c=0;c<a.length;c++){var u=a[c],f=r[u],s=t[u],l=f(s,e);if(void 0===l)throw e&&e.type,new Error(y(14));o[u]=l,n=n||l!==s}return(n=n||a.length!==Object.keys(t).length)?o:t}}(t))},P=o(757),S=o.n(P),L=function(t){return t&&t.includes("application/json")};function A(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function N(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?A(Object(r),!0).forEach((function(e){k(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):A(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function k(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function _(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}var T=function(){var t,e=(t=S().mark((function t(e,r){var n,o;return S().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(t.prev=0,r){t.next=4;break}return console.log('Skipping fetching blog posts, invalid blogUrl: "'.concat(r,'"')),t.abrupt("return");case 4:return t.next=6,fetch(r);case 6:if(n=t.sent,!L(n.headers.get("content-type"))){t.next=14;break}return t.next=10,n.json();case 10:o=t.sent,e.dispatch({type:"blog/loaded",payload:o}),t.next=15;break;case 14:throw new Error("Blog posts url is not serving json");case 15:t.next=20;break;case 17:t.prev=17,t.t0=t.catch(0),console.warn("Could not fetch blog posts due to error:",t.t0);case 20:case"end":return t.stop()}}),t,null,[[0,17]])})),function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){_(i,n,o,a,c,"next",t)}function c(t){_(i,n,o,a,c,"throw",t)}a(void 0)}))});return function(t,r){return e.apply(this,arguments)}}(),R={recent:null},D=k({},"blogPosts",(function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:R,e=arguments.length>1?arguments[1]:void 0;switch(e.type){case"blog/loaded":return N(N({},t),{},{recent:e.payload});default:return t}})),I=function(t){var e;return null===(e=t.getState().blogPosts)||void 0===e?void 0:e.recent};function U(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function C(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?U(Object(r),!0).forEach((function(e){q(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):U(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function q(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function G(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}var M=function(){var t,e=(t=S().mark((function t(e,r){var n,o,i;return S().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(n=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return e.dispatch({type:"session/loaded",payload:t})},t.prev=1,r){t.next=6;break}return console.log('Skipping fetching session, invalid sessionUrl: "'.concat(r,'"')),n(),t.abrupt("return");case 6:return t.next=8,fetch(r,{cache:"no-cache"});case 8:if(o=t.sent,L(o.headers.get("content-type"))){t.next=12;break}throw new Error("Session endpoint is not serving json");case 12:return t.next=14,o.json();case 14:"not-found"===(i=t.sent).error?n():n(i),t.next=22;break;case 18:t.prev=18,t.t0=t.catch(1),n(),console.warn("Could not fetch session data due to error:",t.t0);case 22:case"end":return t.stop()}}),t,null,[[1,18]])})),function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){G(i,n,o,a,c,"next",t)}function c(t){G(i,n,o,a,c,"throw",t)}a(void 0)}))});return function(t,r){return e.apply(this,arguments)}}(),B={data:null},F=q({},"session",(function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:B,e=arguments.length>1?arguments[1]:void 0;switch(e.type){case"session/loaded":return C(C({},t),{},{data:e.payload});default:return t}})),W=function(t){var e;return null===(e=t.getState().session)||void 0===e?void 0:e.data}})(),i})()}));
@@ -15,9 +15,10 @@
15
15
  --color-charcoal-grey: #292831;
16
16
  --color-gui-default: #0073e6;
17
17
  --color-gui-hover: #0867c4;
18
- --color-gui-focus: #80b9f2;
18
+ --color-gui-focus: #0073e6;
19
+ --color-gui-focus-outline: #80b9f2;
19
20
  --color-gui-active: #074095;
20
- --color-gui-viewed: #4887c2;
21
+ --color-gui-visited: #4887c2;
21
22
  --color-gui-unavailable: #a8a8a8;
22
23
  --color-gui-error: #fb0c0c;
23
24
  --color-gui-success: #11cb24;
@@ -117,7 +118,9 @@
117
118
 
118
119
  --spacing-0: 0px;
119
120
  --spacing-1: 1px;
121
+ --spacing-2: 0.125rem;
120
122
  --spacing-4: 0.25rem;
123
+ --spacing-6: 0.375rem;
121
124
  --spacing-8: 0.5rem;
122
125
  --spacing-12: 0.75rem;
123
126
  --spacing-14: 0.875rem;
@@ -155,7 +158,7 @@
155
158
  /* In components, when looking at implementing viewport margin and spacing between elements,
156
159
  the values in the comments can be used as guide as they represent the grid the elements (should) sit on.
157
160
  alternatively, look for ui-grid-* helpers. */
158
- --bp-xs: 375px; /* gutters 8px, side-margin 24px */
161
+ --bp-xs: 428px; /* gutters 8px, side-margin 24px */
159
162
  --bp-sm: 768px; /* gutters 16px, side-margin 32px */
160
163
  --bp-md: 1040px; /* gutters 24px, side-margin 40px, meganav desktop */
161
164
  --bp-lg: 1280px; /* gutters 24px, side-margin 64px */
@@ -343,17 +346,17 @@
343
346
  }
344
347
 
345
348
  .ui-text-p1 {
346
- @apply font-sans font-light text-cool-black;
349
+ @apply font-sans font-light text-charcoal-grey;
347
350
  @apply text-p1;
348
351
  }
349
352
 
350
353
  .ui-text-p2 {
351
- @apply font-sans font-light text-cool-black;
354
+ @apply font-sans font-light text-charcoal-grey;
352
355
  @apply text-p2;
353
356
  }
354
357
 
355
358
  .ui-text-p3 {
356
- @apply font-sans font-light text-cool-black;
359
+ @apply font-sans font-light text-charcoal-grey;
357
360
  @apply text-p3;
358
361
  }
359
362
 
@@ -459,24 +462,18 @@
459
462
  @apply list-square;
460
463
  }
461
464
 
462
- /* visited needs to come before :hover et all else it overrides them */
463
- .ui-link:visited {
464
- @apply text-gui-viewed;
465
- }
466
-
467
465
  .ui-link {
468
- @apply hover:text-active-orange active:text-red-orange;
469
- -webkit-text-decoration-color: var(--color-active-orange);
470
- text-decoration-color: var(--color-active-orange);
471
- text-underline-offset: 4px; /* px used here as behaves weird with rem's */
472
- -webkit-text-decoration-line: underline;
473
- text-decoration-line: underline;
474
- text-decoration-thickness: 0.125rem;
466
+ @apply visited:text-gui-visited;
467
+ @apply hover:text-gui-hover active:text-gui-active disabled:text-gui-unavailable;
468
+ @apply focus:text-gui-focus focus:outline-gui-focus;
469
+ @apply underline;
475
470
  }
476
471
 
477
- .ui-link:focus {
478
- @apply focus:text-white focus:bg-active-orange focus:outline-none;
479
- text-decoration: none;
472
+ .ui-link-neutral {
473
+ @apply visited:text-dark-grey;
474
+ @apply hover:text-dark-grey active:text-cool-black disabled:text-gui-unavailable;
475
+ @apply focus:text-gui-focus focus:outline-gui-focus-neutral;
476
+ @apply underline;
480
477
  }
481
478
  }
482
479
  @layer components {
@@ -576,21 +573,6 @@
576
573
  stroke: var(--color-dark-grey);
577
574
  }
578
575
 
579
- /* Extend how tailwind does group hover for icons */
580
- .group {
581
- &:hover {
582
- .group-hover\:icon-gui-hover {
583
- stroke: var(--color-gui-hover);
584
- }
585
- }
586
-
587
- &:focus {
588
- .group-focus\:icon-gui-focus {
589
- stroke: var(--color-gui-focus);
590
- }
591
- }
592
- }
593
-
594
576
  .ui-version-tag {
595
577
  @apply inline-block absolute align-top uppercase font-bold whitespace-nowrap;
596
578
 
@@ -1,3 +1,3 @@
1
1
  module AblyUi
2
- VERSION = '7.10.0'
2
+ VERSION = '8.0.0.dev.7e3a14d'
3
3
  end
metadata CHANGED
@@ -1,16 +1,16 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ably-ui
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.10.0
4
+ version: 8.0.0.dev.7e3a14d
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dominik Piatek
8
8
  - Arti Mathanda
9
9
  - Bruce Thomas
10
- autorequire:
10
+ autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2022-07-07 00:00:00.000000000 Z
13
+ date: 2022-08-17 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: view_component
@@ -32,7 +32,7 @@ dependencies:
32
32
  - - "<"
33
33
  - !ruby/object:Gem::Version
34
34
  version: '2.50'
35
- description:
35
+ description:
36
36
  email:
37
37
  - dominik.piatek@ably.com
38
38
  - arti.mathanda@ably.com
@@ -91,10 +91,12 @@ files:
91
91
  - lib/ably_ui/core/fonts/NEXT-Book-Medium.woff
92
92
  - lib/ably_ui/core/fonts/NEXT-Book-Medium.woff2
93
93
  - lib/ably_ui/core/fonts/next.css
94
+ - lib/ably_ui/core/fonts/source-code-pro.css
94
95
  - lib/ably_ui/core/footer/component.css
95
96
  - lib/ably_ui/core/footer/component.js
96
97
  - lib/ably_ui/core/footer/footer.html.erb
97
98
  - lib/ably_ui/core/footer/footer.rb
99
+ - lib/ably_ui/core/icon/component.css
98
100
  - lib/ably_ui/core/icon/component.js
99
101
  - lib/ably_ui/core/icon/icon.html.erb
100
102
  - lib/ably_ui/core/icon/icon.rb
@@ -179,6 +181,18 @@ files:
179
181
  - lib/ably_ui/core/meganav_items_signed_in/component.js
180
182
  - lib/ably_ui/core/meganav_items_signed_in/meganav_items_signed_in.html.erb
181
183
  - lib/ably_ui/core/meganav_items_signed_in/meganav_items_signed_in.rb
184
+ - lib/ably_ui/core/meganav_search/component.js
185
+ - lib/ably_ui/core/meganav_search/meganav_search.html.erb
186
+ - lib/ably_ui/core/meganav_search/meganav_search.rb
187
+ - lib/ably_ui/core/meganav_search_autocomplete/component.js
188
+ - lib/ably_ui/core/meganav_search_autocomplete/meganav_search_autocomplete.html.erb
189
+ - lib/ably_ui/core/meganav_search_autocomplete/meganav_search_autocomplete.rb
190
+ - lib/ably_ui/core/meganav_search_panel/component.js
191
+ - lib/ably_ui/core/meganav_search_panel/meganav_search_panel.html.erb
192
+ - lib/ably_ui/core/meganav_search_panel/meganav_search_panel.rb
193
+ - lib/ably_ui/core/meganav_search_suggestions/component.js
194
+ - lib/ably_ui/core/meganav_search_suggestions/meganav_search_suggestions.html.erb
195
+ - lib/ably_ui/core/meganav_search_suggestions/meganav_search_suggestions.rb
182
196
  - lib/ably_ui/core/notice/component.css
183
197
  - lib/ably_ui/core/notice/component.js
184
198
  - lib/ably_ui/core/notice/notice.html.erb
@@ -209,7 +223,7 @@ licenses:
209
223
  - Apache-2.0
210
224
  metadata:
211
225
  source_code_uri: https://github.com/ably/ably-ui
212
- post_install_message:
226
+ post_install_message:
213
227
  rdoc_options: []
214
228
  require_paths:
215
229
  - lib
@@ -220,12 +234,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
220
234
  version: '0'
221
235
  required_rubygems_version: !ruby/object:Gem::Requirement
222
236
  requirements:
223
- - - ">="
237
+ - - ">"
224
238
  - !ruby/object:Gem::Version
225
- version: '0'
239
+ version: 1.3.1
226
240
  requirements: []
227
- rubygems_version: 3.2.3
228
- signing_key:
241
+ rubygems_version: 3.3.7
242
+ signing_key:
229
243
  specification_version: 4
230
244
  summary: Shared component library and design system for Ably Real-time Ltd (ably.com)
231
245
  test_files: []