@cfpb/cfpb-design-system 3.10.0 → 3.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (59) hide show
  1. package/CHANGELOG.md +21 -1
  2. package/dist/base/index.css +1 -1
  3. package/dist/base/index.css.map +2 -2
  4. package/dist/base/index.js +1 -1
  5. package/dist/base/index.js.map +1 -1
  6. package/dist/components/cfpb-buttons/index.css +1 -1
  7. package/dist/components/cfpb-buttons/index.css.map +2 -2
  8. package/dist/components/cfpb-buttons/index.js +1 -1
  9. package/dist/components/cfpb-buttons/index.js.map +1 -1
  10. package/dist/components/cfpb-expandables/index.css +1 -1
  11. package/dist/components/cfpb-expandables/index.css.map +2 -2
  12. package/dist/components/cfpb-expandables/index.js +1 -1
  13. package/dist/components/cfpb-expandables/index.js.map +1 -1
  14. package/dist/components/cfpb-forms/index.css +1 -1
  15. package/dist/components/cfpb-forms/index.css.map +2 -2
  16. package/dist/components/cfpb-forms/index.js +1 -1
  17. package/dist/components/cfpb-forms/index.js.map +1 -1
  18. package/dist/components/cfpb-icons/index.css +1 -1
  19. package/dist/components/cfpb-icons/index.css.map +2 -2
  20. package/dist/components/cfpb-icons/index.js +1 -1
  21. package/dist/components/cfpb-icons/index.js.map +1 -1
  22. package/dist/components/cfpb-layout/index.css +1 -1
  23. package/dist/components/cfpb-layout/index.css.map +2 -2
  24. package/dist/components/cfpb-layout/index.js +1 -1
  25. package/dist/components/cfpb-layout/index.js.map +1 -1
  26. package/dist/components/cfpb-notifications/index.css +1 -1
  27. package/dist/components/cfpb-notifications/index.css.map +2 -2
  28. package/dist/components/cfpb-notifications/index.js +1 -1
  29. package/dist/components/cfpb-notifications/index.js.map +1 -1
  30. package/dist/components/cfpb-pagination/index.css +1 -1
  31. package/dist/components/cfpb-pagination/index.css.map +2 -2
  32. package/dist/components/cfpb-pagination/index.js +1 -1
  33. package/dist/components/cfpb-pagination/index.js.map +1 -1
  34. package/dist/components/cfpb-tables/index.css +1 -1
  35. package/dist/components/cfpb-tables/index.css.map +2 -2
  36. package/dist/components/cfpb-tables/index.js +1 -1
  37. package/dist/components/cfpb-tables/index.js.map +1 -1
  38. package/dist/components/cfpb-tooltips/index.css +1 -1
  39. package/dist/components/cfpb-tooltips/index.css.map +2 -2
  40. package/dist/components/cfpb-tooltips/index.js +1 -1
  41. package/dist/components/cfpb-tooltips/index.js.map +1 -1
  42. package/dist/components/cfpb-typography/index.css +1 -1
  43. package/dist/components/cfpb-typography/index.css.map +2 -2
  44. package/dist/components/cfpb-typography/index.js +1 -1
  45. package/dist/components/cfpb-typography/index.js.map +1 -1
  46. package/dist/index.css +1 -1
  47. package/dist/index.css.map +2 -2
  48. package/dist/index.js +1 -1
  49. package/dist/index.js.map +1 -1
  50. package/dist/utilities/index.css +1 -1
  51. package/dist/utilities/index.css.map +2 -2
  52. package/dist/utilities/index.js +1 -1
  53. package/dist/utilities/index.js.map +1 -1
  54. package/package.json +1 -1
  55. package/src/abstracts/vars.scss +12 -4
  56. package/src/components/cfpb-forms/form-field.scss +9 -5
  57. package/src/components/cfpb-forms/multiselect.scss +3 -4
  58. package/src/components/cfpb-forms/select.scss +25 -11
  59. package/src/utilities/utilities.scss +3 -5
