!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports["monday-style"]=t():e["monday-style"]=t()}(this,(function(){return(()=>{"use strict";var e={43424:(e,t,n)=>{function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var n=i(t);if(n&&n.has(e))return n.get(e);var a={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var u in e)if("default"!==u&&Object.prototype.hasOwnProperty.call(e,u)){var l=o?Object.getOwnPropertyDescriptor(e,u):null;l&&(l.get||l.set)?Object.defineProperty(a,u,l):a[u]=e[u]}a.default=e,n&&n.set(e,a);return a}(n(16689)),o=l(n(59003));n(75981);var u=l(n(98396));function l(e){return e&&e.__esModule?e:{default:e}}function i(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(i=function(e){return e?n:t})(e)}var c=(0,a.forwardRef)((function(e,t){var n=e.icon,r=void 0===n?"":n,l=e.iconLabel,i=void 0===l?"":l,c=e.labelText,d=void 0===c?"":c,s=e.labelFor,f=void 0===s?"":s,p=e.iconClassName,m=void 0===p?"":p,y=e.labelClassName,b=void 0===y?"":y;return d?a.default.createElement("section",{className:"label-component--wrapper"},a.default.createElement(u.default,{icon:r,className:(0,o.default)("label-component--icon",m),id:f,clickable:!1,iconLabel:i,iconType:u.default.type.ICON_FONT}),a.default.createElement("label",{htmlFor:f,ref:t,className:(0,o.default)("label-component--text",b)},d)):null}));c.__docgenInfo={description:"",methods:[],displayName:"FieldLabel",props:{icon:{defaultValue:{value:'""',computed:!1},required:!1},iconLabel:{defaultValue:{value:'""',computed:!1},required:!1},labelText:{defaultValue:{value:'""',computed:!1},required:!1},labelFor:{defaultValue:{value:'""',computed:!1},required:!1},iconClassName:{defaultValue:{value:'""',computed:!1},required:!1},labelClassName:{defaultValue:{value:'""',computed:!1},required:!1}}};var d=c;t.default=d},35614:(e,t,n)=>{function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var n=s(t);if(n&&n.has(e))return n.get(e);var a={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var u in e)if("default"!==u&&Object.prototype.hasOwnProperty.call(e,u)){var l=o?Object.getOwnPropertyDescriptor(e,u):null;l&&(l.get||l.set)?Object.defineProperty(a,u,l):a[u]=e[u]}a.default=e,n&&n.set(e,a);return a}(n(16689)),o=d(n(580)),u=d(n(59003)),l=d(n(23831)),i=d(n(46830)),c=["className","src","onClick","clickable","ariaLabel","ariaHidden","replaceToCurrentColor","customColor","data-testid"];function d(e){return e&&e.__esModule?e:{default:e}}function s(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(s=function(e){return e?n:t})(e)}function f(){return f=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},f.apply(this,arguments)}function p(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function m(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"currentColor";return e.replace(/fill=".*?"/g,'fill="'.concat(t,'"'))}var y=function(e){var t=e.className,n=e.src,r=e.onClick,o=e.clickable,d=e.ariaLabel,s=e.ariaHidden,y=e.replaceToCurrentColor,b=e.customColor,v=e["data-testid"],g=p(e,c),O=(0,i.default)({isClickable:o,label:d,isDecorationOnly:s}),S=(0,a.useCallback)((function(e){return y?m(e,"currentColor"):b?m(e,b):e}),[y,b]);return"string"!=typeof n?null:a.default.createElement(l.default,f({},O,{onClick:r,src:n,className:(0,u.default)("monday-style-custom-svg-icon--wrapper",t),preProcessor:S},g,{"data-testid":v}))};y.propTypes={className:o.default.string,src:o.default.oneOfType([o.default.string,o.default.object]),ariaLabel:o.default.string,ariaHidden:o.default.bool,replaceToCurrentColor:o.default.bool,customColor:o.default.string},y.defaultProps={className:"",src:"",ariaLabel:void 0,ariaHidden:void 0,replaceToCurrentColor:!1,customColor:void 0},y.__docgenInfo={description:"",methods:[],displayName:"CustomSvgIcon",props:{className:{defaultValue:{value:'""',computed:!1},type:{name:"string"},required:!1,description:""},src:{defaultValue:{value:'""',computed:!1},type:{name:"union",value:[{name:"string"},{name:"object"}]},required:!1,description:""},ariaLabel:{defaultValue:{value:"undefined",computed:!0},type:{name:"string"},required:!1,description:""},ariaHidden:{defaultValue:{value:"undefined",computed:!0},type:{name:"bool"},required:!1,description:""},replaceToCurrentColor:{defaultValue:{value:"false",computed:!1},type:{name:"bool"},required:!1,description:""},customColor:{defaultValue:{value:"undefined",computed:!0},type:{name:"string"},required:!1,description:""}}};var b=y;t.default=b},12816:(e,t,n)=>{function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a,o=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var n=l(t);if(n&&n.has(e))return n.get(e);var a={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var u in e)if("default"!==u&&Object.prototype.hasOwnProperty.call(e,u)){var i=o?Object.getOwnPropertyDescriptor(e,u):null;i&&(i.get||i.set)?Object.defineProperty(a,u,i):a[u]=e[u]}a.default=e,n&&n.set(e,a);return a}(n(16689)),u=(a=n(59003))&&a.__esModule?a:{default:a};function l(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(l=function(e){return e?n:t})(e)}var i=(0,o.forwardRef)((function(e,t){var n=e.className,r=e.onClick,a=e["aria-label"],l=e.tabIndex,i=e.icon,c=e.role,d=void 0===c?"img":c,s=e["aria-hidden"],f=e["data-testid"],p="function"==typeof i,m=p?"":i;return o.default.createElement("span",{"aria-hidden":s,className:(0,u.default)(n,"fa",m),onClick:r,ref:t,"aria-label":a,tabIndex:l,role:d,"data-testid":f},p&&i())}));i.__docgenInfo={description:"",methods:[],displayName:"FontIcon",props:{role:{defaultValue:{value:'"img"',computed:!1},required:!1}}};var c=i;t.default=c},98396:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!==m(e)&&"function"!=typeof e)return{default:e};var n=f(t);if(n&&n.has(e))return n.get(e);var r={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&Object.prototype.hasOwnProperty.call(e,o)){var u=a?Object.getOwnPropertyDescriptor(e,o):null;u&&(u.get||u.set)?Object.defineProperty(r,o,u):r[o]=e[o]}r.default=e,n&&n.set(e,r);return r}(n(16689)),a=s(n(580)),o=s(n(59003)),u=n(99634),l=s(n(35614)),i=s(n(12816)),c=s(n(57288)),d=s(n(59347));function s(e){return e&&e.__esModule?e:{default:e}}function f(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(f=function(e){return e?n:t})(e)}function p(){return p=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},p.apply(this,arguments)}function m(e){return m="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},m(e)}n(77274);var y=(0,r.forwardRef)((function(e,t){var n=e.onClick,a=e.className,s=e.icon,f=e.clickable,y=e.iconLabel,b=e.iconType,v=e.iconSize,g=e.ignoreFocusStyle,O=e.tabindex,S=e.ariaHidden,_=e.style,C=e.useCurrentColor,E=e.customColor,T=e["data-testid"],h=(0,c.default)({onClick:n,iconLabel:y,clickable:f,className:a,isDecorationOnly:S,ignoreFocusStyle:g,externalTabIndex:O}),P=h.screenReaderAccessProps,N=h.onClickCallback,j=h.computedClassName,I=h.iconRef,A=(0,d.default)({refs:[t,I]});if(!s)return null;var M="function"==typeof s;if(b===u.ICON_TYPES.SVG||M||"object"===m(s)){var k=s;return r.default.createElement(k,p({},P,{ref:M?void 0:A,size:v.toString(),onClick:n,className:j,style:_,"data-testid":T}))}return b===u.ICON_TYPES.SRC?r.default.createElement(l.default,p({src:s},P,{className:(0,o.default)(j),onClick:N,style:_,replaceToCurrentColor:C,customColor:E,"data-testid":T})):r.default.createElement(i.default,p({},P,{className:(0,o.default)(j),onClick:N,ref:A,icon:s,style:_,"data-testid":T}))}));y.type=u.ICON_TYPES,y.propTypes={onClick:a.default.func,className:a.default.string,iconType:a.default.oneOf([y.type.SVG,y.type.ICON_FONT,u.ICON_TYPES.SRC]),icon:a.default.oneOfType([a.default.string,a.default.func]),clickable:a.default.bool,iconLabel:a.default.string,iconSize:a.default.oneOfType([a.default.number,a.default.string]),ignoreFocusStyle:a.default.bool,ariaHidden:a.default.bool,useCurrentColor:a.default.bool,customColor:a.default.string},y.defaultProps={onClick:function(){},className:"",icon:"",clickable:!0,iconLabel:void 0,iconType:u.ICON_TYPES.SVG,iconSize:16,ignoreFocusStyle:!1,ariaHidden:void 0,useCurrentColor:!1,customColor:void 0},y.__docgenInfo={description:"",methods:[],displayName:"Icon",props:{onClick:{defaultValue:{value:"() => {}",computed:!1},type:{name:"func"},required:!1,description:""},className:{defaultValue:{value:'""',computed:!1},type:{name:"string"},required:!1,description:"class name to be added to icon"},icon:{defaultValue:{value:'""',computed:!1},type:{name:"union",value:[{name:"string"},{name:"func"}]},required:!1,description:"we support three types of icons - SVG, FONT and SRC (classname) so this prop is either the name of the icon or the component"},clickable:{defaultValue:{value:"true",computed:!1},type:{name:"bool"},required:!1,description:"is in used for tabIndex"},iconLabel:{defaultValue:{value:"undefined",computed:!0},type:{name:"string"},required:!1,description:"icon aria label support"},iconType:{defaultValue:{value:"ICON_TYPES.SVG",computed:!0},type:{name:"enum",value:[{value:"Icon.type.SVG",computed:!0},{value:"Icon.type.ICON_FONT",computed:!0},{value:"ICON_TYPES.SRC",computed:!0}]},required:!1,description:"the type of the component - svg, font or custom svg (using react-inlinesvg)"},iconSize:{defaultValue:{value:"16",computed:!1},type:{name:"union",value:[{name:"number"},{name:"string"}]},required:!1,description:"size for font icon"},ignoreFocusStyle:{defaultValue:{value:"false",computed:!1},type:{name:"bool"},required:!1,description:"remove focus style"},ariaHidden:{defaultValue:{value:"undefined",computed:!0},type:{name:"bool"},required:!1,description:""},useCurrentColor:{defaultValue:{value:"false",computed:!1},type:{name:"bool"},required:!1,description:'when using svg from src (Icon.type.SRC) this boolean will transform the "fill" property to "currentColor"'},customColor:{defaultValue:{value:"undefined",computed:!0},type:{name:"string"},required:!1,description:"If you want to override to coloring of currentColor"}}};var b=y;t.default=b},99634:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ICON_TYPES=void 0;t.ICON_TYPES={SVG:"SVG",ICON_FONT:"FA",SRC:"SRC"}},57288:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=e.onClick,n=e.className,i=e.clickable,d=e.ignoreFocusStyle,f=e.isDecorationOnly,p=e.iconLabel,m=e.externalTabIndex,y=(0,r.useRef)(null),b=(0,r.useCallback)((function(e){document.activeElement===y.current&&t(e)}),[y,t]),v=(0,r.useCallback)((function(e){e.preventDefault()}),[]),g=(0,r.useMemo)((function(){return(0,a.default)("icon_component",n,{"icon_component--clickable":i,"icon_component--no-focus-style":d})}),[i,n,d]);(0,u.default)({eventName:"mousedown",callback:v,ref:y}),(0,l.default)({keys:s,ref:y,callback:b,ignoreDocumentFallback:!0,capture:!0,stopPropagation:!0,preventDefault:!0});var O=(0,r.useCallback)((function(e){(t||o.default)(e)}),[t]),S=(0,c.default)({isClickable:i,label:p,isDecorationOnly:f});return S.tabIndex=null!=m?m:S.tabIndex,{screenReaderAccessProps:S,onClickCallback:O,computedClassName:g,onEnterCallback:b,iconRef:y}};var r=n(16689),a=d(n(59003)),o=d(n(87553)),u=d(n(67167)),l=d(n(37960)),i=n(27324),c=d(n(46830));function d(e){return e&&e.__esModule?e:{default:e}}var s=[i.keyCodes.ENTER,i.keyCodes.SPACE]},6847:(e,t,n)=>{function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a,o=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var n=i(t);if(n&&n.has(e))return n.get(e);var a={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var u in e)if("default"!==u&&Object.prototype.hasOwnProperty.call(e,u)){var l=o?Object.getOwnPropertyDescriptor(e,u):null;l&&(l.get||l.set)?Object.defineProperty(a,u,l):a[u]=e[u]}a.default=e,n&&n.set(e,a);return a}(n(16689)),u=(a=n(580))&&a.__esModule?a:{default:a};n(4374);var l=n(34066);function i(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(i=function(e){return e?n:t})(e)}var c=(0,o.forwardRef)((function(e,t){var n=e.svgClassName,r=e.className,a=e.size,u=e.id,i=(0,l.backwardCompatibilityForProperties)([r,n],""),c=(0,o.useMemo)((function(){if("number"==typeof a)return{width:a,height:a}}),[a]);return o.default.createElement("div",{className:"monday-loader-component",ref:t,role:"alert",title:"loading",style:c,id:u},o.default.createElement("svg",{className:"circle-loader-spinner ".concat(i),viewBox:"0 0 50 50"},o.default.createElement("circle",{className:"circle-loader-spinner-path",cx:"25",cy:"25",r:"20",fill:"none",strokeWidth:"5"})))}));c.propTypes={id:u.default.string,className:u.default.string,size:u.default.number},c.defaultProps={id:void 0,className:void 0,size:void 0},c.__docgenInfo={description:"",methods:[],displayName:"Loader",props:{id:{defaultValue:{value:"undefined",computed:!0},type:{name:"string"},required:!1,description:""},className:{defaultValue:{value:"undefined",computed:!0},type:{name:"string"},required:!1,description:""},size:{defaultValue:{value:"undefined",computed:!0},type:{name:"number"},required:!1,description:"The containing box of the loader"}}};var d=c;t.default=d},85699:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.getActualSize=t.TEXT_TYPES=void 0;var r=n(59705),a={s:r.SIZES.SMALL,md:r.SIZES.MEDIUM,l:r.SIZES.LARGE};t.getActualSize=function(e){return a[e]||e};t.TEXT_TYPES={TEXT:"text",PASSWORD:"password",SEARCH:"search",DATE:"date",DATE_TIME:"datetime-local"}},99123:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.sizeMapper=t.FEEDBACK_STATES=t.FEEDBACK_CLASSES=void 0;var r,a,o=n(59705);function u(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var l={ERROR:"error",SUCCESS:"success"};t.FEEDBACK_STATES=l;var i=(u(r={},l.ERROR,"input-component__input--error-validation"),u(r,l.SUCCESS,"input-component__input--success-validation"),r);t.FEEDBACK_CLASSES=i;var c=(u(a={},o.SIZES.SMALL,"input-component__input-wrapper--size-small"),u(a,o.SIZES.MEDIUM,"input-component__input-wrapper--size-medium"),u(a,o.SIZES.LARGE,"input-component__input-wrapper--size-large"),a);t.sizeMapper=c},27324:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.keyCodes=void 0;t.keyCodes={ENTER:"Enter",SPACE:" "}},59705:(e,t)=>{function n(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(t,"__esModule",{value:!0}),t.SIZES=t.PASCAL_BASE_SIZE=t.DialogPositions=t.BASE_SIZES=void 0;var a=Object.freeze({SMALL:"Small",MEDIUM:"Medium",LARGE:"Large"});t.PASCAL_BASE_SIZE=a;var o=Object.freeze({SMALL:"small",MEDIUM:"medium",LARGE:"large"});t.BASE_SIZES=o;var u=Object.freeze(function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?n(Object(a),!0).forEach((function(t){r(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):n(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}({XXS:"xxs",XS:"xs"},o));t.SIZES=u;var l=Object.freeze({LEFT:"left",LEFT_START:"left-start",LEFT_END:"left-end",RIGHT:"right",RIGHT_START:"right-start",RIGHT_END:"right-end",TOP:"top",TOP_START:"top-start",TOP_END:"top-end",BOTTOM:"bottom",BOTTOM_START:"bottom-start",BOTTOM_END:"bottom-end"});t.DialogPositions=l},34066:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.backwardCompatibilityForProperties=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1?arguments[1]:void 0,n=e.find((function(e){return void 0!==e}));return n||t}},10481:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.getClickableIconScreenReaderAccessProps=c,t.getClickableScreenReaderAccessProps=i,t.getIconScreenReaderAccessProps=function(e){var t=e.isClickable,n=e.isDecorationOnly,r=e.isKeyboardAccessible,o=e.label,u=(0,a.default)(n)?!t:n;if(t)return c({label:o,isDecorationOnly:u,isKeyboardAccessible:r});return{role:u?void 0:"img","aria-hidden":u,tabIndex:void 0,"aria-label":n?void 0:o}};var r,a=(r=n(86069))&&r.__esModule?r:{default:r};function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function u(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?o(Object(n),!0).forEach((function(t){l(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function l(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e){var t=e.isKeyboardAccessible,n=void 0===t||t,r=e.isDecorationOnly;return{role:"button",tabIndex:n?0:-1,"aria-hidden":void 0!==r&&r}}function c(e){var t=e.label,n=e.isDecorationOnly,r=void 0!==n&&n,a=e.isKeyboardAccessible;return u(u({},i({isDecorationOnly:r,isKeyboardAccessible:void 0===a||a})),{},{"aria-label":t})}},34900:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=e.delay,n=void 0===t?0:t,u=e.onChange,i=void 0===u?o.default:u,c=e.initialStateValue,d=void 0===c?"":c,s=e.trim,f=(b=(0,r.useState)(d),v=2,function(e){if(Array.isArray(e))return e}(b)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,a,o=[],u=!0,l=!1;try{for(n=n.call(e);!(u=(r=n.next()).done)&&(o.push(r.value),!t||o.length!==t);u=!0);}catch(e){l=!0,a=e}finally{try{u||null==n.return||n.return()}finally{if(l)throw a}}return o}}(b,v)||function(e,t){if(e){if("string"==typeof e)return l(e,t);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)?l(e,t):void 0}}(b,v)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),p=f[0],m=f[1],y=(0,r.useRef)(null);var b,v;(0,r.useEffect)((function(){y.current=d}));var g=(0,r.useMemo)((function(){return n?(0,a.default)(i,n):i}),[i,n]),O=(0,r.useCallback)((function(e){var t=e.target.value;if(s)return m(t.trim()),void g(t.trim());m(t),g(t)}),[g,m,s]),S=(0,r.useCallback)((function(){m(""),i("")}),[m,i]);d!==y.current&&d!==p&&m(d);return{inputValue:p,onEventChanged:O,clearValue:S,updateValue:m}};var r=n(16689),a=u(n(93908)),o=u(n(87553));function u(e){return e&&e.__esModule?e:{default:e}}function l(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}},67167:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=e.eventName,n=e.callback,a=e.ref,o=e.capture,u=void 0!==o&&o;(0,r.useEffect)((function(){var e=a&&a.current;if(e){var r={capture:u};return e.addEventListener(t,n,r),function(){e.removeEventListener(t,n,r)}}}),[t,a,n,u])};var r=n(16689)},46830:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=e.isClickable,n=e.label,o=e.isDecorationOnly;return(0,r.useMemo)((function(){return(0,a.getIconScreenReaderAccessProps)({isClickable:t,label:n,isDecorationOnly:o})}),[t,n,o])};var r=n(16689),a=n(10481)},37960:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var r,a=n(16689),o=(r=n(67167))&&r.__esModule?r:{default:r};var u="ctrlOrMetaKey";function l(e){var t,n=e.keys,r=void 0===n?[]:n,l=e.modifier,i=e.ref,c=e.callback,d=e.ignoreDocumentFallback,s=void 0!==d&&d,f=e.capture,p=void 0!==f&&f,m=e.preventDefault,y=void 0!==m&&m,b=e.stopPropagation,v=void 0!==b&&b,g=e.keyEventName,O=void 0===g?"keydown":g,S=(0,a.useRef)(document),_=(0,a.useCallback)((function(e){var t=e.key;r.includes(t)&&(l&&!function(e,t){return!!e[t]||t===u&&(e.ctrlKey||e.metaKey)}(e,l)||(y&&e.preventDefault(),v&&e.stopPropagation(),c(e)))}),[c,r,y,v,l]);t=i||(s?null:S),(0,o.default)({eventName:O,callback:_,ref:t,capture:p})}l.modifiers={ALT:"altKey",META:"metaKey",CTRL:"ctrlKey",SHIFT:"shiftKey",CTRL_OR_META:u}},59347:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=e.refs,n=void 0===t?[]:t;return(0,r.useMemo)((function(){return n.every((function(e){return null===e}))?null:function(e){n.forEach((function(t){t&&function(e,t){if(null===e)return;if("function"==typeof e)return void e(t);try{e.current=t}catch(n){throw console.error(n),new Error("Cannot assign value '".concat(t,"' to ref '").concat(e,"'"))}}(t,e)}))}}),[n])};var r=n(16689)},75981:(e,t,n)=>{n.r(t)},77274:(e,t,n)=>{n.r(t)},4374:(e,t,n)=>{n.r(t)},37234:(e,t,n)=>{n.r(t)},69374:e=>{e.exports=require("@react-aria/button")},59003:e=>{e.exports=require("classnames")},93908:e=>{e.exports=require("lodash/debounce")},86069:e=>{e.exports=require("lodash/isNil")},87553:e=>{e.exports=require("lodash/noop")},580:e=>{e.exports=require("prop-types")},16689:e=>{e.exports=require("react")},23831:e=>{e.exports=require("react-inlinesvg")}},t={};function n(r){var a=t[r];if(void 0!==a)return a.exports;var o=t[r]={exports:{}};return e[r](o,o.exports,n),o.exports}n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var r={};return(()=>{var e=r;function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t(e)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.ARIA_LABELS=void 0;var a=function(e,n){if(!n&&e&&e.__esModule)return e;if(null===e||"object"!==t(e)&&"function"!=typeof e)return{default:e};var r=v(n);if(r&&r.has(e))return r.get(e);var a={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var u in e)if("default"!==u&&Object.prototype.hasOwnProperty.call(e,u)){var l=o?Object.getOwnPropertyDescriptor(e,u):null;l&&(l.get||l.set)?Object.defineProperty(a,u,l):a[u]=e[u]}a.default=e,r&&r.set(e,a);return a}(n(16689)),o=b(n(580)),u=b(n(59003)),l=b(n(34900));n(37234);var i=b(n(98396)),c=b(n(6847)),d=n(99123),s=b(n(43424)),f=n(85699),p=n(59705),m=b(n(59347)),y=n(69374);function b(e){return e&&e.__esModule?e:{default:e}}function v(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(v=function(e){return e?n:t})(e)}function g(){return g=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},g.apply(this,arguments)}var O=function(){},S=(0,a.forwardRef)((function(e,t){var n=e.className,r=e.placeholder,o=e.autoComplete,p=e.value,b=e.onChange,v=e.onBlur,C=e.onFocus,E=e.onKeyDown,T=e.debounceRate,h=e.autoFocus,P=e.disabled,N=e.readonly,j=e.setRef,I=e.iconName,A=e.secondaryIconName,M=e.id,k=e.title,w=e.size,q=e.validation,x=e.wrapperClassName,V=e.onIconClick,D=e.clearOnIconClick,L=e.labelIconName,R=e.showCharCount,F=e.inputAriaLabel,z=e.searchResultsContainerId,K=e.activeDescendant,W=e.iconsNames,B=e.type,H=e.maxLength,G=e.trim,X=e.role,Y=e.required,Z=e.loading,U=(0,a.useRef)(null),$=(0,l.default)({delay:T,onChange:b,initialStateValue:p,trim:G}),J=$.inputValue,Q=$.onEventChanged,ee=$.clearValue,te=(0,a.useMemo)((function(){return A&&J?A:I}),[I,A,J]),ne=(0,a.useCallback)((function(){P||(D&&(U.current&&U.current.focus(),ee()),V(te))}),[ee,te,U,D,P,V]),re=(0,a.useMemo)((function(){return q?d.FEEDBACK_CLASSES[q.status]:""}),[q]),ae=I||A,oe=R||q&&q.text,ue=A===te,le=I===te,ie=A&&ue&&!!J,ce=(0,m.default)({refs:[t,U,j]}),de=(0,y.useButton)({onPress:ne,elementType:"div"}).buttonProps;return(0,a.useEffect)((function(){if(U.current&&h){var e=requestAnimationFrame((function(){return U.current.focus()}));return function(){return cancelAnimationFrame(e)}}}),[U,h]),a.default.createElement("div",{className:(0,u.default)("input-component",x,{"input-component--disabled":P}),role:X,"aria-busy":Z},a.default.createElement("div",{className:"input-component__label--wrapper"},a.default.createElement(s.default,{labelText:k,icon:L,iconLabel:W.layout,labelFor:M}),a.default.createElement("div",{className:(0,u.default)("input-component__input-wrapper",d.sizeMapper[(0,f.getActualSize)(w)],re)},a.default.createElement("input",{className:(0,u.default)(n,"input-component__input",{"input-component__input--has-icon":!!ae}),placeholder:r,autoComplete:o,value:J,onChange:Q,disabled:P,readOnly:N,ref:ce,type:B,id:M,onBlur:v,onFocus:C,onKeyDown:E,maxLength:H,role:z&&"combobox","aria-label":F||r,"aria-invalid":q&&"error"===q.status,"aria-owns":z,"aria-activedescendant":K,required:Y}),Z&&a.default.createElement("div",{className:(0,u.default)("input-component__loader--container",{"input-component__loader--container-has-icon":ae})},a.default.createElement("div",{className:"input-component__loader"},a.default.createElement(c.default,{svgClassName:"input-component__loader-svg"}))),a.default.createElement("div",g({className:(0,u.default)("input-component__icon--container",{"input-component__icon--container-has-icon":ae,"input-component__icon--container-active":le})},de,{tabIndex:V!==O&&J&&I.length&&le?"0":"-1"}),a.default.createElement(i.default,{icon:I,className:(0,u.default)("input-component__icon"),clickable:!1,id:M,iconLabel:W.primary,iconType:i.default.type.ICON_FONT,ignoreFocusStyle:!0,iconSize:w===S.sizes.SMALL?"16px":"18px"})),a.default.createElement("div",g({className:(0,u.default)("input-component__icon--container",{"input-component__icon--container-has-icon":ae,"input-component__icon--container-active":ue})},de,{tabIndex:ie?"0":"-1"}),a.default.createElement(i.default,{icon:A,className:(0,u.default)("input-component__icon"),clickable:!1,id:M,iconLabel:W.secondary,iconType:i.default.type.ICON_FONT,ignoreFocusStyle:!0,iconSize:w===S.sizes.SMALL?"16px":"18px"}))),oe&&a.default.createElement("div",{className:"input-component__sub-text-container"},q&&q.text&&a.default.createElement("span",{className:"input-component__sub-text-container-status","aria-label":_.VALIDATION_TEXT},q.text),R&&a.default.createElement("span",{className:"input-component__sub-text-container-counter","aria-label":_.CHAR},J&&J.length||0))))}));S.sizes=p.SIZES,S.feedbacks=d.FEEDBACK_STATES,S.types=f.TEXT_TYPES,S.propTypes={className:o.default.string,placeholder:o.default.string,autoComplete:o.default.string,value:o.default.string,onChange:o.default.func,onBlur:o.default.func,onFocus:o.default.func,onKeyDown:o.default.func,debounceRate:o.default.number,autoFocus:o.default.bool,disabled:o.default.bool,readonly:o.default.bool,setRef:o.default.func,iconName:o.default.oneOfType([o.default.string,o.default.func]),secondaryIconName:o.default.oneOfType([o.default.string,o.default.func]),id:o.default.string,title:o.default.string,size:o.default.oneOf([S.sizes.SMALL,S.sizes.MEDIUM,S.sizes.LARGE]),validation:o.default.oneOfType([o.default.shape({status:o.default.oneOf(["error","success"]),text:o.default.string}),o.default.shape({text:o.default.string})]),wrapperClassName:o.default.string,onIconClick:o.default.func,clearOnIconClick:o.default.bool,labelIconName:o.default.oneOfType([o.default.string,o.default.func]),showCharCount:o.default.bool,inputAriaLabel:o.default.string,searchResultsContainerId:o.default.string,activeDescendant:o.default.string,iconsNames:o.default.shape({layout:o.default.string,primary:o.default.string,secondary:o.default.string}),type:o.default.oneOf([S.types.TEXT,S.types.PASSWORD,S.types.SEARCH,S.types.DATE,S.types.DATE_TIME]),maxLength:o.default.number,trim:o.default.bool,role:o.default.string,required:o.default.bool,loading:o.default.bool},S.defaultProps={className:"",placeholder:"",autoComplete:"off",value:void 0,onChange:O,onBlur:O,onFocus:O,onKeyDown:O,debounceRate:0,autoFocus:!1,disabled:!1,readonly:!1,setRef:O,iconName:"",secondaryIconName:"",id:"input",title:"",size:S.sizes.SMALL,validation:null,wrapperClassName:"",onIconClick:O,clearOnIconClick:!1,labelIconName:"",showCharCount:!1,inputAriaLabel:void 0,searchResultsContainerId:"",activeDescendant:"",iconsNames:{primary:"",secondary:"",label:""},type:f.TEXT_TYPES.TEXT,maxLength:null,trim:!1,role:"",required:!1,loading:!1};var _={CHAR:"Input char count",VALIDATION_TEXT:"Additional helper text"};e.ARIA_LABELS=_,S.__docgenInfo={description:"",methods:[],displayName:"TextField",props:{className:{defaultValue:{value:'""',computed:!1},type:{name:"string"},required:!1,description:""},placeholder:{defaultValue:{value:'""',computed:!1},type:{name:"string"},required:!1,description:""},autoComplete:{defaultValue:{value:'"off"',computed:!1},type:{name:"string"},required:!1,description:"See https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete for all of the available options"},value:{defaultValue:{value:"undefined",computed:!0},type:{name:"string"},required:!1,description:""},onChange:{defaultValue:{value:"() => {\n}",computed:!1},type:{name:"func"},required:!1,description:""},onBlur:{defaultValue:{value:"() => {\n}",computed:!1},type:{name:"func"},required:!1,description:""},onFocus:{defaultValue:{value:"() => {\n}",computed:!1},type:{name:"func"},required:!1,description:""},onKeyDown:{defaultValue:{value:"() => {\n}",computed:!1},type:{name:"func"},required:!1,description:""},debounceRate:{defaultValue:{value:"0",computed:!1},type:{name:"number"},required:!1,description:""},autoFocus:{defaultValue:{value:"false",computed:!1},type:{name:"bool"},required:!1,description:""},disabled:{defaultValue:{value:"false",computed:!1},type:{name:"bool"},required:!1,description:""},readonly:{defaultValue:{value:"false",computed:!1},type:{name:"bool"},required:!1,description:""},setRef:{defaultValue:{value:"() => {\n}",computed:!1},type:{name:"func"},required:!1,description:""},iconName:{defaultValue:{value:'""',computed:!1},type:{name:"union",value:[{name:"string"},{name:"func"}]},required:!1,description:""},secondaryIconName:{defaultValue:{value:'""',computed:!1},type:{name:"union",value:[{name:"string"},{name:"func"}]},required:!1,description:""},id:{defaultValue:{value:'"input"',computed:!1},type:{name:"string"},required:!1,description:""},title:{defaultValue:{value:'""',computed:!1},type:{name:"string"},required:!1,description:""},size:{defaultValue:{value:"TextField.sizes.SMALL",computed:!0},type:{name:"enum",value:[{value:"TextField.sizes.SMALL",computed:!0},{value:"TextField.sizes.MEDIUM",computed:!0},{value:"TextField.sizes.LARGE",computed:!0}]},required:!1,description:"SIZES is exposed on the component itself"},validation:{defaultValue:{value:"null",computed:!1},type:{name:"union",value:[{name:"shape",value:{status:{name:"enum",value:[{value:'"error"',computed:!1},{value:'"success"',computed:!1}],description:"Don't provide status for plain assistant text",required:!1},text:{name:"string",required:!1}}},{name:"shape",value:{text:{name:"string",required:!1}}}]},required:!1,description:""},wrapperClassName:{defaultValue:{value:'""',computed:!1},type:{name:"string"},required:!1,description:""},onIconClick:{defaultValue:{value:"() => {\n}",computed:!1},type:{name:"func"},required:!1,description:""},clearOnIconClick:{defaultValue:{value:"false",computed:!1},type:{name:"bool"},required:!1,description:""},labelIconName:{defaultValue:{value:'""',computed:!1},type:{name:"union",value:[{name:"string"},{name:"func"}]},required:!1,description:""},showCharCount:{defaultValue:{value:"false",computed:!1},type:{name:"bool"},required:!1,description:""},inputAriaLabel:{defaultValue:{value:"undefined",computed:!0},type:{name:"string"},required:!1,description:""},searchResultsContainerId:{defaultValue:{value:'""',computed:!1},type:{name:"string"},required:!1,description:""},activeDescendant:{defaultValue:{value:'""',computed:!1},type:{name:"string"},required:!1,description:""},iconsNames:{defaultValue:{value:'{ primary: "", secondary: "", label: "" }',computed:!1},type:{name:"shape",value:{layout:{name:"string",required:!1},primary:{name:"string",required:!1},secondary:{name:"string",required:!1}}},required:!1,description:"Icon names labels for a11y"},type:{defaultValue:{value:"TEXT_TYPES.TEXT",computed:!0},type:{name:"enum",value:[{value:"TextField.types.TEXT",computed:!0},{value:"TextField.types.PASSWORD",computed:!0},{value:"TextField.types.SEARCH",computed:!0},{value:"TextField.types.DATE",computed:!0},{value:"TextField.types.DATE_TIME",computed:!0}]},required:!1,description:"TEXT_TYPES is exposed on the component itself"},maxLength:{defaultValue:{value:"null",computed:!1},type:{name:"number"},required:!1,description:""},trim:{defaultValue:{value:"false",computed:!1},type:{name:"bool"},required:!1,description:""},role:{defaultValue:{value:'""',computed:!1},type:{name:"string"},required:!1,description:"ARIA role for container landmark"},required:{defaultValue:{value:"false",computed:!1},type:{name:"bool"},required:!1,description:"adds required to the input element"},loading:{defaultValue:{value:"false",computed:!1},type:{name:"bool"},required:!1,description:"shows loading animation"}}};var C=S;e.default=C})(),r})()}));