@@ -1,2 +1,2 @@
1
- (()=>{var ct=Object.defineProperty;var lt=Object.getOwnPropertySymbols;var St=Object.prototype.hasOwnProperty,Et=Object.prototype.propertyIsEnumerable;var dt=(a,e,t)=>e in a?ct(a,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):a[e]=t,ve=(a,e)=>{for(var t in e||(e={}))St.call(e,t)&&dt(a,t,e[t]);if(lt)for(var t of lt(e))Et.call(e,t)&&dt(a,t,e[t]);return a};var g=(a,e)=>{for(var t in e)ct(a,t,{get:e[t],enumerable:!0})};var we={};g(we,{default:()=>Dt});var Dt={};var ke={};g(ke,{default:()=>jt});var jt={};var Se={};g(Se,{default:()=>Ot});var Ot={};var Ee={};g(Ee,{default:()=>It});var It={};var Le={};g(Le,{default:()=>Mt});var Mt={};var De={};g(De,{default:()=>qt});var qt={};var Ae={};g(Ae,{default:()=>$t});var $t={};var je={};g(je,{default:()=>Ht});var Ht={};var Te={};g(Te,{default:()=>Gt});var Gt={};var Oe={};g(Oe,{default:()=>Ut});var Ut={};var re={bpXS:{min:0,max:600},bpSM:{min:601,max:900},bpMED:{min:901,max:1020},bpLG:{min:1021,max:1200},bpXL:{min:1201}};function ne(){let a=getComputedStyle(document.body).fontSize;return a=a===""?-1:a,parseFloat(a)}function Pt(a,e){let t=a.min,r=a.max;ne()>0&&ne()!==16&&(t=t/16*ne(),r=r/16*ne());let o=t||0,s=r||Number.POSITIVE_INFINITY;return o<=e&&e<=s}function Xt(a){let e={};a=a||window.innerWidth;let t;for(t in re)e[t]=Pt(re[t],a);return e}var se="mobile",Kt="tablet",Jt="desktop";function ze(a){let e=!1,t=Xt();return(a===se&&t.bpXS||a===Kt&&t.bpSM||a===Jt&&(t.bpMED||t.bpLG||t.bpXL))&&(e=!0),e}var B="data-js-hook",le="behavior_",Ie="state_";function D(){let a={};function e(i,o){return{}.hasOwnProperty.call(a,i)?a[i].push(o):a[i]=[o],this}function t(i,o){if(!{}.hasOwnProperty.call(a,i))return this;let s=a[i].indexOf(o);return s!==-1&&a[i].splice(s,1),this}function r(i,o){if(!{}.hasOwnProperty.call(a,i))return this;o=o||{};let s=a[i];for(let d=0,c=s.length;d<c;d++)s[d].call(this,o);return this}return this.addEventListener=e,this.removeEventListener=t,this.dispatchEvent=r,this.getRegisteredEvents=()=>a,this}function Y(a,e){if(!a)return!1;let t=a.getAttribute(B);return t?(t=t.split(" "),t.indexOf(e)>-1):!1}function A(a,e){if(Y(a,e))return e;if(e.indexOf(" ")!==-1){let r=B+" values cannot contain spaces!";throw new Error(r)}let t=a.getAttribute(B);return t!==null&&(e=t+" "+e),a.setAttribute(B,e),e}var Be=Ie+"atomic_init";function Yt(a,e){if(!a||!a.classList){let t=a+' is not valid. Check that element is a DOM node with class "'+e+'"';throw new Error(t)}return a}function Wt(a,e){let t=a.classList.contains(e)?a:a.querySelector("."+e);if(!t){let r=e+" not found on or in passed DOM node.";throw new Error(r)}return t}function q(a,e){return Yt(a,e),Wt(a,e)}function M(a){return Y(a,Be)?!1:(A(a,Be),!0)}function C(a,e,t,r={}){let o=(t||document).querySelectorAll(a),s=[],d,c;for(let p=0,m=o.length;p<m;p++)c=o[p],Y(c,Be)===!1&&(d=new e(c),d.init(r),s.push(d));return s}var Me={};g(Me,{default:()=>Qt});var Qt={};var Ne={};g(Ne,{default:()=>ta});var ta={};var qe={};g(qe,{default:()=>oa});var oa={};var Ce={};g(Ce,{default:()=>ra});var ra={};var $e={};g($e,{default:()=>sa});var sa={};var Z="o-expandable";function P(a){let e=q(a,Z),t,r,i,o,s;function d(){if(!M(e))return this;t=e.querySelector(`.${Z}__header`),r=e.querySelector(`.${Z}__content`),i=e.querySelector(`.${Z}__label`);let m=e.classList.contains(`${Z}--onload-open`);A(e,"behavior_flyout-menu"),A(t,"behavior_flyout-menu_trigger"),A(r,"behavior_flyout-menu_content");let f=m?I.CLASSES.MH_DEFAULT:I.CLASSES.MH_ZERO;return o=new I(r).init(f),s=new X(e),s.setTransition(o,o.maxHeightZero,o.maxHeightDefault),s.init(m),s.addEventListener("expandbegin",()=>{r.classList.remove("u-hidden"),this.dispatchEvent("expandbegin",{target:this})}),s.addEventListener("collapseend",()=>{r.classList.add("u-hidden")}),this}function c(){return i.textContent.trim()}this.init=d,this.expand=()=>s.expand(),this.collapse=()=>s.collapse(),this.isExpanded=()=>s.isExpanded(),this.refresh=()=>s.getTransition().refresh(),this.getLabelText=c;let p=new D;return this.addEventListener=p.addEventListener,this.removeEventListener=p.removeEventListener,this.dispatchEvent=p.dispatchEvent,this}P.BASE_CLASS=Z;P.init=a=>C(`.${P.BASE_CLASS}`,P,a);var de="o-expandable-group";function ce(a){let e=q(a,de),t=e.classList.contains(`${de}--accordion`),r,i;function o(d){let c=d.target;i&&i!==c&&i.collapse(),i=c}function s(d){return M(e)?(t&&(r=d,r.forEach(c=>{c.addEventListener("expandbegin",o)})),this):this}return this.init=s,this}ce.BASE_CLASS=de;ce.init=a=>{(a||document).querySelectorAll(`.${de}`).forEach(r=>{let i=C(`.${P.BASE_CLASS}`,P,r);new ce(r).init(i)})};var Q="o-summary";function me(a){let e=q(a,Q),t=e.classList.contains(`${Q}--mobile`),r=e.querySelector(`.${Q}__content`),i=e.querySelector(`.${Q}__btn`),o,s,d;function c(){return M(e)?(window.addEventListener("load",p),this):this}function p(){window.removeEventListener("load",p),d=!_(),A(e,"behavior_flyout-menu"),A(r,"behavior_flyout-menu_content"),A(i,"behavior_flyout-menu_trigger"),s=new X(e,!1),o=new I(r),o.init(d?I.CLASSES.MH_SUMMARY:I.CLASSES.MH_DEFAULT),s.setTransition(o,o.maxHeightSummary,o.maxHeightDefault),s.addEventListener("triggerclick",j),s.init(),x(),window.addEventListener("resize",x),"onorientationchange"in window&&window.addEventListener("orientationchange",x),e.addEventListener("focusin",m),r.addEventListener("click",f)}function m(b){!d&&b.target!==i&&(i.click(),e.removeEventListener("focusin",m))}function f(b){b.target.tagName!=="A"&&s.isExpanded()&&o.refresh()}function x(){_()?G():H()}function _(){return t&&!ze(se)||r.scrollHeight<=88}function j(){s.addEventListener("expandend",S)}function S(){T(),window.removeEventListener("resize",x),window.removeEventListener("orientationchange",x),s.removeEventListener("expandend",S),s.suspend(),o.remove()}function E(){i.classList.remove("u-hidden")}function T(){i.classList.add("u-hidden")}function H(){return d&&(s.collapse(),o.animateOn(),E(),d=!1),!d}function G(){return d||(o.animateOff(),s.expand(),T(),d=!0),d}let z=new D;return this.addEventListener=z.addEventListener,this.removeEventListener=z.removeEventListener,this.dispatchEvent=z.dispatchEvent,this.init=c,this}me.BASE_CLASS=Q;me.init=a=>C(`.${Q}`,me,a);var ee="o-summary-minimal";function he(a){let e=q(a,ee),t=e.querySelector(`.${ee}__content`),r=e.querySelector(`.${ee}__btn`),i,o;function s(){return M(e)?(A(e,"behavior_flyout-menu"),A(t,"behavior_flyout-menu_content"),A(r,"behavior_flyout-menu_trigger"),window.addEventListener("load",d),this):this}function d(){window.removeEventListener("load",d),o=new X(e,!1),i=new I(t),i.init(I.CLASSES.MH_SUMMARY),o.setTransition(i,i.maxHeightSummary,i.maxHeightDefault),o.init(),e.addEventListener("focusin",c),t.addEventListener("click",p),o.collapse(),i.animateOn()}function c(f){f.target!==r&&(r.click(),e.removeEventListener("focusin",c))}function p(f){f.target.tagName!=="A"&&o.isExpanded()&&i.refresh()}let m=new D;return this.addEventListener=m.addEventListener,this.removeEventListener=m.removeEventListener,this.dispatchEvent=m.dispatchEvent,this.init=s,this}he.BASE_CLASS=ee;he.init=a=>C(`.${ee}`,he,a);var Fe={};g(Fe,{default:()=>ca});var ca={};var He={};g(He,{default:()=>ha});var ha={};var Ve={};g(Ve,{default:()=>ua});var ua={};var Ge={};g(Ge,{default:()=>ga});var ga={};var Re={};g(Re,{default:()=>xa});var xa={};var Ue={};g(Ue,{default:()=>_a});var _a={};var Pe={};g(Pe,{default:()=>wa});var wa={};var Xe={};g(Xe,{default:()=>Sa});var Sa={};var Ke={};g(Ke,{default:()=>La});var La={};var Je={};g(Je,{default:()=>Aa});var Aa={};var Ye={};g(Ye,{default:()=>Ta});var Ta={};var We={};g(We,{default:()=>za});var za={};var Ze={};g(Ze,{default:()=>Ba});var Ba={};var Qe={};g(Qe,{default:()=>Na});var Na={};var et={};g(et,{default:()=>Ca});var Ca={};var tt={};g(tt,{default:()=>Fa});var Fa={};var at={};g(at,{default:()=>Va});var Va={};var ot={};g(ot,{default:()=>Ra});var Ra={};var it={};g(it,{default:()=>Pa});var Pa={};var rt={};g(rt,{default:()=>Ka});var Ka={};function pe(a,e){let t;if(Y(a,e))return t=a,t;if(a){let r="["+B+"="+e+"]";t=a.querySelector(r)}if(!t){let r=e+" behavior not found on passed DOM node!";throw new Error(r)}return t}var Ja=Object.prototype.toString;var Ya=Array.isArray||function(e){return Ja.call(e)==="[object Array]"};function nt(){return!!new RegExp(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i).test(navigator.userAgent)}var te=le+"flyout-menu",Wa="["+B+"="+te;function X(a,e=!0){let t=pe(a,te),r=H(a),i=pe(a,te+"_content"),o=0,s=0,d=1,c=2,p=3,m,f,x,_=W.bind(this),j=R.bind(this),S,E=!0,T=!1;function H(n){let l=[],h=n.querySelectorAll(`${Wa}_trigger]`),u,k,U;for(let V=h.length>>>0;V--;){for(U=!1,u=h[V],k=u.parentElement;k!==n;)k.getAttribute(B)&&k.getAttribute(B).split(" ").indexOf(te)!==-1?(U=!0,k=n):k=k.parentElement;U||l.unshift(h[V])}return l}function G(n=!1){return o=n?p:s,r.forEach(l=>{z("expanded",l,n),l.addEventListener("click",y.bind(this)),l.addEventListener("touchstart",b,{passive:!0}),l.addEventListener("mouseover",w.bind(this)),l.addEventListener("mouseout",L.bind(this))}),i.setAttribute("data-open",n?"true":"false"),e&&!n&&i.setAttribute("hidden",""),ie(),this}function z(n,l,h){let u=String(h);return l.setAttribute("aria-"+n,u),u}function b(){T=!0}function w(n){E||(T||this.dispatchEvent("triggerover",{target:this,trigger:n.target,type:"triggerover"}),T=!1)}function L(n){E||this.dispatchEvent("triggerout",{target:this,trigger:n.target,type:"triggerout"})}function y(n){if(!E)switch(this.dispatchEvent("triggerclick",{target:this,trigger:n.target,type:"triggerclick"}),n.preventDefault(),o){case s:case d:this.expand();break;case c:case p:this.collapse();break}}function O(){if(m==null||m.halt(),o===c||o===p)return this;if(o=c,e&&i.removeAttribute("hidden"),this.dispatchEvent("expandbegin",{target:this,type:"expandbegin"}),!f||!x)return j(),this;let n=m==null?void 0:m.isAnimated();return n&&m.addEventListener(v.END_EVENT,j),f(),n||j(),this}function N(){if(m==null||m.halt(),o===d||o===s)return this;for(let l=0,h=r.length;l<h;l++)z("expanded",r[l],!1);if(i.setAttribute("data-open","false"),o=d,this.dispatchEvent("collapsebegin",{target:this,type:"collapsebegin"}),!x||!f)return _(),this;let n=m==null?void 0:m.isAnimated();return n&&m.addEventListener(v.END_EVENT,_),x(),n||_(),this}function R(){o=p,i.setAttribute("data-open","true"),m&&m.removeEventListener(v.END_EVENT,j),this.dispatchEvent("expandend",{target:this,type:"expandend"});for(let n=0,l=r.length;n<l;n++)z("expanded",r[n],!0)}function W(){o=s,e&&i.setAttribute("hidden",""),m&&m.removeEventListener(v.END_EVENT,_),this.dispatchEvent("collapseend",{target:this,type:"collapseend"})}function oe(n,l,h){m=n,l&&l!==x&&(x=l),h&&h!==f&&(f=h)}function fe(){m&&m.remove();let n;m=n,f=n,x=n}function xe(){return{container:t,content:i,trigger:r}}function ie(){return E&&(E=!1),!E}function ye(){return E||(E=!0),E}function _e(n){return S=n,this}let J=new D;return this.addEventListener=J.addEventListener,this.removeEventListener=J.removeEventListener,this.dispatchEvent=J.dispatchEvent,this.init=G,this.expand=O,this.collapse=N,this.setTransition=oe,this.clearTransition=fe,this.getData=()=>S,this.getTransition=()=>m,this.getDom=xe,this.isAnimating=()=>o===c||o===d,this.isExpanded=()=>o===p,this.resume=ie,this.setData=_e,this.suspend=ye,X.BASE_CLASS=te,this}var ue={CSS_PROPERTY:"opacity",BASE_CLASS:"u-alpha-transition",ALPHA_100:"u-alpha-100",ALPHA_0:"u-alpha-0"};function ut(a){let e=new D,t=new v(a,ue,this);function r(s){return t.init(s),this}function i(){return t.applyClass(ue.ALPHA_100),this}function o(){return t.applyClass(ue.ALPHA_0),this}return this.addEventListener=e.addEventListener,this.dispatchEvent=e.dispatchEvent,this.removeEventListener=e.removeEventListener,this.animateOff=t.animateOff,this.animateOn=t.animateOn,this.halt=t.halt,this.isAnimated=t.isAnimated,this.remove=t.remove,this.setElement=t.setElement,this.fadeIn=i,this.fadeOut=o,this.init=r,this}ut.CLASSES=ue;function v(a,e,t){let r=e,i=a;if(!t)throw new Error("Child transition argument must be defined!");let o=t,s,d,c,p=!1,m=!1,f=!1;if(typeof r.CSS_PROPERTY=="undefined"||typeof r.BASE_CLASS=="undefined")throw new Error("Transitions require CSS_PROPERTY and BASE_CLASS to be passed into BaseTransition.");function x(){d&&p?(i.addEventListener(d,c),o.dispatchEvent(v.BEGIN_EVENT,{target:o,type:v.BEGIN_EVENT}),i.classList.add(v.ANIMATING_CLASS),m=!0):(o.dispatchEvent(v.BEGIN_EVENT,{target:o,type:v.BEGIN_EVENT}),c())}function _(){i.removeEventListener(d,c)}function j(y){return y&&y.propertyName!==r.CSS_PROPERTY?!1:(_(),i.classList.remove(v.ANIMATING_CLASS),o.dispatchEvent(v.END_EVENT,{target:o,type:v.END_EVENT}),m=!1,!0)}function S(){let y;for(y in r)({}).hasOwnProperty.call(r,y)&&r[y]!==r.BASE_CLASS&&i.classList.contains(r[y])&&i.classList.remove(r[y])}function E(){m&&(i.style.webkitTransitionDuration="0",i.style.mozTransitionDuration="0",i.style.oTransitionDuration="0",i.style.transitionDuration="0",i.removeEventListener(d,c),c(),i.style.webkitTransitionDuration="",i.style.mozTransitionDuration="",i.style.oTransitionDuration="",i.style.transitionDuration="")}function T(){E(),S(),i.classList.remove(r.BASE_CLASS)}function H(){i.classList.remove(v.NO_ANIMATION_CLASS),p=!0}function G(){i.classList.add(v.NO_ANIMATION_CLASS),p=!1}function z(y){if(!y){let W="Element does not have TransitionEnd event. It may be null!";throw new Error(W)}let O,N={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"},R;for(R in N)if({}.hasOwnProperty.call(N,R)&&typeof y.style[R]!="undefined"){O=N[R];break}return O}function b(y){T(),H(),i=y,i.classList.add(r.BASE_CLASS),d=z(i)}function w(y){if(p=!i.classList.contains(v.NO_ANIMATION_CLASS),c=j.bind(this),b(i),!y)throw new Error("Transition needs to be passed an initial CSS class on initialization!");return i.classList.add(y),this}function L(y){return f||(S(),f=!0),i.classList.contains(y)?!1:(_(),i.classList.remove(s),s=y,x(),i.classList.add(s),!0)}return this.animateOff=G,this.animateOn=H,this.applyClass=L,this.halt=E,this.init=w,this.isAnimated=()=>p,this.remove=T,this.setElement=b,this}v.BEGIN_EVENT="transitionbegin";v.END_EVENT="transitionend";v.NO_ANIMATION_CLASS="u-no-animation";v.ANIMATING_CLASS="u-is-animating";var ae={CSS_PROPERTY:"max-height",BASE_CLASS:"u-max-height-transition",MH_DEFAULT:"u-max-height-default",MH_SUMMARY:"u-max-height-summary",MH_ZERO:"u-max-height-zero"};function I(a){let e=new D,t=new v(a,ae,this),r=0;function i(){let x=a.scrollHeight+"px";a.style.maxHeight=x}function o(){window.removeEventListener("load",o),i()}function s(f){return t.init(f),window.addEventListener("load",o),window.addEventListener("resize",()=>{i()}),this}function d(){return i(),t.applyClass(ae.MH_DEFAULT),(!r||a.scrollHeight>r)&&(r=a.scrollHeight),this}function c(){return t.applyClass(ae.MH_SUMMARY),r=a.scrollHeight,this}function p(){return t.applyClass(ae.MH_ZERO),r=a.scrollHeight,this}function m(){return a.style.maxHeight="",t.remove()}return this.addEventListener=e.addEventListener,this.dispatchEvent=e.dispatchEvent,this.removeEventListener=e.removeEventListener,this.animateOff=t.animateOff,this.animateOn=t.animateOn,this.halt=t.halt,this.isAnimated=t.isAnimated,this.setElement=t.setElement,this.refresh=i,this.remove=m,this.init=s,this.maxHeightDefault=d,this.maxHeightSummary=c,this.maxHeightZero=p,this}I.CLASSES=ae;var K={CSS_PROPERTY:"transform",BASE_CLASS:"u-move-transition",MOVE_TO_ORIGIN:"u-move-to-origin",MOVE_LEFT:"u-move-left",MOVE_LEFT_2X:"u-move-left-2x",MOVE_LEFT_3X:"u-move-left-3x",MOVE_RIGHT:"u-move-right",MOVE_UP:"u-move-up"};function bt(a){let e=new D,t=new v(a,K,this);function r(c){return t.init(c),this}function i(){return t.applyClass(K.MOVE_TO_ORIGIN),this}function o(c){c=c||1;let p=[K.MOVE_LEFT,K.MOVE_LEFT_2X,K.MOVE_LEFT_3X];return t.applyClass(p[c-1]),this}function s(){return t.applyClass(K.MOVE_RIGHT),this}function d(){return t.applyClass(K.MOVE_UP),this}return this.addEventListener=e.addEventListener,this.dispatchEvent=e.dispatchEvent,this.removeEventListener=e.removeEventListener,this.animateOff=t.animateOff,this.animateOn=t.animateOn,this.halt=t.halt,this.isAnimated=t.isAnimated,this.setElement=t.setElement,this.remove=t.remove,this.init=r,this.moveLeft=()=>o(1),this.moveLeft2=()=>o(2),this.moveLeft3=()=>o(3),this.moveRight=s,this.moveToOrigin=i,this.moveUp=d,this}bt.CLASSES=K;var Qa;function eo(a){return a.replace(/[-\\^$*+?.()|[\]{}]/g,"\\$&")}function to(a,e){return RegExp(eo(e.trim()),"i").test(a)}function ao(a,e,t){let r=a,i=e,o=(t==null?void 0:t.maxSelections)||5,s=[],d=[],c=[],p=[],m=-1;function f(b){return i+"-"+b.value.trim().replace(/\s+/g,"-").toLowerCase()}function x(){return d.length>=o}function _(b){let w,L=[],y=!1;for(let O=0,N=b.length;O<N;O++)w=b[O],y=x()?!1:w.defaultSelected,L.push({id:f(w),value:w.value,text:w.text,checked:y}),y&&d.push(O);return L}function j(){return s=_(r),this}function S(b){return s[b].checked=!s[b].checked,d.length<o&&s[b].checked?(d.push(b),d.sort(),!0):(s[b].checked=!1,d=d.filter(function(w){return w!==b}),!1)}function E(b,w,L,y){return to(w.text,y)&&b.push(L),b}function T(b){return Object.prototype.toString.call(b)!=="[object String]"&&(b=""),p=c,s.length>0&&(c=s.reduce(function(w,L,y){return E(w,L,y,b)},[])),m=-1,c}function H(b){return s[b]}function G(b){let w=c.length,L=w===0?s.length:w;b<0?m=-1:b>=L?m=L-1:m=b}function z(){return m}return this.init=j,this.toggleOption=S,this.getSelectedIndices=function(){return d},this.isAtMaxSelections=x,this.filterIndices=T,this.clearFilter=function(){return c=p=[],Qa},this.getFilterIndices=function(){return c},this.getLastFilterIndices=function(){return p},this.getIndex=z,this.setIndex=G,this.resetIndex=function(){return m=-1,m},this.getOption=H,this}var gt=ao;function $(a,e,t){let r=document.createElement(a);return Object.keys(t).forEach(i=>{let o=t[i];i in r?r[i]=o:r.setAttribute(i,o)}),e&&e.appendChild(r),r}var ft='<svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" class="cf-icon-svg cf-icon-svg--error" viewBox="0 0 12 19"><path d="M11.383 13.644A1.03 1.03 0 0 1 9.928 15.1L6 11.172 2.072 15.1a1.03 1.03 0 1 1-1.455-1.456l3.928-3.928L.617 5.79a1.03 1.03 0 1 1 1.455-1.456L6 8.261l3.928-3.928a1.03 1.03 0 0 1 1.455 1.456L7.455 9.716z"/></svg>';var so=ft,F="o-multiselect",lo="a-checkbox",co="a-text-input",xt="prev",be="next",st="Enter",mo=" ",yt="Escape",ho="ArrowUp",_t="ArrowDown",vt="Tab",wt={renderTags:!0,maxSelections:5};function ge(a){a.classList.add(F);let e=q(a,F),t=!1,r,i,o,s,d,c,p,m,f,x,_,j=[],S;function E(){_.classList.remove("u-no-results"),_.classList.add("u-filtered");let n=o.getLastFilterIndices();for(let l=0,h=n.length;l<h;l++)j[n[l]].classList.remove("u-filter-match");n=o.getFilterIndices();for(let l=0,h=n.length;l<h;l++)j[n[l]].classList.add("u-filter-match")}function T(){_.classList.remove("u-filtered","u-no-results");for(let n=0,l=_.children.length;n<l;n++)_.children[n].classList.remove("u-filter-match");o.clearFilter()}function H(){_.classList.add("u-no-results"),_.classList.remove("u-filtered")}function G(n){return n.length>0?(E(),!0):(H(),!1)}function z(n){T(),o.resetIndex();let l=o.filterIndices(n);G(l)}function b(){return c.classList.add("u-active"),x.classList.remove("u-invisible"),x.setAttribute("aria-hidden",!1),S.dispatchEvent("expandbegin",{target:S}),S}function w(){return c.classList.remove("u-active"),x.classList.add("u-invisible"),x.setAttribute("aria-hidden",!0),o.resetIndex(),S.dispatchEvent("collapsebegin",{target:S}),S}function L(n){n===be?o.setIndex(o.getIndex()+1):n===xt&&o.setIndex(o.getIndex()-1);let l=o.getIndex();if(l>-1){let h=l,u=o.getFilterIndices();u.length>0&&(h=u[l]);let U=o.getOption(h).value,kt=_.querySelector('[data-option="'+U+'"]').querySelector("input");t=!0,kt.focus()}else t=!1,f.focus()}function y(){f.value="",T()}function O(n){let l=n.target;l.tagName==="BUTTON"&&(n.preventDefault(),l.removeEventListener("click",O),l.querySelector("label").click())}function N(n){if(n.key===mo||n.key===st){let l=n.target.querySelector("label");_.querySelector("#"+l.getAttribute("for")).click()}}function R(n){return r+"-"+n.value.trim().replace(/[^\w]/g,"-").toLowerCase()}function W(n,l){let h=R(l),u=$("li",null,{"data-option":l.value}),k=$("button",u,{type:"button",class:"a-tag-filter",innerHTML:"<label for="+h+">"+l.text+so+"</label>"});n.appendChild(u),k.addEventListener("click",O),k.addEventListener("keydown",N)}function oe(n){let l=o.getOption(n)||o.getOption(o.getIndex());if(l){if(l.checked){_.classList.contains("u-max-selections")&&_.classList.remove("u-max-selections");let h='[data-option="'+l.value+'"]',u=p.querySelector(h);typeof u!="undefined"&&u&&(p==null||p.removeChild(u))}else d!=null&&d.renderTags&&p&&W(p,l);o.toggleOption(n),o.isAtMaxSelections()&&_.classList.add("u-max-selections"),S.dispatchEvent("selectionsupdated",{target:S})}o.resetIndex(),t=!1,x.getAttribute("aria-hidden")==="false"&&f.focus()}function fe(n){oe(Number(n.target.getAttribute("data-index"))),y()}function xe(){m.addEventListener("mousemove",function(h){let u=h.target;h.offsetX>u.offsetWidth-35?u.style.cursor="pointer":u.style.cursor="auto"}),m.addEventListener("mouseup",function(h){let u=h.target;h.offsetX>u.offsetWidth-35&&x.offsetHeight===140&&f.blur()}),f.addEventListener("input",function(){z(this.value)}),f.addEventListener("focus",function(){x.getAttribute("aria-hidden")==="true"&&b()}),f.addEventListener("blur",function(){!t&&x.getAttribute("aria-hidden")==="false"&&w()}),f.addEventListener("keydown",function(h){let u=h.key;x.getAttribute("aria-hidden")==="true"&&u!==vt&&b(),u===st?(h.preventDefault(),L(be)):u===yt?(y(),w()):u===_t?L(be):u===vt&&!h.shiftKey&&x.getAttribute("aria-hidden")==="false"&&w()}),_.addEventListener("mousedown",function(){t=!0}),_.addEventListener("keydown",function(h){let u=h.key,k=h.target,U=k.checked;if(u===st){h.preventDefault(),k.checked=!U;let V=new Event("change",{bubbles:!1,cancelable:!0});k.dispatchEvent(V)}else u===yt?(f.focus(),w()):u===ho?L(xt):u===_t&&L(be)}),x.addEventListener("mousedown",function(h){h.target.tagName==="LABEL"&&(t=!0)});let n=_.querySelectorAll("input");for(let h=0,u=n.length;h<u;h++)n[h].addEventListener("change",fe);let l=p.querySelectorAll("button");for(let h=0,u=l.length;h<u;h++)l[h].addEventListener("click",O),l[h].addEventListener("keydown",N)}function ie(){c=document.createElement("div"),c.className=F,p=$("ul",null,{className:"m-tag-group"}),m=$("header",c,{className:F+"__header"}),f=$("input",m,{className:F+"__search "+co,type:"text",placeholder:i||"Select up to five",id:e.id,autocomplete:"off"}),x=$("fieldset",c,{className:F+"__fieldset u-invisible","aria-hidden":"true"});let n=F+"__options";o.isAtMaxSelections()&&(n+=" u-max-selections"),_=$("ul",x,{className:n});let l,h,u;for(let k=0,U=s.length;k<U;k++){l=s[k],h=R(l),u=o.getOption(k).checked;let V=$("li",_,{"data-option":l.value,"data-cy":"multiselect-option",class:"m-form-field m-form-field--checkbox"});$("input",V,{id:h,type:"checkbox",value:l.value,name:r,class:lo+" "+F+"__checkbox",checked:u,"data-index":k}),$("label",V,{for:h,textContent:l.text,className:F+"__label a-label"}),j.push(V),u&&(d!=null&&d.renderTags)&&W(p,l)}return c.insertBefore(p,m),e.parentNode.insertBefore(c,e),c.appendChild(e),c}function ye(n=wt){if(!M(e))return this;if(nt())return this;if(S=this,r=e.name||e.id,i=e.getAttribute("placeholder"),s=e.options||[],d=ve(ve({},wt),n),s.length>0){o=new gt(s,r,d).init();let l=ie();e.parentNode.removeChild(e),e=l,M(e),xe()}return this}function _e(){return o}this.init=ye,this.expand=b,this.collapse=w;let J=new D;return this.addEventListener=J.addEventListener,this.removeEventListener=J.removeEventListener,this.dispatchEvent=J.dispatchEvent,this.getModel=_e,this.updateSelections=oe,this.selectionClickHandler=O,this.selectionKeyDownHandler=N,this}ge.BASE_CLASS=F;ge.init=a=>C(`.${F}`,ge,void 0,a);})();
1
+ (()=>{var ct=Object.defineProperty;var lt=Object.getOwnPropertySymbols;var St=Object.prototype.hasOwnProperty,Et=Object.prototype.propertyIsEnumerable;var dt=(a,e,t)=>e in a?ct(a,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):a[e]=t,_e=(a,e)=>{for(var t in e||(e={}))St.call(e,t)&&dt(a,t,e[t]);if(lt)for(var t of lt(e))Et.call(e,t)&&dt(a,t,e[t]);return a};var g=(a,e)=>{for(var t in e)ct(a,t,{get:e[t],enumerable:!0})};var we={};g(we,{default:()=>Dt});var Dt={};var ke={};g(ke,{default:()=>jt});var jt={};var Se={};g(Se,{default:()=>Ot});var Ot={};var Ee={};g(Ee,{default:()=>It});var It={};var Le={};g(Le,{default:()=>Mt});var Mt={};var De={};g(De,{default:()=>qt});var qt={};var Ae={};g(Ae,{default:()=>$t});var $t={};var je={};g(je,{default:()=>Ht});var Ht={};var Te={};g(Te,{default:()=>Gt});var Gt={};var Oe={};g(Oe,{default:()=>Ut});var Ut={};var ie={bpXS:{min:0,max:600},bpSM:{min:601,max:900},bpMED:{min:901,max:1020},bpLG:{min:1021,max:1200},bpXL:{min:1201}};function ne(){let a=getComputedStyle(document.body).fontSize;return a=a===""?-1:a,parseFloat(a)}function Pt(a,e){let t=a.min,i=a.max;ne()>0&&ne()!==16&&(t=t/16*ne(),i=i/16*ne());let r=t||0,s=i||Number.POSITIVE_INFINITY;return r<=e&&e<=s}function Xt(a){let e={};a=a||window.innerWidth;let t;for(t in ie)e[t]=Pt(ie[t],a);return e}var se="mobile",Kt="tablet",Jt="desktop";function ze(a){let e=!1,t=Xt();return(a===se&&t.bpXS||a===Kt&&t.bpSM||a===Jt&&(t.bpMED||t.bpLG||t.bpXL))&&(e=!0),e}var B="data-js-hook",le="behavior_",Ie="state_";function D(){let a={};function e(o,r){return{}.hasOwnProperty.call(a,o)?a[o].push(r):a[o]=[r],this}function t(o,r){if(!{}.hasOwnProperty.call(a,o))return this;let s=a[o].indexOf(r);return s!==-1&&a[o].splice(s,1),this}function i(o,r){if(!{}.hasOwnProperty.call(a,o))return this;r=r||{};let s=a[o];for(let d=0,c=s.length;d<c;d++)s[d].call(this,r);return this}return this.addEventListener=e,this.removeEventListener=t,this.dispatchEvent=i,this.getRegisteredEvents=()=>a,this}function Y(a,e){if(!a)return!1;let t=a.getAttribute(B);return t?(t=t.split(" "),t.indexOf(e)>-1):!1}function A(a,e){if(Y(a,e))return e;if(e.indexOf(" ")!==-1){let i=B+" values cannot contain spaces!";throw new Error(i)}let t=a.getAttribute(B);return t!==null&&(e=t+" "+e),a.setAttribute(B,e),e}var Be=Ie+"atomic_init";function Yt(a,e){if(!a||!a.classList){let t=a+' is not valid. Check that element is a DOM node with class "'+e+'"';throw new Error(t)}return a}function Wt(a,e){let t=a.classList.contains(e)?a:a.querySelector("."+e);if(!t){let i=e+" not found on or in passed DOM node.";throw new Error(i)}return t}function q(a,e){return Yt(a,e),Wt(a,e)}function M(a){return Y(a,Be)?!1:(A(a,Be),!0)}function C(a,e,t,i={}){let r=(t||document).querySelectorAll(a),s=[],d,c;for(let p=0,m=r.length;p<m;p++)c=r[p],Y(c,Be)===!1&&(d=new e(c),d.init(i),s.push(d));return s}var Me={};g(Me,{default:()=>Qt});var Qt={};var Ne={};g(Ne,{default:()=>ta});var ta={};var qe={};g(qe,{default:()=>ra});var ra={};var Ce={};g(Ce,{default:()=>ia});var ia={};var $e={};g($e,{default:()=>sa});var sa={};var Z="o-expandable";function P(a){let e=q(a,Z),t,i,o,r,s;function d(){if(!M(e))return this;t=e.querySelector(`.${Z}__header`),i=e.querySelector(`.${Z}__content`),o=e.querySelector(`.${Z}__label`);let m=e.classList.contains(`${Z}--onload-open`);A(e,"behavior_flyout-menu"),A(t,"behavior_flyout-menu_trigger"),A(i,"behavior_flyout-menu_content");let f=m?I.CLASSES.MH_DEFAULT:I.CLASSES.MH_ZERO;return r=new I(i).init(f),s=new X(e),s.setTransition(r,r.maxHeightZero,r.maxHeightDefault),s.init(m),s.addEventListener("expandbegin",()=>{i.classList.remove("u-hidden"),this.dispatchEvent("expandbegin",{target:this})}),s.addEventListener("collapseend",()=>{i.classList.add("u-hidden")}),this}function c(){return o.textContent.trim()}this.init=d,this.expand=()=>s.expand(),this.collapse=()=>s.collapse(),this.isExpanded=()=>s.isExpanded(),this.refresh=()=>s.getTransition().refresh(),this.getLabelText=c;let p=new D;return this.addEventListener=p.addEventListener,this.removeEventListener=p.removeEventListener,this.dispatchEvent=p.dispatchEvent,this}P.BASE_CLASS=Z;P.init=a=>C(`.${P.BASE_CLASS}`,P,a);var de="o-expandable-group";function ce(a){let e=q(a,de),t=e.classList.contains(`${de}--accordion`),i,o;function r(d){let c=d.target;o&&o!==c&&o.collapse(),o=c}function s(d){return M(e)?(t&&(i=d,i.forEach(c=>{c.addEventListener("expandbegin",r)})),this):this}return this.init=s,this}ce.BASE_CLASS=de;ce.init=a=>{(a||document).querySelectorAll(`.${de}`).forEach(i=>{let o=C(`.${P.BASE_CLASS}`,P,i);new ce(i).init(o)})};var Q="o-summary";function me(a){let e=q(a,Q),t=e.classList.contains(`${Q}--mobile`),i=e.querySelector(`.${Q}__content`),o=e.querySelector(`.${Q}__btn`),r,s,d;function c(){return M(e)?(window.addEventListener("load",p),this):this}function p(){window.removeEventListener("load",p),d=!x(),A(e,"behavior_flyout-menu"),A(i,"behavior_flyout-menu_content"),A(o,"behavior_flyout-menu_trigger"),s=new X(e,!1),r=new I(i),r.init(d?I.CLASSES.MH_SUMMARY:I.CLASSES.MH_DEFAULT),s.setTransition(r,r.maxHeightSummary,r.maxHeightDefault),s.addEventListener("triggerclick",j),s.init(),v(),window.addEventListener("resize",v),"onorientationchange"in window&&window.addEventListener("orientationchange",v),e.addEventListener("focusin",m),i.addEventListener("click",f)}function m(b){!d&&b.target!==o&&(o.click(),e.removeEventListener("focusin",m))}function f(b){b.target.tagName!=="A"&&s.isExpanded()&&r.refresh()}function v(){x()?G():H()}function x(){return t&&!ze(se)||i.scrollHeight<=88}function j(){s.addEventListener("expandend",S)}function S(){T(),window.removeEventListener("resize",v),window.removeEventListener("orientationchange",v),s.removeEventListener("expandend",S),s.suspend(),r.remove()}function E(){o.classList.remove("u-hidden")}function T(){o.classList.add("u-hidden")}function H(){return d&&(s.collapse(),r.animateOn(),E(),d=!1),!d}function G(){return d||(r.animateOff(),s.expand(),T(),d=!0),d}let z=new D;return this.addEventListener=z.addEventListener,this.removeEventListener=z.removeEventListener,this.dispatchEvent=z.dispatchEvent,this.init=c,this}me.BASE_CLASS=Q;me.init=a=>C(`.${Q}`,me,a);var ee="o-summary-minimal";function he(a){let e=q(a,ee),t=e.querySelector(`.${ee}__content`),i=e.querySelector(`.${ee}__btn`),o,r;function s(){return M(e)?(A(e,"behavior_flyout-menu"),A(t,"behavior_flyout-menu_content"),A(i,"behavior_flyout-menu_trigger"),window.addEventListener("load",d),this):this}function d(){window.removeEventListener("load",d),r=new X(e,!1),o=new I(t),o.init(I.CLASSES.MH_SUMMARY),r.setTransition(o,o.maxHeightSummary,o.maxHeightDefault),r.init(),e.addEventListener("focusin",c),t.addEventListener("click",p),r.collapse(),o.animateOn()}function c(f){f.target!==i&&(i.click(),e.removeEventListener("focusin",c))}function p(f){f.target.tagName!=="A"&&r.isExpanded()&&o.refresh()}let m=new D;return this.addEventListener=m.addEventListener,this.removeEventListener=m.removeEventListener,this.dispatchEvent=m.dispatchEvent,this.init=s,this}he.BASE_CLASS=ee;he.init=a=>C(`.${ee}`,he,a);var Fe={};g(Fe,{default:()=>ca});var ca={};var He={};g(He,{default:()=>ha});var ha={};var Ve={};g(Ve,{default:()=>ua});var ua={};var Ge={};g(Ge,{default:()=>ga});var ga={};var Re={};g(Re,{default:()=>va});var va={};var Ue={};g(Ue,{default:()=>xa});var xa={};var Pe={};g(Pe,{default:()=>wa});var wa={};var Xe={};g(Xe,{default:()=>Sa});var Sa={};var Ke={};g(Ke,{default:()=>La});var La={};var Je={};g(Je,{default:()=>Aa});var Aa={};var Ye={};g(Ye,{default:()=>Ta});var Ta={};var We={};g(We,{default:()=>za});var za={};var Ze={};g(Ze,{default:()=>Ba});var Ba={};var Qe={};g(Qe,{default:()=>Na});var Na={};var et={};g(et,{default:()=>Ca});var Ca={};var tt={};g(tt,{default:()=>Fa});var Fa={};var at={};g(at,{default:()=>Va});var Va={};var rt={};g(rt,{default:()=>Ra});var Ra={};var ot={};g(ot,{default:()=>Pa});var Pa={};var it={};g(it,{default:()=>Ka});var Ka={};function pe(a,e){let t;if(Y(a,e))return t=a,t;if(a){let i="["+B+"="+e+"]";t=a.querySelector(i)}if(!t){let i=e+" behavior not found on passed DOM node!";throw new Error(i)}return t}var Ja=Object.prototype.toString;var Ya=Array.isArray||function(e){return Ja.call(e)==="[object Array]"};function nt(){return!!new RegExp(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i).test(navigator.userAgent)}var te=le+"flyout-menu",Wa="["+B+"="+te;function X(a,e=!0){let t=pe(a,te),i=H(a),o=pe(a,te+"_content"),r=0,s=0,d=1,c=2,p=3,m,f,v,x=W.bind(this),j=R.bind(this),S,E=!0,T=!1;function H(n){let l=[],h=n.querySelectorAll(`${Wa}_trigger]`),u,k,U;for(let V=h.length>>>0;V--;){for(U=!1,u=h[V],k=u.parentElement;k!==n;)k.getAttribute(B)&&k.getAttribute(B).split(" ").indexOf(te)!==-1?(U=!0,k=n):k=k.parentElement;U||l.unshift(h[V])}return l}function G(n=!1){return r=n?p:s,i.forEach(l=>{z("expanded",l,n),l.addEventListener("click",y.bind(this)),l.addEventListener("touchstart",b,{passive:!0}),l.addEventListener("mouseover",w.bind(this)),l.addEventListener("mouseout",L.bind(this))}),o.setAttribute("data-open",n?"true":"false"),e&&!n&&o.setAttribute("hidden",""),oe(),this}function z(n,l,h){let u=String(h);return l.setAttribute("aria-"+n,u),u}function b(){T=!0}function w(n){E||(T||this.dispatchEvent("triggerover",{target:this,trigger:n.target,type:"triggerover"}),T=!1)}function L(n){E||this.dispatchEvent("triggerout",{target:this,trigger:n.target,type:"triggerout"})}function y(n){if(!E)switch(this.dispatchEvent("triggerclick",{target:this,trigger:n.target,type:"triggerclick"}),n.preventDefault(),r){case s:case d:this.expand();break;case c:case p:this.collapse();break}}function O(){if(m==null||m.halt(),r===c||r===p)return this;if(r=c,e&&o.removeAttribute("hidden"),this.dispatchEvent("expandbegin",{target:this,type:"expandbegin"}),!f||!v)return j(),this;let n=m==null?void 0:m.isAnimated();return n&&m.addEventListener(_.END_EVENT,j),f(),n||j(),this}function N(){if(m==null||m.halt(),r===d||r===s)return this;for(let l=0,h=i.length;l<h;l++)z("expanded",i[l],!1);if(o.setAttribute("data-open","false"),r=d,this.dispatchEvent("collapsebegin",{target:this,type:"collapsebegin"}),!v||!f)return x(),this;let n=m==null?void 0:m.isAnimated();return n&&m.addEventListener(_.END_EVENT,x),v(),n||x(),this}function R(){r=p,o.setAttribute("data-open","true"),m&&m.removeEventListener(_.END_EVENT,j),this.dispatchEvent("expandend",{target:this,type:"expandend"});for(let n=0,l=i.length;n<l;n++)z("expanded",i[n],!0)}function W(){r=s,e&&o.setAttribute("hidden",""),m&&m.removeEventListener(_.END_EVENT,x),this.dispatchEvent("collapseend",{target:this,type:"collapseend"})}function re(n,l,h){m=n,l&&l!==v&&(v=l),h&&h!==f&&(f=h)}function fe(){m&&m.remove();let n;m=n,f=n,v=n}function ve(){return{container:t,content:o,trigger:i}}function oe(){return E&&(E=!1),!E}function ye(){return E||(E=!0),E}function xe(n){return S=n,this}let J=new D;return this.addEventListener=J.addEventListener,this.removeEventListener=J.removeEventListener,this.dispatchEvent=J.dispatchEvent,this.init=G,this.expand=O,this.collapse=N,this.setTransition=re,this.clearTransition=fe,this.getData=()=>S,this.getTransition=()=>m,this.getDom=ve,this.isAnimating=()=>r===c||r===d,this.isExpanded=()=>r===p,this.resume=oe,this.setData=xe,this.suspend=ye,X.BASE_CLASS=te,this}var ue={CSS_PROPERTY:"opacity",BASE_CLASS:"u-alpha-transition",ALPHA_100:"u-alpha-100",ALPHA_0:"u-alpha-0"};function ut(a){let e=new D,t=new _(a,ue,this);function i(s){return t.init(s),this}function o(){return t.applyClass(ue.ALPHA_100),this}function r(){return t.applyClass(ue.ALPHA_0),this}return this.addEventListener=e.addEventListener,this.dispatchEvent=e.dispatchEvent,this.removeEventListener=e.removeEventListener,this.animateOff=t.animateOff,this.animateOn=t.animateOn,this.halt=t.halt,this.isAnimated=t.isAnimated,this.remove=t.remove,this.setElement=t.setElement,this.fadeIn=o,this.fadeOut=r,this.init=i,this}ut.CLASSES=ue;function _(a,e,t){let i=e,o=a;if(!t)throw new Error("Child transition argument must be defined!");let r=t,s,d,c,p=!1,m=!1,f=!1;if(typeof i.CSS_PROPERTY=="undefined"||typeof i.BASE_CLASS=="undefined")throw new Error("Transitions require CSS_PROPERTY and BASE_CLASS to be passed into BaseTransition.");function v(){d&&p?(o.addEventListener(d,c),r.dispatchEvent(_.BEGIN_EVENT,{target:r,type:_.BEGIN_EVENT}),o.classList.add(_.ANIMATING_CLASS),m=!0):(r.dispatchEvent(_.BEGIN_EVENT,{target:r,type:_.BEGIN_EVENT}),c())}function x(){o.removeEventListener(d,c)}function j(y){return y&&y.propertyName!==i.CSS_PROPERTY?!1:(x(),o.classList.remove(_.ANIMATING_CLASS),r.dispatchEvent(_.END_EVENT,{target:r,type:_.END_EVENT}),m=!1,!0)}function S(){let y;for(y in i)({}).hasOwnProperty.call(i,y)&&i[y]!==i.BASE_CLASS&&o.classList.contains(i[y])&&o.classList.remove(i[y])}function E(){m&&(o.style.webkitTransitionDuration="0",o.style.mozTransitionDuration="0",o.style.oTransitionDuration="0",o.style.transitionDuration="0",o.removeEventListener(d,c),c(),o.style.webkitTransitionDuration="",o.style.mozTransitionDuration="",o.style.oTransitionDuration="",o.style.transitionDuration="")}function T(){E(),S(),o.classList.remove(i.BASE_CLASS)}function H(){o.classList.remove(_.NO_ANIMATION_CLASS),p=!0}function G(){o.classList.add(_.NO_ANIMATION_CLASS),p=!1}function z(y){if(!y){let W="Element does not have TransitionEnd event. It may be null!";throw new Error(W)}let O,N={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"},R;for(R in N)if({}.hasOwnProperty.call(N,R)&&typeof y.style[R]!="undefined"){O=N[R];break}return O}function b(y){T(),H(),o=y,o.classList.add(i.BASE_CLASS),d=z(o)}function w(y){if(p=!o.classList.contains(_.NO_ANIMATION_CLASS),c=j.bind(this),b(o),!y)throw new Error("Transition needs to be passed an initial CSS class on initialization!");return o.classList.add(y),this}function L(y){return f||(S(),f=!0),o.classList.contains(y)?!1:(x(),o.classList.remove(s),s=y,v(),o.classList.add(s),!0)}return this.animateOff=G,this.animateOn=H,this.applyClass=L,this.halt=E,this.init=w,this.isAnimated=()=>p,this.remove=T,this.setElement=b,this}_.BEGIN_EVENT="transitionbegin";_.END_EVENT="transitionend";_.NO_ANIMATION_CLASS="u-no-animation";_.ANIMATING_CLASS="u-is-animating";var ae={CSS_PROPERTY:"max-height",BASE_CLASS:"u-max-height-transition",MH_DEFAULT:"u-max-height-default",MH_SUMMARY:"u-max-height-summary",MH_ZERO:"u-max-height-zero"};function I(a){let e=new D,t=new _(a,ae,this),i=0;function o(){let v=a.scrollHeight+"px";a.style.maxHeight=v}function r(){window.removeEventListener("load",r),o()}function s(f){return t.init(f),window.addEventListener("load",r),window.addEventListener("resize",()=>{o()}),this}function d(){return o(),t.applyClass(ae.MH_DEFAULT),(!i||a.scrollHeight>i)&&(i=a.scrollHeight),this}function c(){return t.applyClass(ae.MH_SUMMARY),i=a.scrollHeight,this}function p(){return t.applyClass(ae.MH_ZERO),i=a.scrollHeight,this}function m(){return a.style.maxHeight="",t.remove()}return this.addEventListener=e.addEventListener,this.dispatchEvent=e.dispatchEvent,this.removeEventListener=e.removeEventListener,this.animateOff=t.animateOff,this.animateOn=t.animateOn,this.halt=t.halt,this.isAnimated=t.isAnimated,this.setElement=t.setElement,this.refresh=o,this.remove=m,this.init=s,this.maxHeightDefault=d,this.maxHeightSummary=c,this.maxHeightZero=p,this}I.CLASSES=ae;var K={CSS_PROPERTY:"transform",BASE_CLASS:"u-move-transition",MOVE_TO_ORIGIN:"u-move-to-origin",MOVE_LEFT:"u-move-left",MOVE_LEFT_2X:"u-move-left-2x",MOVE_LEFT_3X:"u-move-left-3x",MOVE_RIGHT:"u-move-right",MOVE_UP:"u-move-up"};function bt(a){let e=new D,t=new _(a,K,this);function i(c){return t.init(c),this}function o(){return t.applyClass(K.MOVE_TO_ORIGIN),this}function r(c){c=c||1;let p=[K.MOVE_LEFT,K.MOVE_LEFT_2X,K.MOVE_LEFT_3X];return t.applyClass(p[c-1]),this}function s(){return t.applyClass(K.MOVE_RIGHT),this}function d(){return t.applyClass(K.MOVE_UP),this}return this.addEventListener=e.addEventListener,this.dispatchEvent=e.dispatchEvent,this.removeEventListener=e.removeEventListener,this.animateOff=t.animateOff,this.animateOn=t.animateOn,this.halt=t.halt,this.isAnimated=t.isAnimated,this.setElement=t.setElement,this.remove=t.remove,this.init=i,this.moveLeft=()=>r(1),this.moveLeft2=()=>r(2),this.moveLeft3=()=>r(3),this.moveRight=s,this.moveToOrigin=o,this.moveUp=d,this}bt.CLASSES=K;var Qa;function er(a){return a.replace(/[-\\^$*+?.()|[\]{}]/g,"\\$&")}function tr(a,e){return RegExp(er(e.trim()),"i").test(a)}function ar(a,e,t){let i=a,o=e,r=(t==null?void 0:t.maxSelections)||5,s=[],d=[],c=[],p=[],m=-1;function f(b){return o+"-"+b.value.trim().replace(/\s+/g,"-").toLowerCase()}function v(){return d.length>=r}function x(b){let w,L=[],y=!1;for(let O=0,N=b.length;O<N;O++)w=b[O],y=v()?!1:w.defaultSelected,L.push({id:f(w),value:w.value,text:w.text,checked:y}),y&&d.push(O);return L}function j(){return s=x(i),this}function S(b){return s[b].checked=!s[b].checked,d.length<r&&s[b].checked?(d.push(b),d.sort(),!0):(s[b].checked=!1,d=d.filter(function(w){return w!==b}),!1)}function E(b,w,L,y){return tr(w.text,y)&&b.push(L),b}function T(b){return Object.prototype.toString.call(b)!=="[object String]"&&(b=""),p=c,s.length>0&&(c=s.reduce(function(w,L,y){return E(w,L,y,b)},[])),m=-1,c}function H(b){return s[b]}function G(b){let w=c.length,L=w===0?s.length:w;b<0?m=-1:b>=L?m=L-1:m=b}function z(){return m}return this.init=j,this.toggleOption=S,this.getSelectedIndices=function(){return d},this.isAtMaxSelections=v,this.filterIndices=T,this.clearFilter=function(){return c=p=[],Qa},this.getFilterIndices=function(){return c},this.getLastFilterIndices=function(){return p},this.getIndex=z,this.setIndex=G,this.resetIndex=function(){return m=-1,m},this.getOption=H,this}var gt=ar;function $(a,e,t){let i=document.createElement(a);return Object.keys(t).forEach(o=>{let r=t[o];o in i?i[o]=r:i.setAttribute(o,r)}),e&&e.appendChild(i),i}var ft='<svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" class="cf-icon-svg cf-icon-svg--error" viewBox="0 0 12 19"><path d="M11.383 13.644A1.03 1.03 0 0 1 9.928 15.1L6 11.172 2.072 15.1a1.03 1.03 0 1 1-1.455-1.456l3.928-3.928L.617 5.79a1.03 1.03 0 1 1 1.455-1.456L6 8.261l3.928-3.928a1.03 1.03 0 0 1 1.455 1.456L7.455 9.716z"/></svg>';var sr=ft,F="o-multiselect",lr="a-checkbox",dr="a-text-input",vt="prev",be="next",st="Enter",cr=" ",yt="Escape",mr="ArrowUp",xt="ArrowDown",_t="Tab",wt={renderTags:!0,maxSelections:5};function ge(a){a.classList.add(F);let e=q(a,F),t=!1,i,o,r,s,d,c,p,m,f,v,x,j=[],S;function E(){x.classList.remove("u-no-results"),x.classList.add("u-filtered");let n=r.getLastFilterIndices();for(let l=0,h=n.length;l<h;l++)j[n[l]].classList.remove("u-filter-match");n=r.getFilterIndices();for(let l=0,h=n.length;l<h;l++)j[n[l]].classList.add("u-filter-match")}function T(){x.classList.remove("u-filtered","u-no-results");for(let n=0,l=x.children.length;n<l;n++)x.children[n].classList.remove("u-filter-match");r.clearFilter()}function H(){x.classList.add("u-no-results"),x.classList.remove("u-filtered")}function G(n){return n.length>0?(E(),!0):(H(),!1)}function z(n){T(),r.resetIndex();let l=r.filterIndices(n);G(l)}function b(){return c.classList.add("u-active"),v.classList.remove("u-invisible"),v.setAttribute("aria-hidden",!1),S.dispatchEvent("expandbegin",{target:S}),S}function w(){return c.classList.remove("u-active"),v.classList.add("u-invisible"),v.setAttribute("aria-hidden",!0),r.resetIndex(),S.dispatchEvent("collapsebegin",{target:S}),S}function L(n){n===be?r.setIndex(r.getIndex()+1):n===vt&&r.setIndex(r.getIndex()-1);let l=r.getIndex();if(l>-1){let h=l,u=r.getFilterIndices();u.length>0&&(h=u[l]);let U=r.getOption(h).value,kt=x.querySelector('[data-option="'+U+'"]').querySelector("input");t=!0,kt.focus()}else t=!1,f.focus()}function y(){f.value="",T()}function O(n){let l=n.target;l.tagName==="BUTTON"&&(n.preventDefault(),l.removeEventListener("click",O),l.querySelector("label").click())}function N(n){if(n.key===cr||n.key===st){let l=n.target.querySelector("label");x.querySelector("#"+l.getAttribute("for")).click()}}function R(n){return i+"-"+n.value.trim().replace(/[^\w]/g,"-").toLowerCase()}function W(n,l){let h=R(l),u=$("li",null,{"data-option":l.value}),k=$("button",u,{type:"button",class:"a-tag-filter",innerHTML:"<label for="+h+">"+l.text+sr+"</label>"});n.appendChild(u),k.addEventListener("click",O),k.addEventListener("keydown",N)}function re(n){let l=r.getOption(n)||r.getOption(r.getIndex());if(l){if(l.checked){x.classList.contains("u-max-selections")&&x.classList.remove("u-max-selections");let h='[data-option="'+l.value+'"]',u=p.querySelector(h);typeof u!="undefined"&&u&&(p==null||p.removeChild(u))}else d!=null&&d.renderTags&&p&&W(p,l);r.toggleOption(n),r.isAtMaxSelections()&&x.classList.add("u-max-selections"),S.dispatchEvent("selectionsupdated",{target:S})}r.resetIndex(),t=!1,v.getAttribute("aria-hidden")==="false"&&f.focus()}function fe(n){re(Number(n.target.getAttribute("data-index"))),y()}function ve(){m.addEventListener("mousemove",function(h){let u=h.target;h.offsetX>u.offsetWidth-35?u.style.cursor="pointer":u.style.cursor="auto"}),m.addEventListener("mouseup",function(h){let u=h.target;h.offsetX>u.offsetWidth-35&&v.offsetHeight===140&&f.blur()}),f.addEventListener("input",function(){z(this.value)}),f.addEventListener("focus",function(){v.getAttribute("aria-hidden")==="true"&&b()}),f.addEventListener("blur",function(){!t&&v.getAttribute("aria-hidden")==="false"&&w()}),f.addEventListener("keydown",function(h){let u=h.key;v.getAttribute("aria-hidden")==="true"&&u!==_t&&b(),u===st?(h.preventDefault(),L(be)):u===yt?(y(),w()):u===xt?L(be):u===_t&&!h.shiftKey&&v.getAttribute("aria-hidden")==="false"&&w()}),x.addEventListener("mousedown",function(){t=!0}),x.addEventListener("keydown",function(h){let u=h.key,k=h.target,U=k.checked;if(u===st){h.preventDefault(),k.checked=!U;let V=new Event("change",{bubbles:!1,cancelable:!0});k.dispatchEvent(V)}else u===yt?(f.focus(),w()):u===mr?L(vt):u===xt&&L(be)}),v.addEventListener("mousedown",function(h){h.target.tagName==="LABEL"&&(t=!0)});let n=x.querySelectorAll("input");for(let h=0,u=n.length;h<u;h++)n[h].addEventListener("change",fe);let l=p.querySelectorAll("button");for(let h=0,u=l.length;h<u;h++)l[h].addEventListener("click",O),l[h].addEventListener("keydown",N)}function oe(){c=document.createElement("div"),c.className=F,p=$("ul",null,{className:"m-tag-group"}),m=$("header",c,{className:F+"__header"}),f=$("input",m,{className:F+"__search "+dr,type:"text",placeholder:o||"Select up to five",id:e.id,autocomplete:"off"}),v=$("fieldset",c,{className:F+"__fieldset u-invisible","aria-hidden":"true"});let n=F+"__options";r.isAtMaxSelections()&&(n+=" u-max-selections"),x=$("ul",v,{className:n});let l,h,u;for(let k=0,U=s.length;k<U;k++){l=s[k],h=R(l),u=r.getOption(k).checked;let V=$("li",x,{"data-option":l.value,"data-cy":"multiselect-option",class:"m-form-field m-form-field--checkbox"});$("input",V,{id:h,type:"checkbox",value:l.value,name:i,class:lr+" "+F+"__checkbox",checked:u,"data-index":k}),$("label",V,{for:h,textContent:l.text,className:F+"__label a-label"}),j.push(V),u&&(d!=null&&d.renderTags)&&W(p,l)}return c.insertBefore(p,m),e.parentNode.insertBefore(c,e),c.appendChild(e),c}function ye(n=wt){if(!M(e))return this;if(nt())return this;if(S=this,i=e.name||e.id,o=e.getAttribute("placeholder"),s=e.options||[],d=_e(_e({},wt),n),s.length>0){r=new gt(s,i,d).init();let l=oe();e.parentNode.removeChild(e),e=l,M(e),ve()}return this}function xe(){return r}this.init=ye,this.expand=b,this.collapse=w;let J=new D;return this.addEventListener=J.addEventListener,this.removeEventListener=J.removeEventListener,this.dispatchEvent=J.dispatchEvent,this.getModel=xe,this.updateSelections=re,this.selectionClickHandler=O,this.selectionKeyDownHandler=N,this}ge.BASE_CLASS=F;ge.init=a=>C(`.${F}`,ge,void 0,a);})();
2
2
  //# sourceMappingURL=index.js.map