{"version":3,"sources":["webpack:///./ClientApp/services/Localizer.tsx","webpack:///./ClientApp/shared/polyfills/customEvent.js","webpack:///./ClientApp/shared/components/svg/RightChevronSVG.tsx","webpack:///./ClientApp/shared/components/svg/MapPinSVG.tsx","webpack:///./ClientApp/shared/hooks/useAxiosLoader.ts","webpack:///./ClientApp/shared/hooks/useAxiosPaginatedLoader.ts","webpack:///./ClientApp/shared/breakpoints.ts","webpack:///./ClientApp/shared/components/Spinner.tsx","webpack:///./ClientApp/shared/components/svg/MagnifyingGlassSVG.tsx","webpack:///./ClientApp/features/commerce/store-locator/StoreLocationFormattedAddress.tsx","webpack:///./ClientApp/features/commerce/store-locator/DefaultStoreLocationResultsItem.tsx","webpack:///./ClientApp/shared/components/Pagination.tsx","webpack:///./ClientApp/services/AxiosHelper.ts","webpack:///./ClientApp/shared/edit/fields/FieldInputErrorWrapper.tsx","webpack:///./ClientApp/features/commerce/store-details/StoreDetailsButton.tsx","webpack:///./ClientApp/features/commerce/store-locator/StoreLocationOptions.tsx","webpack:///./ClientApp/shared/components/svg/ExternalLinkSVG.tsx","webpack:///./ClientApp/features/commerce/store-locator/StoreLocationGetDirections.tsx","webpack:///./ClientApp/features/commerce/store-locator/useStoreLocator.tsx","webpack:///./ClientApp/features/commerce/default-store-location/useDefaultStoreLocationLoader.tsx","webpack:///./ClientApp/shared/components/svg/MapPinSolidSVG.tsx","webpack:///./ClientApp/features/commerce/store-locator/GoogleMapsMarker.tsx","webpack:///./ClientApp/shared/edit/fields/FieldLabel.tsx","webpack:///./ClientApp/shared/edit/InlineAlert.tsx","webpack:///./ClientApp/shared/components/svg/XSVG.tsx","webpack:///./ClientApp/services/UserData.ts","webpack:///./ClientApp/shared/edit/fields/CheckboxInputField.tsx","webpack:///./ClientApp/shared/edit/fields/CheckBoxField.tsx","webpack:///./ClientApp/shared/edit/fields/DropdownField.tsx","webpack:///./ClientApp/shared/edit/fields/ValidationMessages.tsx","webpack:///./ClientApp/shared/edit/fields/StarRatingField.tsx","webpack:///./ClientApp/shared/edit/fields/TextAreaField.tsx","webpack:///./ClientApp/shared/edit/fields/InputField.tsx","webpack:///./ClientApp/shared/edit/fields/TextBoxField.tsx","webpack:///../Roc.SharedClientApp/types/model-status.ts","webpack:///./ClientApp/shared/util/AccountUrls.ts","webpack:///./ClientApp/shared/hooks/useRocEventHandler.tsx","webpack:///./ClientApp/features/commerce/store-locator/ResultsWithinDistance.tsx","webpack:///./ClientApp/shared/util/ErrorBoundary.tsx","webpack:///./ClientApp/shared/polyfills/getAttributeNames.js","webpack:///./ClientApp/shared/util/ApplicationInit.tsx","webpack:///./ClientApp/shared/edit/OptionalFieldMarker.tsx","webpack:///./ClientApp/shared/hooks/useDelayedDisplay.tsx","webpack:///./ClientApp/shared/components/svg/CheckCircleSVG.tsx","webpack:///./ClientApp/shared/util/events/rocEventUtils.ts","webpack:///./ClientApp/shared/components/hawksearch/components/svg/DashCircleSVG.tsx","webpack:///./ClientApp/shared/components/svg/CircleExclamationSVG.tsx","webpack:///./ClientApp/shared/components/CircleButton.tsx","webpack:///./ClientApp/shared/components/svg/StarEmptySVG.tsx","webpack:///./ClientApp/shared/components/svg/StarSVG.tsx","webpack:///./ClientApp/shared/components/star-rating/StarRating.tsx","webpack:///./ClientApp/shared/components/star-rating/useStarRating.ts","webpack:///./ClientApp/shared/components/hawksearch/helpers/Cookies.ts","webpack:///./ClientApp/shared/components/svg/PencilSVG.tsx","webpack:///./ClientApp/services/ServerData.ts","webpack:///./ClientApp/shared/hooks/useLoader.ts","webpack:///./ClientApp/features/commerce/store-locator/StoreLocator.tsx","webpack:///./ClientApp/features/commerce/store-locator/index.tsx","webpack:///./ClientApp/shared/components/svg/FolderSVG.tsx","webpack:///./ClientApp/shared/components/svg/GarbageCanCircleSVG.tsx","webpack:///./ClientApp/shared/components/StatusDisplay.tsx","webpack:///./ClientApp/util/StringUtil.ts","webpack:///./ClientApp/shared/components/svg/LeftChevronSVG.tsx","webpack:///./ClientApp/styles/node-modules/react-toggle/style.css?5a6e","webpack:///./ClientApp/styles/node-modules/react-toggle/style.css"],"names":["LocalizerResources","isAlreadyLogged","initializeLocalizerResources","windowWithResources","window","__ROC_LOCALIZER_RESOURCES__","Array","isArray","forEach","obj","Object","keys","key","Localizer","replaceStrings","length","console","warn","resource","replace","match","index","LocalizedSpan","props","resourceKey","args","localizedString","data-testid","toKebabCase","dangerouslySetInnerHTML","__html","CustomEvent","event","params","bubbles","cancelable","detail","undefined","evt","document","createEvent","initCustomEvent","prototype","Event","RightChevronSVG","className","rest","viewBox","classnames","focusable","aria-hidden","d","MapPinSVG","cache","useAxiosLoader","axiosParams","active","callback","cacheKey","method","useLoader","loading","setLoading","error","setError","response","setResponse","useState","reloadTimes","setReloadTimes","cancelToken","useRef","useEffect","current","Axios","CancelToken","source","AxiosHelper","isCancel","cancel","values","reload","useAxiosPaginatedLoader","query","initialPageSize","initialSortByName","initialSortDirection","initialResults","pageSize","setPageSizeState","pageNumber","setPageNumber","sortByName","setSortByName","sortDirection","setSortDirection","dataLoaderActive","setDataLoaderActive","customQuery","setCustomQuery","paginationQuery","url","results","data","page","goToPage","pagination","totalPages","goToNextPage","goToPreviousPage","setSorting","sortBy","direction","setPageSize","size","setQuery","lg","md","sm","Spinner","light","waitMs","align","block","parentCentered","useDelayedDisplay","spinner","MagnifyingGlassSVG","LazyMediaQuery","React","lazy","StoreLocationFormattedAddress","location","distanceUnit","onPinClicked","bigTitle","showTitle","Pin","onClick","type","aria-label","name","Suspense","fallback","minWidth","address1","address2","city","country","state","region","postalCode","phoneNumber","href","distance","toFixed","maxWidth","DefaultStoreLocationResultsItem","testId","saveDefaultLocation","isSavingDefaultLocation","defaultStoreLocation","id","disabled","Pagination","flush","hasNextPage","hasPreviousPage","uniqueId","createGuid","localPageNumber","setLocalPageNumber","timerRef","attemptGoToPage","newPageNumber","clearTimeout","setTimeout","parseInt","htmlFor","value","onChange","currentTarget","onKeyDown","toLocaleString","axios","create","defaults","headers","common","interceptors","request","use","config","toLowerCase","getCsrfToken","csrfToken","RequestVerificationToken","addUnauthorizedAccessInterceptor","history","status","AccountUrls","Login","encodeURIComponent","pathname","Promise","reject","FieldInputErrorWrapper","hideIcon","children","inline","meta","useField","invalid","submitError","dirtySinceLastSubmit","submitting","touched","StoreDetailsButton","searchText","link","StoreLocationOptions","searchResults","StoreLocationGetDirections","origin","ExternalLinkSVG","targetLocation","latitude","longitude","target","rel","useStoreLocator","useStoreLocationParams","savingError","setSavingError","isSaving","setIsSaving","initSearchText","setSearchTextInternal","locationChangeDispatcher","dispatchRocEvent","loadingError","isLoading","actor","requestToken","post","searchString","token","setSearchText","useDefaultStoreLocationLoader","setIsLoading","setDefaultStoreLocation","useRocEventHandler","getUserData","userDataResponse","axiosError","message","MapPinSolidSVG","GoogleMapsMarker","$hover","dto","setActiveMarkerKey","icon","XSVG","FieldLabel","label","isRequired","trim","InlineAlert","title","defaultProps","theme","isTitleOnOwnRow","isCollapsed","onCollapse","isAxiosError","userDataPromise","get","getUserDataNoCache","userData","CheckboxInputField","input","checked","readOnly","placeholder","step","defaultValue","dirty","defaultChecked","aria-describedby","CheckBoxField","afterSubmit","allowNull","beforeSubmit","formatOnBlur","initialValue","isEqual","subscription","DropdownField","addSelectOption","options","validateFields","onFocus","onBlur","map","option","text","getErrorArray","errorOrSubmitError","errors","push","filter","ValidationMessages","concat","aria-live","aria-atomic","Fragment","StarRatingField","maxRating","OptionalFieldMarker","StarRating","readonly","TextAreaField","rows","validate","component","format","parse","render","InputField","forwardRef","ref","TextBoxField","ModelStatus","BaseUrl","ServerData","ACCOUNT_URL_BASE","ACCOUNT_LOGIN_URL","Login2fa","ACCOUNT_LOGIN_WITH_2FA_URL","Register","ACCOUNT_REGISTER_URL","ForgotPassword","ACCOUNT_FORGOT_PASSWORD_URL","LoginWithRecoveryCode","ACCOUNT_LOGIN_WITH_RECOVERY_CODE_URL","Logout","ACCOUNT_LOGOUT_URL","OrganizationReview","ACCOUNT_ORGANIZATION_REVIEW_URL","OrganizationSelector","ACCOUNT_ORGANIZATION_SELECTOR_URL","eventType","dispatchEvent","eventHandler","deps","removeHandlerCallback","addRocEventHandler","ResultsWithinDistance","resultsCount","toString","ErrorBoundary","this","setState","renderError","Component","renderProps","Element","getAttributeNames","attributes","result","i","getDataPropsFromAttributes","element","s","startsWith","attributeName","toCamelCase","substring","getAttribute","initReactApp","getReactElement","elementId","getElementById","ReactDOM","initReactAppByAttribute","attribute","elements","querySelectorAll","memo","display","setDisplay","timeout","CheckCircleSVG","handler","addEventListener","removeEventListener","DashCircleSVG","class","fill","CircleExclamationSVG","CircleButton","otherProps","StarEmptySVG","StarSVG","ratingStars","setRatingStars","ratingHovered","setRatingHovered","newState","isFull","isPending","isHighlighted","isChecked","ratingValue","useStarRating","Error","onInputChange","e","modifierClasses","onMouseEnter","onMouseLeave","getVisitorExpiry","Date","setTime","getTime","toUTCString","getVisitExpiry","substr","Math","floor","random","join","getCookie","nameEQ","ca","cookie","split","charAt","indexOf","setCookie","expiry","expires","PencilSVG","windowWithServerData","__ROC_SERVER_DATA__","initializeServerData","LazyDesktop","then","module","default","Desktop","LazyMobile","Mobile","LazyTablet","Tablet","LazyTabletAndSmaller","TabletAndSmaller","LazyScrollToElement","LazyGoogleMapReact","StoreLocator","markers","setMarkers","lat","lng","mapCenter","setMapCenter","isGoogleApiLoaded","setIsGoogleApiLoaded","hasValidationError","setHasValidationError","mapObj","mapsObj","focusEl","activeMarkerKey","centerMap","onMarkerClick","clickedMarkerIndex","markerClicked","centerMapTo","onFormSubmit","formValues","bounds","LatLngBounds","point","extend","fitBounds","marker","SearchFormValidationError","Map","bootstrapURLKeys","GoogleMapsApiKey","center","defaultZoom","yesIWantToUseGoogleMapApiInternals","onGoogleApiLoaded","maps","onApiIsLoaded","onChildClick","Number","SearchForm","tabIndex","onSubmit","pristine","hasValidationErrors","valid","handleSubmit","SearchResultsPagination","SearchResultsComponent","data-testId","searchDistanceInMiles","totalRecords","markerIndex","findIndex","scroller","scrollTo","duration","smooth","innerWidth","focus","FolderSVG","GarbageCanCircleSVG","StatusDisplay","Published","Inactive","Deleted","Draft","Archived","toLocaleLowerCase","word","toUpperCase","stripHtml","html","tmp","createElement","innerHTML","textContent","innerText","trimString","LeftChevronSVG","api","content","__esModule","exports","locals","___CSS_LOADER_API_IMPORT___"],"mappings":"6/BAwJA,IAAMA,EAAwC,GAKxCC,EAA2C,GAKjD,SAASC,IACR,IAAMC,EAAsBC,OAG3BD,GACAA,EAAoBE,6BACpBC,MAAMC,QAAQJ,EAAoBE,8BAElCF,EAAoBE,4BAA4BG,SAAQ,SAACC,GACxD,cAAkBC,OAAOC,KAAKF,GAA9B,eAAoC,CAA/B,IAAMG,EAAG,KACbZ,EAAmBY,GAAOH,EAAIG,OAc3B,SAASC,EACfD,GAEC,2BADEE,EACF,iCADEA,EACF,kBAKD,GAJ+C,IAA3CJ,OAAOC,KAAKX,GAAoBe,QACnCb,KAGIF,IAAuBA,EAAmBY,GAQ9C,OALMX,EAAgBW,KACpBI,QAAQC,KAAKL,EAAK,2DAClBX,EAAgBW,IAAO,GAGlBA,EAGR,IAAMM,EAAWlB,EAAmBY,GAEpC,OAAKE,EAIEI,EAASC,QAAQ,YAAY,SAACC,EAAeC,GACnD,OAAOP,EAAeO,GAASP,EAAeO,GAAS,MAJhDH,EAqBF,SAASI,EAAcC,GAA2B,IAChDC,EAA2BD,EAA3BC,YADgD,EACrBD,EAAdE,YADmC,MAC5B,GAD4B,EAElDC,EAAkBb,EAAS,WAAT,GAAUW,GAAV,SAA0BC,KAElD,OACC,wBACCE,cAAA,oBAA0BC,YAAYJ,IACtCK,wBAAyB,CAAEC,OAAQJ,O,mBC3OtC,WACC,GAAkC,mBAAvBtB,OAAO2B,YACjB,OAAO,EAGR,SAASA,EAAYC,EAAOC,GAC3BA,EAASA,GAAU,CAAEC,SAAS,EAAOC,YAAY,EAAOC,YAAQC,GAEhE,IAAIC,EAAMC,SAASC,YAAY,eAE/B,OADAF,EAAIG,gBAAgBT,EAAOC,EAAOC,Q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AMuF,OAIdvF,EACLuF,OACAvP,QAAQ,iBAAkB,KAC1BA,QAAQ,qBAAsB,SAC9BA,QAAQ,2BAA4B,SACpCA,QAAQ,KAAM,IACd4f,oBATM,GAgBF,SAASvJ,EAAYrM,GAC3B,OAAOA,EACLhK,QAAQ,uBAAuB,SAAU6f,EAAM3f,GAC/C,OAAiB,IAAVA,EAAc2f,EAAK/U,cAAgB+U,EAAKC,iBAE/C9f,QAAQ,gBAAiB,IAUrB,SAAS+f,EAAUC,GACzB,IAAMC,EAAM7e,SAAS8e,cAAc,OAEnC,OADAD,EAAIE,UAAYH,EACTC,EAAIG,aAAeH,EAAII,WAAa,GAmBrC,SAASC,EAAWtW,GAC1B,OAAOA,EAAQA,EAAMuF,OAAS,K,6pBC7HhBgR,IAdf,YAA0D,IAAhC7e,EAAgC,EAAhCA,UAAcC,EAAkB,mBACzD,OACC,2BACCC,QAAQ,YACRF,UAAWG,IAAW,WAAYH,GAClCI,UAAU,QACVC,cAAY,QACRJ,GAEJ,0BAAMK,EAAE,mM,mBClBX,IAAIwe,EAAM,EAAQ,IACFC,EAAU,EAAQ,IAIC,iBAFvBA,EAAUA,EAAQC,WAAaD,EAAQ3F,QAAU2F,KAG/CA,EAAU,CAAC,CAAC5F,EAAO9E,EAAI0K,EAAS,MAG9C,IAAIjP,EAAU,CAEd,OAAiB,OACjB,WAAoB,GAEPgP,EAAIC,EAASjP,GAI1BqJ,EAAO8F,QAAUF,EAAQG,QAAU,I,oBChBnCD,EADkC,EAAQ,IAChCE,EAA4B,IAE9B3O,KAAK,CAAC2I,EAAO9E,EAAI,6lGAA8lG,KAEvnG8E,EAAO8F,QAAUA,I","file":"store-locator.js","sourcesContent":["import { AddressResourceKeys } from 'features/address-book/resources';\r\nimport { ContactFormResourceKeys } from 'features/contact-form/resources';\r\nimport { CreatePasswordResourceKeys } from 'features/create-password/resources';\r\nimport { LoginWith2faResourceKeys } from 'features/login-with-2fa/resources';\r\nimport { LoginWithRecoveryCodeResourceKeys } from 'features/login-with-recovery-code/resources';\r\nimport { LoginResourceKeys } from 'features/login/resources';\r\nimport { MyAccountResourceKeys } from 'features/my-account/resources';\r\nimport { ResetPasswordResourceKeys } from 'features/reset-password/resources';\r\nimport { SubmitQuestionResourceKeys } from 'features/submit-question/resources';\r\nimport * as React from 'react';\r\nimport { toKebabCase } from 'util/StringUtil';\r\n\r\n// #region Commerce\r\nimport { CommerceResourceKeys } from 'features/commerce/CommerceResourceKeys';\r\n// #endregion\r\n\r\n// #region TapeCase Customization\r\nimport { SubmitQuoteResourceKeys } from 'features/submit-quote/resources';\r\nimport { TapeCaseRegistrationResourceKeys } from 'features/register-tapecase/resources';\r\nimport { CareersFormResourceKeys } from 'features/careers-form/resources';\r\nimport { FileUploadResourceKeys } from 'features/file-upload/resources';\r\n// #endregion\r\n\r\n/**\r\n * Type that will hold all the global localization keys\r\n */\r\ntype LocalizerGlobalResourceKeys =\r\n\t| 'Success'\r\n\t| 'OfTotalPages'\r\n\t| 'Cancel'\r\n\t| 'Confirm'\r\n\t| 'FirstName'\r\n\t| 'LastName'\r\n\t| 'Email'\r\n\t| 'Username'\r\n\t| 'Amount'\r\n\t| 'NameOnCard'\r\n\t| 'CardNumber'\r\n\t| 'ExpDate'\r\n\t| 'ExpMonth'\r\n\t| 'ExpYear'\r\n\t| 'Expires'\r\n\t| 'Expired'\r\n\t| 'SecurityCode'\r\n\t| 'Submit'\r\n\t| 'Save'\r\n\t| 'ZipCode'\r\n\t| 'Remove'\r\n\t| 'Removed'\r\n\t| 'Update'\r\n\t| 'Undo'\r\n\t| 'Cancel'\r\n\t| 'Enter'\r\n\t| 'Close'\r\n\t| 'SortBy'\r\n\t| 'PleaseWait'\r\n\t| 'Unknown'\r\n\t| 'Yes'\r\n\t| 'No'\r\n\t| 'Delete'\r\n\t| 'Update'\r\n\t| 'SaveAndContinueButtonText'\r\n\t| 'SaveAndContinue'\r\n\t| 'Continue'\r\n\t| 'SaveErrorMessage'\r\n\t| 'Edit'\r\n\t| 'ErrorMessageGenericTitle'\r\n\t| 'CheckEnteredValues'\r\n\t| 'ErrorMessageForbidden'\r\n\t| 'ErrorMessageNetwork'\r\n\t| 'ErrorOccurredSubmittingTheForm'\r\n\t| 'UnexpectedErrorOccurred'\r\n\t| 'Login'\r\n\t| 'ReturnToShipping'\r\n\t| 'BreadcrumbsLabel'\r\n\t| 'Other'\r\n\t| 'RememberMe'\r\n\t| 'ForgotYourPassword'\r\n\t| 'RegisterNewUserLinkText'\r\n\t| 'LoginPageTitleText'\r\n\t| 'ForgotPasswordPageTitle'\r\n\t| 'ForgotPasswordConfirmationPageTitle'\r\n\t| 'ForgotPasswordConfirmation'\r\n\t| 'Optional'\r\n\t| 'SearchBoxPlaceholder'\r\n\t| 'XOutOfYStars'\r\n\t| 'XToYOfZ'\r\n\t| 'ModalLabel'\r\n\t| 'RequiredFields'\r\n\t| 'Status'\r\n\t| 'Version'\r\n\t| 'CreatedOn'\r\n\t| 'CreatedBy'\r\n\t| 'ModifiedOn'\r\n\t| 'ModifiedBy'\r\n\t| 'OpenStatusInformation'\r\n\t| 'CloseStatusInformation'\r\n\t| 'SearchFilter'\r\n\t| 'Pagination'\r\n\t| 'Previous'\r\n\t| 'Next'\r\n\t| 'ClearFilter';\r\n\r\n/**\r\n * Type that will hold all the localization keys\r\n */\r\nexport type LocalizerResourceKey =\r\n\t| LocalizerGlobalResourceKeys\r\n\t| LoginResourceKeys\r\n\t| ContactFormResourceKeys\r\n\t// #region Commerce\r\n\t| CommerceResourceKeys\r\n\t// #endregion\r\n\t| ResetPasswordResourceKeys\r\n\t| CreatePasswordResourceKeys\r\n\t| SubmitQuestionResourceKeys\r\n\t| ResetPasswordResourceKeys\r\n\t| CreatePasswordResourceKeys\r\n\t| MyAccountResourceKeys\r\n\t| LoginWith2faResourceKeys\r\n\t| LoginWithRecoveryCodeResourceKeys\r\n\t| AddressResourceKeys\r\n\t// #region TapeCase Customization\r\n\t| SubmitQuoteResourceKeys\r\n\t| TapeCaseRegistrationResourceKeys\r\n\t| CareersFormResourceKeys\r\n\t| FileUploadResourceKeys;\r\n// #endregion\r\n\r\n/**\r\n * Interface for the resources\r\n *\r\n * @export\r\n * @interface LocalizerResource\r\n */\r\ninterface LocalizerResource {\r\n\t[id: string]: string;\r\n}\r\n\r\n/**\r\n * Extends Window with a property that will hold the localizer resources\r\n *\r\n * @interface WindowWithResources\r\n * @extends {Window}\r\n */\r\nexport interface WindowWithResources extends Window {\r\n\t__ROC_LOCALIZER_RESOURCES__?: LocalizerResource[];\r\n}\r\n\r\n/**\r\n * Main object that will hold all the localized resources\r\n */\r\nconst LocalizerResources: LocalizerResource = {};\r\n\r\n/**\r\n * To prevent redundant logging\r\n */\r\nconst isAlreadyLogged: Record = {};\r\n\r\n/**\r\n * Initializer function that will populate the main localized resources object\r\n */\r\nfunction initializeLocalizerResources() {\r\n\tconst windowWithResources = window as WindowWithResources;\r\n\r\n\tif (\r\n\t\twindowWithResources &&\r\n\t\twindowWithResources.__ROC_LOCALIZER_RESOURCES__ &&\r\n\t\tArray.isArray(windowWithResources.__ROC_LOCALIZER_RESOURCES__)\r\n\t) {\r\n\t\twindowWithResources.__ROC_LOCALIZER_RESOURCES__.forEach((obj) => {\r\n\t\t\tfor (const key of Object.keys(obj)) {\r\n\t\t\t\tLocalizerResources[key] = obj[key];\r\n\t\t\t}\r\n\t\t});\r\n\t}\r\n}\r\n\r\n/**\r\n * Function that can be used to load the localized strings with support to parameter replacements\r\n *\r\n * @export\r\n * @param {string} key\r\n * @param {...string[]} replaceStrings\r\n * @returns\r\n */\r\nexport function Localizer(\r\n\tkey: TResourceKey,\r\n\t...replaceStrings: string[]\r\n) {\r\n\tif (Object.keys(LocalizerResources).length === 0) {\r\n\t\tinitializeLocalizerResources();\r\n\t}\r\n\r\n\tif (!LocalizerResources || !LocalizerResources[key]) {\r\n\t\t// if running in a test environment, just skip any warnings.\r\n\t\tif (process.env.NODE_ENV !== 'test') {\r\n\t\t\tif (!isAlreadyLogged[key]) {\r\n\t\t\t\tconsole.warn(key, 'Localizer Resource not found. Key will be used instead.');\r\n\t\t\t\tisAlreadyLogged[key] = true;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn key;\r\n\t}\r\n\r\n\tconst resource = LocalizerResources[key];\r\n\r\n\tif (!replaceStrings) {\r\n\t\treturn resource;\r\n\t}\r\n\r\n\treturn resource.replace(/{(\\d+)}/g, (match: string, index: number) => {\r\n\t\treturn replaceStrings[index] ? replaceStrings[index] : '';\r\n\t});\r\n}\r\n\r\n/**\r\n * Interface for the LocalizedSpan component\r\n *\r\n * @interface LocalizedSpanProps\r\n */\r\ninterface LocalizedSpanProps {\r\n\tresourceKey: LocalizerResourceKey;\r\n\targs?: string[];\r\n}\r\n\r\n/**\r\n * Component responsible for the initialization of the react app\r\n */\r\nexport function LocalizedSpan(props: LocalizedSpanProps) {\r\n\tconst { resourceKey, args = [] } = props;\r\n\tconst localizedString = Localizer(resourceKey, ...args);\r\n\r\n\treturn (\r\n\t\t\r\n\t);\r\n}\r\n","// source: https://developer.mozilla.org/en-US/docs/Web/API/CustomEvent/CustomEvent\r\n(function () {\r\n\tif (typeof window.CustomEvent === 'function') {\r\n\t\treturn false;\r\n\t}\r\n\r\n\tfunction CustomEvent(event, params) {\r\n\t\tparams = params || { bubbles: false, cancelable: false, detail: undefined };\r\n\t\t// eslint-disable-next-line\r\n\t\tvar evt = document.createEvent('CustomEvent');\r\n\t\tevt.initCustomEvent(event, params.bubbles, params.cancelable, params.detail);\r\n\t\treturn evt;\r\n\t}\r\n\r\n\tCustomEvent.prototype = window.Event.prototype;\r\n\r\n\twindow.CustomEvent = CustomEvent;\r\n})();\r\n","import React from 'react';\r\nimport { SVGProps } from './SVGProps';\r\nimport classnames from 'classnames';\r\n\r\n/**\r\n * Right chevron SVG\r\n *\r\n * @returns\r\n */\r\nfunction RightChevronSVG({ className, ...rest }: SVGProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default RightChevronSVG;\r\n","import React from 'react';\r\nimport { SVGProps } from './SVGProps';\r\nimport classnames from 'classnames';\r\n\r\n/**\r\n * Map pin SVG\r\n *\r\n * @returns\r\n */\r\nfunction MapPinSVG({ className, ...rest }: SVGProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default MapPinSVG;\r\n","import Axios, { AxiosRequestConfig, AxiosError, AxiosResponse, CancelTokenSource } from 'axios';\r\nimport { useLoader } from './useLoader';\r\nimport { useRef, useEffect, useState } from 'react';\r\nimport AxiosHelper from 'services/AxiosHelper';\r\n\r\n/**\r\n * Use Axios Loader Params\r\n * @param axiosParams The parameters for the request being passed into axios. This includes the method, url, data, etc.\r\n * @param callback A function that is called after a form is posted. It'll include a parameter with the error if something went wrong.\r\n */\r\nexport interface UseAxiosLoaderParams {\r\n\taxiosParams: AxiosRequestConfig;\r\n\tactive?: boolean;\r\n\tcallback?: (error: Error | AxiosError | undefined) => any;\r\n\tcacheKey?: string;\r\n}\r\n\r\nconst cache = {};\r\n\r\n/**\r\n * A reusable hook that facilitates executing axios requests.\r\n */\r\nexport function useAxiosLoader({ axiosParams, active = true, callback, cacheKey }: UseAxiosLoaderParams) {\r\n\tif (axiosParams.method === undefined) {\r\n\t\taxiosParams.method = 'GET';\r\n\t}\r\n\r\n\tconst { ...rest } = axiosParams;\r\n\tconst { loading, setLoading, error, setError, response, setResponse } = useLoader>();\r\n\tconst [reloadTimes, setReloadTimes] = useState(0);\r\n\tconst cancelToken = useRef();\r\n\r\n\tconst reload = () => {\r\n\t\tsetReloadTimes(reloadTimes + 1);\r\n\t};\r\n\r\n\tuseEffect(() => {\r\n\t\t(async () => {\r\n\t\t\ttry {\r\n\t\t\t\tif (!active) {\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tcancelToken.current = Axios.CancelToken.source();\r\n\r\n\t\t\t\tsetLoading(true);\r\n\t\t\t\tsetError(undefined);\r\n\r\n\t\t\t\tlet response: AxiosResponse;\r\n\r\n\t\t\t\tif (cacheKey && cache[cacheKey]) {\r\n\t\t\t\t\tresponse = cache[cacheKey];\r\n\t\t\t\t} else {\r\n\t\t\t\t\tresponse = await AxiosHelper(rest);\r\n\t\t\t\t\tif (cacheKey) {\r\n\t\t\t\t\t\tcache[cacheKey] = response;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\tsetResponse(response);\r\n\r\n\t\t\t\tif (callback !== undefined) {\r\n\t\t\t\t\treturn callback(undefined);\r\n\t\t\t\t}\r\n\t\t\t} catch (error) {\r\n\t\t\t\tif (Axios.isCancel(error)) {\r\n\t\t\t\t\t// if the component was unmounted, there's nothing to do\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tsetError(error);\r\n\r\n\t\t\t\tif (callback !== undefined) {\r\n\t\t\t\t\treturn callback(error);\r\n\t\t\t\t}\r\n\t\t\t} finally {\r\n\t\t\t\tsetLoading(false);\r\n\t\t\t}\r\n\t\t})();\r\n\r\n\t\treturn () => {\r\n\t\t\t// cleanup\r\n\t\t\tif (cancelToken.current) {\r\n\t\t\t\tcancelToken.current.cancel();\r\n\t\t\t}\r\n\t\t};\r\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\r\n\t}, [active, reloadTimes, ...Object.values(axiosParams)]); // this may be overkill? this means that if ANY axios params change, a new request will execute\r\n\r\n\treturn {\r\n\t\tloading,\r\n\t\terror,\r\n\t\tresponse,\r\n\t\tcancelToken: cancelToken.current,\r\n\t\treload,\r\n\t};\r\n}\r\n","import { useEffect, useState } from 'react';\r\nimport { SortByDirection } from 'shared-client/types/index';\r\nimport { BaseDto, PaginatedResult } from 'shared/types';\r\nimport { useAxiosLoader, UseAxiosLoaderParams } from './useAxiosLoader';\r\n\r\n/**\r\n * Use Axios Paginated Loader Params\r\n * @param axiosParams The parameters for the request being passed into axios. This includes the method, url, data, etc.\r\n * @param callback A function that is called after a form is posted. It'll include a parameter with the error if something went wrong.\r\n */\r\nexport interface UseAxiosPaginatedLoaderParams>\r\n\textends UseAxiosLoaderParams {\r\n\tquery?: string;\r\n\tinitialPageSize?: number;\r\n\tinitialSortByName?: string;\r\n\tinitialSortDirection?: SortByDirection;\r\n\tinitialResults?: T;\r\n\tcache?: boolean;\r\n}\r\n\r\n/**\r\n * The useAxiosPaginatedLoader hook result object\r\n */\r\nexport interface UseAxiosPaginatedLoaderResult> {\r\n\t/**\r\n\t * Current page number\r\n\t */\r\n\tpage: number;\r\n\t/**\r\n\t * Go to page and load results\r\n\t */\r\n\tgoToPage: (page: number) => void;\r\n\t/**\r\n\t * Go to next page and load results\r\n\t */\r\n\tgoToNextPage: () => void;\r\n\t/**\r\n\t * Go to previous page and load results\r\n\t */\r\n\tgoToPreviousPage: () => void;\r\n\t/**\r\n\t * Set sorting and load the results\r\n\t */\r\n\tsetSorting: (sortBy: string, direction: SortByDirection) => void;\r\n\t/**\r\n\t * Set page size and load the results\r\n\t */\r\n\tsetPageSize: (pageSize: number) => void;\r\n\t/**\r\n\t * Sets the custom query\r\n\t */\r\n\tsetQuery?: (query: string) => void;\r\n\t/**\r\n\t * Sets the sort by name\r\n\t */\r\n\tsetSortByName?: (sortBy: string) => void;\r\n\t/**\r\n\t * Sets the sort direction\r\n\t */\r\n\tsetSortDirection?: (direction: SortByDirection) => void;\r\n\t/**\r\n\t * Current sort by name\r\n\t */\r\n\tsortByName: string | undefined;\r\n\t/**\r\n\t * Current sort by direction\r\n\t */\r\n\tsortDirection: SortByDirection | undefined;\r\n\t/**\r\n\t * True if loading results\r\n\t */\r\n\tloading: boolean;\r\n\t/**\r\n\t * Error object if an error occurred while loading the results\r\n\t */\r\n\terror: Error | undefined;\r\n\t/**\r\n\t * Current paginated results object\r\n\t */\r\n\tresults: T | null | undefined;\r\n\r\n\t/**\r\n\t * Custom query string that includes\r\n\t * all the other parameters other than pagination and sorting ones\r\n\t */\r\n\tcustomQuery?: string | undefined;\r\n\r\n\t/**\r\n\t * If this function has been called another request will be triggered to get fresh results\r\n\t */\r\n\treload?: () => void;\r\n}\r\n\r\n/**\r\n * A reusable hook for pagination (data is loaded with axios).\r\n */\r\nexport function useAxiosPaginatedLoader>({\r\n\taxiosParams,\r\n\tactive = true,\r\n\tcallback,\r\n\tquery,\r\n\tinitialPageSize,\r\n\tinitialSortByName,\r\n\tinitialSortDirection,\r\n\tinitialResults,\r\n\tcache,\r\n}: UseAxiosPaginatedLoaderParams): UseAxiosPaginatedLoaderResult {\r\n\tconst [pageSize, setPageSizeState] = useState(initialPageSize);\r\n\tconst [pageNumber, setPageNumber] = useState(1);\r\n\tconst [sortByName, setSortByName] = useState(initialSortByName);\r\n\tconst [sortDirection, setSortDirection] = useState(initialSortDirection);\r\n\tconst [dataLoaderActive, setDataLoaderActive] = useState(initialResults === undefined);\r\n\tconst [customQuery, setCustomQuery] = useState(query);\r\n\r\n\tuseEffect(() => {\r\n\t\tsetDataLoaderActive(true);\r\n\t}, [pageNumber, sortByName, sortDirection, pageSize]);\r\n\r\n\tconst goToPage = (page: number) => {\r\n\t\tif (results && page > 0 && page <= results.pagination.totalPages) {\r\n\t\t\tsetPageNumber(page);\r\n\t\t}\r\n\t};\r\n\r\n\tconst goToNextPage = () => {\r\n\t\tif (results && pageNumber < results.pagination.totalPages) {\r\n\t\t\tsetPageNumber(pageNumber + 1);\r\n\t\t}\r\n\t};\r\n\r\n\tconst goToPreviousPage = () => {\r\n\t\tif (pageNumber === 1) {\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tsetPageNumber(pageNumber - 1);\r\n\t};\r\n\r\n\tconst setSorting = (sortBy: string, direction: SortByDirection) => {\r\n\t\tsetPageNumber(1);\r\n\t\tsetSortByName(sortBy);\r\n\t\tsetSortDirection(direction);\r\n\t};\r\n\r\n\tconst setQuery = (customQuery: string | undefined) => {\r\n\t\tsetPageNumber(1);\r\n\t\tsetCustomQuery(customQuery);\r\n\t};\r\n\r\n\tconst paginationQuery = `${pageSize ? `pagesize=${pageSize}` : ''}&pageNumber=${pageNumber}${\r\n\t\tsortByName ? `&sortBy=${sortByName}` : ''\r\n\t}${sortDirection ? `&sortDirection=${sortDirection}` : ''}`;\r\n\r\n\tconst url = `${axiosParams.url}${customQuery ? `?${customQuery}&${paginationQuery}` : `?${paginationQuery}`}`;\r\n\r\n\tconst { loading, error, response, reload } = useAxiosLoader({\r\n\t\taxiosParams: {\r\n\t\t\t...axiosParams,\r\n\t\t\turl: url,\r\n\t\t},\r\n\t\tactive: active && dataLoaderActive,\r\n\t\tcallback,\r\n\t\tcacheKey: cache ? url : undefined,\r\n\t});\r\n\r\n\tconst results = active && dataLoaderActive ? response && response.data : initialResults;\r\n\r\n\tconst setPageSize = (size: number) => {\r\n\t\tsetPageSizeState(size);\r\n\t};\r\n\r\n\treturn {\r\n\t\tpage: pageNumber,\r\n\t\tgoToPage,\r\n\t\tgoToNextPage,\r\n\t\tgoToPreviousPage,\r\n\t\tsetSorting,\r\n\t\tsetPageSize,\r\n\t\tsetQuery,\r\n\t\tsetSortByName,\r\n\t\tsetSortDirection,\r\n\t\treload,\r\n\t\tcustomQuery,\r\n\t\tsortByName,\r\n\t\tsortDirection,\r\n\t\tloading,\r\n\t\terror,\r\n\t\tresults,\r\n\t};\r\n}\r\n","// Extra large desktop breakpoint.\r\nexport const xlg = 1200;\r\n\r\n// Desktop breakpoint.\r\nexport const lg = 992;\r\n\r\n// Tablet breakpoint.\r\nexport const md = 768;\r\n\r\n// Mobile breakpoint.\r\nexport const sm = 576;\r\n","import React from 'react';\r\nimport useDelayedDisplay from 'shared/hooks/useDelayedDisplay';\r\nimport classnames from 'classnames';\r\n\r\ntype SpinnerAlignment = 'left' | 'right' | 'none';\r\n\r\ninterface SpinnerProps {\r\n\tlight?: boolean;\r\n\twaitMs?: number;\r\n\talign?: SpinnerAlignment;\r\n\tblock?: boolean;\r\n\tparentCentered?: boolean;\r\n}\r\n\r\n/**\r\n * Reusable roc-spinner component with color, alignment and wait time props.\r\n *\r\n * @export\r\n * @param {SpinnerProps} { light = false, waitMs = 200, align = 'right', block }\r\n * @returns\r\n */\r\nexport default function Spinner({\r\n\tlight = false,\r\n\twaitMs = 200,\r\n\talign = 'right',\r\n\tblock,\r\n\tparentCentered = false,\r\n}: SpinnerProps) {\r\n\tconst display = useDelayedDisplay(waitMs);\r\n\r\n\tif (!display) {\r\n\t\treturn null;\r\n\t}\r\n\r\n\tconst spinner = (\r\n\t\t\r\n\t\t\t
\r\n\t\t\t\t
\r\n\t\t\t\t
\r\n\t\t\t
\r\n\t\t
\r\n\t);\r\n\r\n\tif (parentCentered) {\r\n\t\treturn
{spinner}
;\r\n\t}\r\n\r\n\treturn spinner;\r\n}\r\n","import React from 'react';\r\nimport { SVGProps } from './SVGProps';\r\nimport classnames from 'classnames';\r\n\r\n/**\r\n * Spinner SVG for loading purposes\r\n *\r\n * @returns\r\n */\r\nfunction MagnifyingGlassSVG({ className, ...rest }: SVGProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default MagnifyingGlassSVG;\r\n","import React from 'react';\r\nimport { LocationDto } from './types';\r\nimport MapPinSVG from 'shared/components/svg/MapPinSVG';\r\nimport type MediaQuery from 'react-responsive';\r\nimport Spinner from 'shared/components/Spinner';\r\nimport { Localizer } from 'services/Localizer';\r\nconst LazyMediaQuery = React.lazy(() => import('react-responsive'));\r\n\r\ninterface StoreLocationFormattedAddressProps {\r\n\t/**\r\n\t * The store location to display\r\n\t */\r\n\tlocation: LocationDto;\r\n\t/**\r\n\t * The distance unit, if any\r\n\t */\r\n\tdistanceUnit?: string;\r\n\t/**\r\n\t * The callback fired when the location name is clicked\r\n\t */\r\n\tonPinClicked?: () => void;\r\n\r\n\tbigTitle?: boolean;\r\n\r\n\tshowTitle?: boolean;\r\n\r\n\tindex?: number;\r\n}\r\n\r\n/**\r\n * Component that displays the address and pin for any particular location\r\n *\r\n * @export\r\n * @param {StoreLocationFormattedAddressProps} props\r\n * @returns\r\n */\r\nexport default function StoreLocationFormattedAddress({\r\n\tlocation,\r\n\tdistanceUnit = 'mi',\r\n\tonPinClicked,\r\n\tbigTitle = false,\r\n\tshowTitle = true,\r\n\tindex = 0,\r\n}: StoreLocationFormattedAddressProps) {\r\n\tconst Pin = onPinClicked ? (\r\n\t\t {\r\n\t\t\t\tonPinClicked();\r\n\t\t\t}}\r\n\t\t\ttype=\"button\"\r\n\t\t\tclassName=\"roc-store-locator-address__map-pin\"\r\n\t\t\taria-label={Localizer('Location') + ' ' + location.name}\r\n\t\t>\r\n\t\t\t\r\n\t\t\r\n\t) : null;\r\n\r\n\treturn (\r\n\t\t}>\r\n\t\t\t
\r\n\t\t\t\t{Pin}\r\n\r\n\t\t\t\t{showTitle && bigTitle ? (\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t{location.name}\r\n\t\t\t\t\t\r\n\t\t\t\t) : showTitle ? (\r\n\t\t\t\t\t

\r\n\t\t\t\t\t\t{location.name}\r\n\t\t\t\t\t

\r\n\t\t\t\t) : null}\r\n\r\n\t\t\t\t{location.address1}\r\n\r\n\t\t\t\t{location.address2 ? (\r\n\t\t\t\t\t{location.address2}\r\n\t\t\t\t) : null}\r\n\r\n\t\t\t\t{location.city}, \r\n\r\n\t\t\t\t\r\n\t\t\t\t\t{location.country === 'US' || location.country === 'CA'\r\n\t\t\t\t\t\t? location.state\r\n\t\t\t\t\t\t\t? location.state + ' '\r\n\t\t\t\t\t\t\t: ' '\r\n\t\t\t\t\t\t: location.region\r\n\t\t\t\t\t\t? location.region + ' '\r\n\t\t\t\t\t\t: ' '}\r\n\t\t\t\t\r\n\r\n\t\t\t\t{location.postalCode}\r\n\r\n\t\t\t\t{location.phoneNumber ? (\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t{location.phoneNumber}\r\n\t\t\t\t\t\r\n\t\t\t\t) : null}\r\n\r\n\t\t\t\t{location.distance ? (\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t{location.distance.toFixed(2)}\r\n\t\t\t\t\t\t{distanceUnit}\r\n\t\t\t\t\t\r\n\t\t\t\t) : null}\r\n\r\n\t\t\t\t\r\n\t\t\t\t\t{Pin}\r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t
\r\n\t);\r\n}\r\n","import React from 'react';\r\nimport { LocationDto } from './types';\r\nimport Spinner from 'shared/components/Spinner';\r\nimport { Localizer } from 'services/Localizer';\r\nimport { WithTestIdOptional } from 'shared-client/types/test';\r\n\r\ninterface DefaultStoreLocationResultsItemProps extends WithTestIdOptional {\r\n\tlocation: LocationDto;\r\n\tsaveDefaultLocation: (location: LocationDto) => Promise;\r\n\tisSavingDefaultLocation: boolean;\r\n\tdefaultStoreLocation: LocationDto | null;\r\n}\r\n\r\n/**\r\n * Component that either displays a link to make the current store your \"Default\" store.\r\n * Or displays a flag that shows that it IS your current store.\r\n *\r\n * @export\r\n * @param {DefaultStoreLocationResultsItem} props\r\n * @returns\r\n */\r\nexport default function DefaultStoreLocationResultsItem(props: DefaultStoreLocationResultsItemProps) {\r\n\tconst { location, testId, saveDefaultLocation, isSavingDefaultLocation, defaultStoreLocation } = props;\r\n\r\n\treturn defaultStoreLocation && defaultStoreLocation.id === location.id ? (\r\n\t\t
\r\n\t\t\t\r\n\t\t\t\t{Localizer('MyStore')}\r\n\t\t\t\r\n\t\t\t{isSavingDefaultLocation ? : null}\r\n\t\t
\r\n\t) : (\r\n\t\t
\r\n\t\t\t {\r\n\t\t\t\t\tsaveDefaultLocation(location);\r\n\t\t\t\t}}\r\n\t\t\t\tdisabled={isSavingDefaultLocation}\r\n\t\t\t\tdata-testid={`${testId}-button`}\r\n\t\t\t>\r\n\t\t\t\t{Localizer('MakeMyStore')} {isSavingDefaultLocation ? : null}\r\n\t\t\t\r\n\t\t
\r\n\t);\r\n}\r\n","import React, { useEffect, useRef, useState } from 'react';\r\nimport { Pagination as PaginationType } from 'shared/types';\r\nimport LeftChevronSVG from './svg/LeftChevronSVG';\r\nimport RightChevronSVG from './svg/RightChevronSVG';\r\nimport { Localizer } from 'services/Localizer';\r\nimport classnames from 'classnames';\r\nimport { createGuid } from './hawksearch/helpers/Cookies';\r\n\r\ninterface PaginationProps {\r\n\tpagination: PaginationType;\r\n\tgoToNextPage: () => void;\r\n\tgoToPreviousPage: () => void;\r\n\tgoToPage: (page: number) => void;\r\n\tflush?: boolean;\r\n}\r\n\r\nexport default function Pagination(props: PaginationProps) {\r\n\tconst {\r\n\t\tflush,\r\n\t\tpagination: { totalPages, hasNextPage, hasPreviousPage, pageNumber },\r\n\t\tgoToNextPage,\r\n\t\tgoToPage,\r\n\t\tgoToPreviousPage,\r\n\t} = props;\r\n\r\n\tconst [uniqueId] = useState(`pagination-input-${createGuid()}`);\r\n\r\n\tconst [localPageNumber, setLocalPageNumber] = useState(undefined);\r\n\r\n\tconst timerRef = useRef(null);\r\n\r\n\t// make sure that the local page number state override is cleared out whenever the pagination page number\r\n\t// changes. this happens whenever a server request is completed and the lifted pagination state is updated\r\n\tuseEffect(() => {\r\n\t\tsetLocalPageNumber(undefined);\r\n\t}, [pageNumber]);\r\n\r\n\tfunction attemptGoToPage(newPageNumber: number) {\r\n\t\tif (newPageNumber < 1 || newPageNumber > totalPages) {\r\n\t\t\t// an invalid page number was entered, so clear out the user entry and do nothing.\r\n\t\t\tsetLocalPageNumber(undefined);\r\n\t\t} else {\r\n\t\t\tgoToPage(newPageNumber);\r\n\t\t}\r\n\t}\r\n\r\n\t// debounce the pager updates\r\n\tuseEffect(() => {\r\n\t\tif (timerRef.current) {\r\n\t\t\tclearTimeout(timerRef.current);\r\n\t\t}\r\n\r\n\t\ttimerRef.current = setTimeout(() => {\r\n\t\t\tif (localPageNumber) {\r\n\t\t\t\tattemptGoToPage(parseInt(localPageNumber));\r\n\t\t\t}\r\n\t\t}, 500);\r\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\r\n\t}, [localPageNumber]);\r\n\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\t\t\r\n\t\t\t\r\n\r\n\t\t\t\r\n\r\n\t\t\t{Localizer('OfTotalPages', totalPages.toLocaleString())}\r\n\r\n\t\t\t\r\n\t\t\t\t\r\n\t\t\t\r\n\t\t
\r\n\t);\r\n}\r\n","import axios, { AxiosInstance, AxiosResponse, AxiosError } from 'axios';\r\nimport AccountUrls from 'shared/util/AccountUrls';\r\nimport { getCsrfToken } from './UserData';\r\n\r\n/**\r\n * Helper that creates an instance of Axios to be used throughout the client application\r\n * and adds a default X-Requested-With header to all requests.\r\n *\r\n */\r\nconst AxiosHelper: AxiosInstance = axios.create();\r\nAxiosHelper.defaults.headers.common['X-Requested-With'] = 'XMLHttpRequest';\r\n\r\n// Add CSRF tokens to all commands that are not GET, HEAD, or OPTIONS\r\nAxiosHelper.interceptors.request.use(async (config) => {\r\n\tif (\r\n\t\tconfig.method?.toLowerCase() !== 'get' &&\r\n\t\tconfig.method?.toLowerCase() !== 'head' &&\r\n\t\tconfig.method?.toLowerCase() !== 'options'\r\n\t) {\r\n\t\tconst csrfToken = await getCsrfToken();\r\n\t\tconfig.headers = { RequestVerificationToken: csrfToken, ...config.headers };\r\n\t}\r\n\treturn config;\r\n});\r\n\r\nexport default AxiosHelper;\r\n\r\n// eslint-disable-next-line no-unused-vars\r\nexport const addUnauthorizedAccessInterceptor = (history) => {\r\n\t// this allows us to act when any request going through axios succeeds or fails.\r\n\tAxiosHelper.interceptors.response.use(\r\n\t\t(response: AxiosResponse) => {\r\n\t\t\treturn response;\r\n\t\t},\r\n\t\t(error: AxiosError) => {\r\n\t\t\tif (error.response && error.response.status === 401) {\r\n\t\t\t\twindow.location.replace(\r\n\t\t\t\t\t`${AccountUrls.Login}?ReturnUrl=${encodeURIComponent(window.location.pathname)}`,\r\n\t\t\t\t);\r\n\t\t\t}\r\n\r\n\t\t\treturn Promise.reject(error);\r\n\t\t},\r\n\t);\r\n};\r\n","import React from 'react';\r\nimport classnames from 'classnames';\r\nimport CircleExclamationSVG from 'shared/components/svg/CircleExclamationSVG';\r\nimport { useField } from 'react-final-form';\r\n\r\ninterface FieldInputErrorWrapperProps {\r\n\thideIcon?: boolean;\r\n\tchildren: React.ReactNode;\r\n\tinline?: boolean;\r\n\tname: string;\r\n}\r\n\r\n/**\r\n * Component for handling the invalid styles for inputs.\r\n *\r\n * @export\r\n * @param {FieldInputErrorWrapperProps} props\r\n * @returns\r\n */\r\nexport default function FieldInputErrorWrapper(props: FieldInputErrorWrapperProps) {\r\n\tconst { hideIcon = false, children, inline = false, name } = props;\r\n\tconst { meta } = useField(name);\r\n\tconst invalid =\r\n\t\t(meta.error || (meta.submitError && !meta.dirtySinceLastSubmit && !meta.submitting)) &&\r\n\t\tmeta.touched &&\r\n\t\tmeta.invalid\r\n\t\t\t? meta.invalid\r\n\t\t\t: false;\r\n\r\n\treturn (\r\n\t\t\r\n\t\t\t{children}\r\n\t\t\t{invalid && !hideIcon ? : null}\r\n\t\t\r\n\t);\r\n}\r\n","import React from 'react';\r\nimport { Localizer } from 'services/Localizer';\r\nimport classnames from 'classnames';\r\n\r\n/**\r\n * Store Details Component Props\r\n */\r\ninterface StoreDetailsProps {\r\n\turl: string | null;\r\n\tsearchText: string | null;\r\n\tlink?: boolean;\r\n}\r\n\r\n/**\r\n * Renders a button (link) that points to the store details page.\r\n * @param props\r\n */\r\nexport default function StoreDetailsButton(props: StoreDetailsProps) {\r\n\tconst { url, searchText, link } = props;\r\n\r\n\treturn (\r\n\t\t\r\n\t\t\t{Localizer('StoreDetails')}\r\n\t\t\r\n\t);\r\n}\r\n","import React from 'react';\r\nimport { LocationDto, StoreLocatorSearchResults } from './types';\r\nimport StoreLocationGetDirections from './StoreLocationGetDirections';\r\nimport StoreDetailsButton from '../store-details/StoreDetailsButton';\r\n\r\ninterface StoreLocationOptionsProps {\r\n\tlocation: LocationDto;\r\n\tsearchResults: StoreLocatorSearchResults | null;\r\n}\r\n\r\n/**\r\n * Directions and details links for a particular location listing.\r\n *\r\n * @export\r\n * @param {StoreLocationOptionsProps} props\r\n * @returns\r\n */\r\nexport default function StoreLocationOptions(props: StoreLocationOptionsProps) {\r\n\tconst { location, searchResults } = props;\r\n\r\n\treturn (\r\n\t\t<>\r\n\t\t\t{searchResults ? (\r\n\t\t\t\t
\r\n\t\t\t\t\t\r\n\r\n\t\t\t\t\t{location.url ? (\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t) : null}\r\n\t\t\t\t
\r\n\t\t\t) : null}\r\n\t\t\r\n\t);\r\n}\r\n","import React from 'react';\r\nimport { SVGProps } from './SVGProps';\r\nimport classnames from 'classnames';\r\n\r\n/**\r\n * External link SVG\r\n *\r\n * @returns\r\n */\r\nfunction ExternalLinkSVG({ className, ...rest }: SVGProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default ExternalLinkSVG;\r\n","import React from 'react';\r\nimport { LocationDto, Geolocation } from './types';\r\nimport ExternalLinkSVG from 'shared/components/svg/ExternalLinkSVG';\r\nimport { Localizer } from 'services/Localizer';\r\n\r\nfunction getGoogleMapsDirectionsUrl(searchText: string | null, targetLocation: Geolocation) {\r\n\tconst directionsUrl = '//google.com/maps/dir/';\r\n\r\n\t// more details about creating a query can be found in docs:\r\n\t// https://developers.google.com/maps/documentation/urls/guide#directions-action\r\n\tlet query = '?api=1';\r\n\tif (searchText) {\r\n\t\tquery += `&origin=${searchText}`;\r\n\t}\r\n\r\n\tquery += `&destination=${targetLocation.latitude},${targetLocation.longitude}`;\r\n\r\n\treturn `${directionsUrl}${query}`;\r\n}\r\n\r\ninterface StoreLocationGetDirectionsProps {\r\n\torigin: string | null;\r\n\tlocation: LocationDto;\r\n}\r\n/**\r\n * Displays \"Get Directions\" button which opens Google Maps with directions to the given store location\r\n * @param props\r\n */\r\nexport default function StoreLocationGetDirections(props: StoreLocationGetDirectionsProps) {\r\n\tconst { origin, location } = props;\r\n\r\n\treturn (\r\n\t\t<>\r\n\t\t\t\r\n\t\t\t\t{Localizer('GetDirections')}\r\n\t\t\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n","import Axios, { CancelTokenSource, AxiosError } from 'axios';\r\nimport { useState } from 'react';\r\nimport AxiosHelper from 'services/AxiosHelper';\r\nimport { useAxiosPaginatedLoader } from 'shared/hooks/useAxiosPaginatedLoader';\r\nimport { dispatchRocEvent } from 'shared/hooks/useRocEventHandler';\r\nimport { LocationDto, StoreLocatorSearchResults } from './types';\r\n\r\nexport interface StoreLocatorState {\r\n\t/**\r\n\t * If true, the default store location is being saved on the server\r\n\t */\r\n\tisSaving: boolean;\r\n\t/**\r\n\t * If true, an error has occured when saving default store location\r\n\t */\r\n\tsavingError: Error | AxiosError | null;\r\n\t/**\r\n\t * If true, an error has occured when searching store locations\r\n\t */\r\n\tloadingError: Error | AxiosError | null;\r\n\t/**\r\n\t * The default store location, if any\r\n\t */\r\n\tdefaultStoreLocation?: LocationDto;\r\n\t/**\r\n\t * If true, the search is in progress\r\n\t */\r\n\tisLoading: boolean;\r\n\t/**\r\n\t * The last search results, if any\r\n\t */\r\n\tsearchResults: StoreLocatorSearchResults | null | undefined;\r\n\t/**\r\n\t * The search text to look up stores by. Can include zip/city/etc.\r\n\t */\r\n\tsearchText: string;\r\n\t/**\r\n\t * Determines whether searches are being executed right now or not. This is passed to useAxiosPaginatedLoader.\r\n\t */\r\n\tdataLoaderActive: boolean;\r\n}\r\n\r\nexport interface StoreLocatorActor {\r\n\tsaveDefaultLocation: (location: LocationDto) => Promise;\r\n\tsetSearchText: (text: string) => void;\r\n\tgoToPage: (pageNumber: number) => void;\r\n\tgoToNextPage: () => void;\r\n\tgoToPreviousPage: () => void;\r\n\tsetDataLoaderActive: (active: boolean) => void;\r\n}\r\n\r\nexport interface UseStoreLocator {\r\n\tstate: StoreLocatorState;\r\n\tactor: StoreLocatorActor;\r\n}\r\n\r\nexport interface UseStoreLocatorParams {\r\n\t/**\r\n\t * Initial search text, please provide if you want to perform search on init\r\n\t */\r\n\tinitSearchText?: string;\r\n\t/**\r\n\t * Current default store location or null if there is no default location\r\n\t */\r\n\tdefaultStoreLocation?: LocationDto;\r\n\t/**\r\n\t * The page size for store locator search results\r\n\t */\r\n\tpageSize?: number;\r\n}\r\n\r\n/**\r\n * Reusable hook to access Store Location-related endpoints on the server.\r\n */\r\nexport function useStoreLocator(useStoreLocationParams: UseStoreLocatorParams): UseStoreLocator {\r\n\tconst { defaultStoreLocation } = useStoreLocationParams;\r\n\tconst pageSize = useStoreLocationParams.pageSize || 10;\r\n\r\n\tconst [savingError, setSavingError] = useState(null);\r\n\tconst [isSaving, setIsSaving] = useState(false);\r\n\tconst [searchText, setSearchTextInternal] = useState(useStoreLocationParams.initSearchText || '');\r\n\tconst [dataLoaderActive, setDataLoaderActive] = useState(false);\r\n\r\n\tconst { goToPage, goToNextPage, goToPreviousPage, setQuery, error, loading, results } = useAxiosPaginatedLoader<\r\n\t\tLocationDto,\r\n\t\tStoreLocatorSearchResults\r\n\t>({\r\n\t\taxiosParams: {\r\n\t\t\turl: '/ajax/store-locator/',\r\n\t\t},\r\n\t\tquery: `searchText=${searchText}`,\r\n\t\tinitialPageSize: pageSize,\r\n\t\tactive: dataLoaderActive,\r\n\t});\r\n\r\n\t// initialize ROC event dispatched that will be used to dispatch events anytime a new store location is saved\r\n\tfunction locationChangeDispatcher(location?: LocationDto) {\r\n\t\tdispatchRocEvent('roc-default-store-location-changed', { location });\r\n\t}\r\n\r\n\tfunction setSearchText(value: string) {\r\n\t\tsetSearchTextInternal(value);\r\n\r\n\t\tif (setQuery) {\r\n\t\t\tsetQuery(`searchText=${value}`);\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Marks a store location as default on the server\r\n\t */\r\n\tconst saveDefaultLocation = async (location: LocationDto): Promise => {\r\n\t\tsetIsSaving(true);\r\n\r\n\t\tconst requestToken: CancelTokenSource = Axios.CancelToken.source();\r\n\r\n\t\ttry {\r\n\t\t\tawait AxiosHelper.post(`/ajax/store-locator/set-default/${location.id}`, {\r\n\t\t\t\tsearchString: searchText,\r\n\t\t\t\tdistance: location.distance,\r\n\t\t\t\tcancelToken: requestToken.token,\r\n\t\t\t});\r\n\r\n\t\t\tsetSavingError(null);\r\n\t\t\tlocationChangeDispatcher(location);\r\n\t\t} catch (error) {\r\n\t\t\tif (Axios.isCancel(error)) {\r\n\t\t\t\t// if the component was unmounted, there's nothing to do\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tsetSavingError(error);\r\n\t\t\tconsole.error('An error occurred while saving is default.', error);\r\n\t\t} finally {\r\n\t\t\tsetIsSaving(false);\r\n\t\t}\r\n\t};\r\n\r\n\treturn {\r\n\t\tstate: {\r\n\t\t\tisSaving,\r\n\t\t\tsavingError: savingError,\r\n\t\t\tloadingError: error ?? null,\r\n\t\t\tdefaultStoreLocation,\r\n\t\t\tisLoading: loading,\r\n\t\t\tsearchResults: results,\r\n\t\t\tsearchText,\r\n\t\t\tdataLoaderActive,\r\n\t\t},\r\n\t\tactor: {\r\n\t\t\tsaveDefaultLocation,\r\n\t\t\tsetSearchText,\r\n\t\t\tgoToNextPage,\r\n\t\t\tgoToPreviousPage,\r\n\t\t\tgoToPage,\r\n\t\t\tsetDataLoaderActive,\r\n\t\t},\r\n\t};\r\n}\r\n","import { useState, useEffect } from 'react';\r\nimport { AxiosError } from 'axios';\r\nimport Axios from 'axios';\r\nimport { LocationDto } from '../store-locator/types';\r\nimport { getUserData } from 'services/UserData';\r\nimport useRocEventHandler from 'shared/hooks/useRocEventHandler';\r\n\r\nexport interface UseDefaultStoreLocationResult {\r\n\tisLoading: boolean;\r\n\tdefaultStoreLocation?: LocationDto;\r\n\tsetDefaultStoreLocation: (location?: LocationDto) => void;\r\n}\r\n\r\n/**\r\n * Custom hook to load default store location from services/UserData (getUserData) promise and to handle default\r\n * store location changes on the client by listening to browser events\r\n */\r\nexport function useDefaultStoreLocationLoader(): UseDefaultStoreLocationResult {\r\n\tconst [isLoading, setIsLoading] = useState(false);\r\n\tconst [defaultStoreLocation, setDefaultStoreLocation] = useState(undefined);\r\n\r\n\t// define event handler for store location changes that will be handling state updates anytime it is changed by any other component\r\n\tuseRocEventHandler(\r\n\t\t'roc-default-store-location-changed',\r\n\t\t({ location }) => {\r\n\t\t\tsetDefaultStoreLocation(location);\r\n\t\t},\r\n\t\t[setDefaultStoreLocation],\r\n\t);\r\n\r\n\t// when the component mounts, begin loading the current user's default store location.\r\n\tuseEffect(() => {\r\n\t\t(async () => {\r\n\t\t\ttry {\r\n\t\t\t\tsetIsLoading(true);\r\n\t\t\t\tconst userDataResponse = (await getUserData()).data;\r\n\t\t\t\tif (userDataResponse.defaultStoreLocation) {\r\n\t\t\t\t\tsetDefaultStoreLocation(userDataResponse.defaultStoreLocation);\r\n\t\t\t\t}\r\n\t\t\t} catch (error) {\r\n\t\t\t\tif (Axios.isCancel(error)) {\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\t\t\t\tconst axiosError = error as AxiosError;\r\n\t\t\t\tconsole.error(`An error occurred while loading user data: ${axiosError.message}`);\r\n\t\t\t} finally {\r\n\t\t\t\tsetIsLoading(false);\r\n\t\t\t}\r\n\t\t})();\r\n\t}, []);\r\n\r\n\treturn {\r\n\t\tdefaultStoreLocation,\r\n\t\tsetDefaultStoreLocation,\r\n\t\tisLoading,\r\n\t};\r\n}\r\n","import React from 'react';\r\nimport { SVGProps } from './SVGProps';\r\nimport classnames from 'classnames';\r\n\r\n/**\r\n * Map pin solid SVG\r\n *\r\n * @returns\r\n */\r\nfunction MapPinSolidSVG({ className, ...rest }: SVGProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default MapPinSolidSVG;\r\n","import React from 'react';\r\nimport { Localizer } from 'services/Localizer';\r\nimport StoreLocationFormattedAddress from './StoreLocationFormattedAddress';\r\nimport { LocationDto, StoreLocatorSearchResults } from './types';\r\nimport MapPinSolidSVG from 'shared/components/svg/MapPinSolidSVG';\r\nimport classnames from 'classnames';\r\nimport StoreLocationOptions from './StoreLocationOptions';\r\nimport DefaultStoreLocationResultsItem from './DefaultStoreLocationResultsItem';\r\nimport XSVG from 'shared/components/svg/XSVG';\r\n\r\n/**\r\n * Google Maps Marker Component Props\r\n */\r\ninterface GoogleMapsMarkerProps {\r\n\t/**\r\n\t * Location DTO\r\n\t */\r\n\tdto: LocationDto | null;\r\n\r\n\t/**\r\n\t * Active, true if the marker is clicked\r\n\t */\r\n\tactive: boolean;\r\n\r\n\t/**\r\n\t * This is set by the parent GoogleMapReact component\r\n\t */\r\n\t$hover?: boolean;\r\n\r\n\t/**\r\n\t * Latitude needed for the parent GoogleMapReact component\r\n\t */\r\n\tlat: number;\r\n\r\n\t/**\r\n\t * Longitude needed for the parent GoogleMapReact component\r\n\t */\r\n\tlng: number;\r\n\r\n\t/**\r\n\t * The list of store locator search results\r\n\t */\r\n\tsearchResults?: StoreLocatorSearchResults | null;\r\n\r\n\t/**\r\n\t * Callback to save a location as the default for the current user\r\n\t */\r\n\tsaveDefaultLocation?: (location: LocationDto) => Promise;\r\n\r\n\t/**\r\n\t * Determines if a default location is currently being saved\r\n\t */\r\n\tisSavingDefaultLocation?: boolean;\r\n\r\n\t/**\r\n\t * Returns a reference to the currently set default store location\r\n\t */\r\n\tdefaultStoreLocation?: LocationDto | null;\r\n\r\n\t/**\r\n\t * State method to change active marker key of store locator compoennt\r\n\t */\r\n\tsetActiveMarkerKey?: (prop: number | null) => void;\r\n}\r\n\r\n/**\r\n * Display a marker on a google map (GoogleMapReact), supports hover and click (active)\r\n * @param props\r\n */\r\nexport default function GoogleMapsMarker(props: GoogleMapsMarkerProps) {\r\n\tconst {\r\n\t\t$hover,\r\n\t\tactive,\r\n\t\tdto,\r\n\t\tsearchResults,\r\n\t\tsaveDefaultLocation,\r\n\t\tisSavingDefaultLocation = false,\r\n\t\tdefaultStoreLocation,\r\n\t\tsetActiveMarkerKey,\r\n\t} = props;\r\n\r\n\tconst icon = ;\r\n\r\n\treturn active ? (\r\n\t\t\r\n\t\t\t{icon}\r\n\t\t\t{dto && searchResults && saveDefaultLocation ? (\r\n\t\t\t\t
\r\n\t\t\t\t\t
\r\n\t\t\t\t\t\t {\r\n\t\t\t\t\t\t\t\tif (setActiveMarkerKey) {\r\n\t\t\t\t\t\t\t\t\tsetActiveMarkerKey(null);\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t}}\r\n\t\t\t\t\t\t\ttype=\"button\"\r\n\t\t\t\t\t\t>\r\n\t\t\t\t\t\t\t{Localizer('Close')}\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t
\r\n\r\n\t\t\t\t\t\r\n\r\n\t\t\t\t\t\r\n\r\n\t\t\t\t\t\r\n\t\t\t\t
\r\n\t\t\t) : null}\r\n\t\t\r\n\t) : (\r\n\t\ticon\r\n\t);\r\n}\r\n","/* eslint-disable jsx-a11y/label-has-for */\r\nimport React from 'react';\r\nimport { WithTestIdOptional } from 'shared-client/types/test';\r\nimport { toKebabCase } from 'util/StringUtil';\r\nimport OptionalFieldMarker from '../OptionalFieldMarker';\r\n\r\nexport interface FieldLabelProps extends WithTestIdOptional {\r\n\tlabel: string;\r\n\tname: string;\r\n\tid?: string;\r\n\tisRequired: boolean;\r\n\thtmlFor?: string;\r\n\tchildren?: React.ReactNode;\r\n}\r\n\r\n/**\r\n * Wrapper component for all field labels for ease of use.\r\n */\r\nexport default function FieldLabel(props: FieldLabelProps) {\r\n\tconst { label, id, isRequired, htmlFor, children, testId } = props;\r\n\r\n\tif (!label || !label.trim()) {\r\n\t\treturn null;\r\n\t}\r\n\r\n\treturn (\r\n\t\t\r\n\t\t\t{label}\r\n\t\t\t{!isRequired ? : null}\r\n\t\t\t{children ? children : null}\r\n\t\t\r\n\t);\r\n}\r\n","import React from 'react';\r\nimport classnames from 'classnames';\r\nimport { Localizer } from 'services/Localizer';\r\nimport { AxiosError } from 'axios';\r\nimport XSVG from 'shared/components/svg/XSVG';\r\n\r\ntype Theme = 'danger' | 'warning' | 'info' | 'success';\r\n\r\nexport interface ErrorAlertProps {\r\n\t/**\r\n\t * The title of the error message such as \"Uh Oh!\" or \"An Unexpected Error has Occurred!\"\r\n\t */\r\n\ttitle: string;\r\n\r\n\t/**\r\n\t * The error message to display if an error object doesn't have a more appropriate message.\r\n\t */\r\n\tmessage: React.ReactNode | string;\r\n\r\n\tchildren?: any;\r\n\r\n\ttheme?: Theme;\r\n\r\n\tisTitleOnOwnRow?: boolean;\r\n\r\n\t/** The error responsible for this message. */\r\n\terror: AxiosError | Error | null;\r\n\r\n\t/**\r\n\t * Method from parent that handles collapse state.\r\n\t */\r\n\tonCollapse?: (collased: boolean) => void;\r\n\r\n\t/**\r\n\t * Controlled collapse state from parent.\r\n\t */\r\n\tisCollapsed?: boolean;\r\n}\r\n\r\n/**\r\n * Reusable Error Alert Component.\r\n */\r\nexport default function InlineAlert(props: ErrorAlertProps) {\r\n\tconst {\r\n\t\ttitle = InlineAlert.defaultProps.title,\r\n\t\tchildren,\r\n\t\ttheme = 'danger',\r\n\t\tisTitleOnOwnRow = false,\r\n\t\terror = InlineAlert.defaultProps.error,\r\n\t\tisCollapsed = false,\r\n\t\tonCollapse,\r\n\t} = props;\r\n\r\n\tlet { message = InlineAlert.defaultProps.message } = props;\r\n\r\n\tconst axiosError = error as AxiosError | null;\r\n\tif (axiosError?.isAxiosError && axiosError != null && axiosError.response == null && axiosError.request != null) {\r\n\t\tmessage = Localizer('ErrorMessageNetwork');\r\n\t}\r\n\r\n\tif (axiosError?.isAxiosError && (axiosError?.response?.status === 401 || axiosError?.response?.status === 403)) {\r\n\t\tmessage = Localizer('ErrorMessageForbidden');\r\n\t}\r\n\r\n\tif (axiosError?.response?.data?.message) {\r\n\t\tmessage = axiosError.response.data.message;\r\n\t}\r\n\r\n\tif (isCollapsed) {\r\n\t\treturn null;\r\n\t}\r\n\r\n\treturn (\r\n\t\t\r\n\t\t\t{onCollapse ? (\r\n\t\t\t\t\r\n\t\t\t) : null}\r\n\r\n\t\t\t{title ? (\r\n\t\t\t\t\r\n\t\t\t\t\t{title}\r\n\t\t\t\t\r\n\t\t\t) : null}\r\n\r\n\t\t\t{message ? {message} : null}\r\n\r\n\t\t\t{children ? <> {children} : null}\r\n\t\t\r\n\t);\r\n}\r\n\r\n/**\r\n * Error Alert Default Props\r\n */\r\nInlineAlert.defaultProps = {\r\n\ttitle: Localizer('ErrorMessageGenericTitle'),\r\n\tmessage: Localizer('UnexpectedErrorOccurred'),\r\n\terror: null,\r\n};\r\n","import React from 'react';\r\nimport { SVGProps } from './SVGProps';\r\nimport classnames from 'classnames';\r\n\r\n/**\r\n * X SVG\r\n *\r\n * @returns\r\n */\r\nfunction XSVG({ className, ...rest }: SVGProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default XSVG;\r\n","import AxiosHelper from 'services/AxiosHelper';\r\nimport { AxiosResponse } from 'axios';\r\n\r\nexport interface UserSummary {\r\n\tisSignedIn: boolean;\r\n\tuserName: string | null;\r\n\tfirstName: string | null;\r\n\tlastName: string | null;\r\n\temail: string | null;\r\n\tphoneNumber: string | null;\r\n\ttwoFactorEnabled: boolean;\r\n\thasRecoveryCodes: boolean;\r\n\tisMachineRemembered: boolean;\r\n\tannouncements: UserAnnouncement[];\r\n\tisExternalLoginUser: boolean;\r\n\r\n\t// #region TapeCase\r\n\tisOptedInForMarketingEmails: boolean;\r\n\t// #endregion\r\n}\r\n\r\n/** Represents the details about an admin impersonation session of the logged in user. */\r\nexport interface Impersonation {\r\n\t/** The id of the admin impersonating the front end user. */\r\n\timpersonatorId: string;\r\n\r\n\t/** The name of the admin impersonating the front end user. */\r\n\timpersonatorName: string;\r\n\r\n\t/** The id of the active user impersonation session. */\r\n\tsessionId: string;\r\n}\r\n\r\nexport interface UserData {\r\n\t/**\r\n\t * Summary of user-specific details\r\n\t */\r\n\tsummary?: UserSummary;\r\n\r\n\t/**\r\n\t * CSRF validation token generated by the server\r\n\t */\r\n\trequestToken?: string;\r\n\r\n\t/**\r\n\t * The information on an impersonation session if one is active.\r\n\t * If an impersonation session isn't active this field will be undefined.\r\n\t */\r\n\timpersonation?: Impersonation;\r\n}\r\n\r\nexport interface UserAnnouncement {\r\n\t/** The id used as the primary key for the announcement in the database */\r\n\tid: string;\r\n\r\n\t/** An announcement to be displayed to the user */\r\n\tmessage: string;\r\n\r\n\t/** A list of pages where the announcement will be displayed. This will be an empty array if it is to be displayed on all pages. */\r\n\tpages: string[];\r\n}\r\n\r\nlet userDataPromise: Promise> | null = null;\r\n\r\n/**\r\n * Returns details related to the current user. By default, this is primarily their first/last name\r\n * and whether they are logged in or not. This can customized to include more details if necessary.\r\n */\r\nexport const getUserData = () => {\r\n\tif (userDataPromise === null) {\r\n\t\tuserDataPromise = AxiosHelper.get('/ajax/user');\r\n\t}\r\n\r\n\treturn userDataPromise;\r\n};\r\n\r\n/**\r\n * Returns non-cached details related to the current user. By default, this is primarily their first/last name\r\n * and whether they are logged in or not. This can customized to include more details if necessary.\r\n */\r\nexport const getUserDataNoCache = () => {\r\n\treturn AxiosHelper.get('/ajax/user');\r\n};\r\n\r\n/**\r\n * Returns a promise that will contain the CSRF token generated on the server to be used to validate\r\n * forms being posted via AJAX.\r\n */\r\nexport async function getCsrfToken() {\r\n\ttry {\r\n\t\tconst userData = await getUserData();\r\n\t\treturn userData.data.requestToken;\r\n\t} catch (error) {\r\n\t\tconsole.warn('Unable to load CSRF token.');\r\n\t\treturn '';\r\n\t}\r\n}\r\n\r\n// #region Commerce\r\nimport { CartSummary } from './UserData.Commerce';\r\nimport { LocationDto } from 'features/commerce/store-locator/types';\r\nimport { OrganizationInvite, OrganizationShipTo } from 'shared-client/types/commerce/organization';\r\nimport { AutoSuggestOption } from '../../../Roc.SharedClientApp/types/fields';\r\n\r\n// Commerce extensions to the UserData interface\r\nexport interface UserData {\r\n\tcartSummary?: CartSummary;\r\n\r\n\t/***\r\n\t * The customer's default store location or null if not set\r\n\t */\r\n\tdefaultStoreLocation?: LocationDto | null;\r\n\r\n\t/**\r\n\t * If store is enabled for this site\r\n\t */\r\n\tenableStoreLocation?: boolean;\r\n}\r\n\r\n/***\r\n * Organization data and permissions\r\n */\r\nexport interface Organization {\r\n\tid: string;\r\n\tpurchaseOrderNumberRequired: boolean;\r\n\tcreditCardAllowed: boolean;\r\n\tgiftCardAllowed: boolean;\r\n\torganizationName: string;\r\n\tcorpAccountAllowed: boolean;\r\n\t//#region TapeCase Customization\r\n\tisApprovedDistributor: boolean;\r\n\tpurchaseOrderAllowed: boolean;\r\n\t//#endregion\r\n}\r\n\r\n/***\r\n * Organization dto data\r\n */\r\nexport interface OrganizationDto extends AutoSuggestOption {}\r\n\r\n/***\r\n * User's organization and permissions data\r\n */\r\nexport interface UserSummary {\r\n\t/***\r\n\t * User's current default organization\r\n\t */\r\n\torganization: Organization | null;\r\n\r\n\t/***\r\n\t * The list of organizations the user is part of\r\n\t */\r\n\tuserOrganizations?: OrganizationDto[] | null;\r\n\r\n\t/***\r\n\t * The selected organization ship to\r\n\t */\r\n\tselectedShipTo: OrganizationShipTo | null;\r\n\r\n\t/***\r\n\t * Defines if the user has multiple shiptos to select from\r\n\t */\r\n\thasMultipleShipTos: boolean | null;\r\n\r\n\t/***\r\n\t * Defines if the user has saved payment methods\r\n\t */\r\n\thasSavedPaymentMethods: boolean | null;\r\n\r\n\t/***\r\n\t * The list of user permissions\r\n\t */\r\n\tpermissions?: UserPermissions;\r\n\r\n\t/***\r\n\t * The list of organizations the user is invited to join\r\n\t */\r\n\torganizationInvites?: OrganizationInvite[];\r\n\r\n\t/***\r\n\t * The user organization removal notification\r\n\t * Used to notify the user if he is no more part of his default organization\r\n\t */\r\n\tuserOrganizationRemovalNotification?: string;\r\n}\r\n\r\n/***\r\n * User's permissions\r\n */\r\nexport interface UserPermissions {\r\n\t/***\r\n\t * Defines if the current user can see organization users\r\n\t */\r\n\tcanSeeOrganizationUsers?: boolean;\r\n\r\n\t/***\r\n\t * Defines if the current user can assign roles to organization users\r\n\t */\r\n\tcanAssignRolesToOrganizationUsers?: boolean;\r\n\r\n\t/***\r\n\t * Defines if the current user can remove users from an organization\r\n\t */\r\n\tremoveUserFromOrganization?: boolean;\r\n\r\n\t/***\r\n\t * Defines if the current user can create organization users\r\n\t */\r\n\tcreateOrganizationUser?: boolean;\r\n\r\n\t/***\r\n\t * Defines if the current user can enable/disable ShipTos for organization users\r\n\t */\r\n\tmanageShipTosAssociation?: boolean;\r\n\r\n\t/***\r\n\t * Defines if the current user can see status of the organization users\r\n\t */\r\n\tcanSeePendingOrganizationUsers?: boolean;\r\n}\r\n// #endregion\r\n","import React from 'react';\r\nimport { FieldRenderProps } from 'react-final-form';\r\nimport { ValidationMessages } from '.';\r\nimport FieldInputErrorWrapper from './FieldInputErrorWrapper';\r\nimport { BaseInputProps } from './InputField';\r\nimport { toKebabCase } from 'util/StringUtil';\r\n\r\nexport type InputFieldProps = FieldRenderProps &\r\n\tBaseInputProps & {\r\n\t\tplaceholder?: string;\r\n\t};\r\n\r\n/**\r\n * Component that renders a checkbox input with form field.\r\n */\r\nexport default function CheckboxInputField({\r\n\tinput: { name, onChange, checked }, //#region TapeCase Customization (bugfix), added attribute `checked` instead of value\r\n\tmeta,\r\n\ttype,\r\n\tlabel = '',\r\n\tdisabled = false,\r\n\treadOnly = false,\r\n\tplaceholder = '',\r\n\tstep,\r\n\ttestId,\r\n\tdefaultValue = false,\r\n}: InputFieldProps) {\r\n\treturn (\r\n\t\t
\r\n\t\t\t
\r\n\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t\t\r\n\t\t
\r\n\t);\r\n}\r\n","import React from 'react';\r\nimport { Field, FieldProps, FieldRenderProps } from 'react-final-form';\r\nimport CheckboxInputField from './CheckboxInputField';\r\nimport { BaseInputProps } from './InputField';\r\n\r\nexport type InputFieldProps = FieldProps> & BaseInputProps;\r\n\r\n/**\r\n * Component that renders a checkbox field\r\n */\r\nexport default function CheckBoxField({\r\n\tname,\r\n\treadOnly = false,\r\n\tdisabled = false,\r\n\tlabel = '',\r\n\tafterSubmit,\r\n\tallowNull,\r\n\tbeforeSubmit,\r\n\tformatOnBlur,\r\n\tinitialValue,\r\n\tisEqual,\r\n\tsubscription,\r\n\tdefaultValue,\r\n\t//#region TapeCase Customization (bugfix)\r\n\tchecked,\r\n}: //endregion\r\nInputFieldProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t{({ input, meta }) => (\r\n\t\t\t\t\r\n\t\t\t)}\r\n\t\t\r\n\t);\r\n}\r\n","import React from 'react';\r\nimport { Field, FieldProps, FieldRenderProps } from 'react-final-form';\r\nimport { DropdownOption } from 'shared-client/types/fields';\r\nimport { toKebabCase } from 'util/StringUtil';\r\nimport { FormFieldProps, ValidationMessages } from '.';\r\nimport FieldInputErrorWrapper from './FieldInputErrorWrapper';\r\nimport FieldLabel from './FieldLabel';\r\nexport type DropdownProps = FormFieldProps & {\r\n\taddSelectOption?: boolean;\r\n\toptions: DropdownOption[];\r\n};\r\n\r\nexport type DropdownFieldProps = DropdownProps &\r\n\tFieldProps>;\r\n\r\n/**\r\n * Component that renders a Dropdown field component\r\n */\r\nexport default function DropdownField({\r\n\tname,\r\n\tisRequired = true,\r\n\treadOnly = false,\r\n\tdisabled = false,\r\n\taddSelectOption = true,\r\n\toptions,\r\n\tlabel = '',\r\n\tafterSubmit,\r\n\tallowNull,\r\n\tbeforeSubmit,\r\n\tformatOnBlur,\r\n\tisEqual,\r\n\tsubscription,\r\n\tvalidateFields,\r\n\ttestId,\r\n}: DropdownFieldProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t{({ input: { value, onChange, onFocus, onBlur }, meta }) => (\r\n\t\t\t\t
\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t{addSelectOption ? \r\n\t\t\t\t\t\t\t))}\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t
\r\n\t\t\t)}\r\n\t\t\r\n\t);\r\n}\r\n","import React from 'react';\r\nimport { FieldRenderProps } from 'react-final-form';\r\n\r\ntype ValidationMessagesProps = Pick, 'meta'> & {\r\n\tid: string;\r\n};\r\n\r\nfunction getErrorArray(errorOrSubmitError) {\r\n\tlet errors: string[] = [];\r\n\tif (typeof errorOrSubmitError === 'string') {\r\n\t\terrors.push(errorOrSubmitError);\r\n\t} else if (Array.isArray(errorOrSubmitError)) {\r\n\t\terrors = errorOrSubmitError.filter((error) => !Array.isArray(error) && typeof error === 'string');\r\n\t}\r\n\r\n\treturn errors;\r\n}\r\n\r\n/**\r\n * Displays validation errors for fields\r\n *\r\n * @class ValidationMessages\r\n * @extends {React.Component}\r\n */\r\nfunction ValidationMessages(props: ValidationMessagesProps) {\r\n\tconst { meta } = props;\r\n\r\n\tif (!meta) {\r\n\t\treturn null;\r\n\t}\r\n\r\n\tlet errors: string[] = [];\r\n\r\n\t/* \r\n\t almost all validation comes from the server, so we only need to check `submitError` despite there being `error`\r\n\t there are 3 kinds of values for submitError, string, string[] and [string|[]|object]\r\n\t the third type happens when you're using FieldArray, so we're going to filter those out and only\r\n\t take the strings if submitError is an array. this is due to a bug (possibly feature?) of final form\r\n\t where the submit errors for field array fields bubble up into the parent field.\r\n\t */\r\n\tif (meta.submitError) {\r\n\t\terrors = errors.concat(getErrorArray(meta.submitError));\r\n\r\n\t\t// for server-side validation, we need to stop showing these after any changes are made.\r\n\t\tif (meta.dirtySinceLastSubmit || meta.submitting) {\r\n\t\t\treturn null;\r\n\t\t}\r\n\t} else if (meta.error) {\r\n\t\t// sometimes we validate on the client, so we need to support these as well.\r\n\t\terrors = errors.concat(getErrorArray(meta.error));\r\n\t}\r\n\r\n\treturn (\r\n\t\t// #region Tapecase\r\n\t\t\r\n\t\t\t{/* #endregion */}\r\n\t\t\t{(meta.submitError || meta.error) &&\r\n\t\t\t\tmeta.touched &&\r\n\t\t\t\terrors.length > 0 &&\r\n\t\t\t\terrors.map((error, index) => (\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t{error}\r\n\t\t\t\t\t\t
\r\n\t\t\t\t\t
\r\n\t\t\t\t))}\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default ValidationMessages;\r\n","import React from 'react';\r\nimport StarRating from '~/shared/components/star-rating/StarRating';\r\nimport { Field } from 'react-final-form';\r\nimport OptionalFieldMarker from '../OptionalFieldMarker';\r\nimport ValidationMessages from './ValidationMessages';\r\nimport { FormFieldProps } from '.';\r\nimport FieldInputErrorWrapper from './FieldInputErrorWrapper';\r\nimport { LocalizedSpan } from 'services/Localizer';\r\nimport { toKebabCase } from 'util/StringUtil';\r\n\r\nexport interface StarRatingFieldProps extends FormFieldProps {\r\n\t/**\r\n\t * The maximum number of stars to display (default is 5)\r\n\t */\r\n\tmaxRating?: number;\r\n}\r\n\r\n/**\r\n * Reusable RFF-compatible field that displays a star rating input\r\n * @param props\r\n */\r\nexport default function StarRatingField({\r\n\tname,\r\n\tlabel = '',\r\n\treadOnly = false,\r\n\tdisabled = false,\r\n\tmaxRating = 5,\r\n\tisRequired = true,\r\n\ttestId,\r\n}: StarRatingFieldProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t{({ input: { value, onChange }, meta }) => (\r\n\t\t\t\t\r\n\t\t\t\t\t
\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t{label} {!isRequired ? : null}\r\n\t\t\t\t\t\t\r\n\r\n\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t
\r\n\r\n\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t${value}\r\n\t\t\t\t\t\t\t`,\r\n\t\t\t\t\t\t\t\t\t`${maxRating}\r\n\t\t\t\t\t\t\t`,\r\n\t\t\t\t\t\t\t\t]}\r\n\t\t\t\t\t\t\t/>\r\n\t\t\t\t\t\t
\r\n\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t
\r\n\t\t\t\t
\r\n\t\t\t)}\r\n\t\t
\r\n\t);\r\n}\r\n","import * as React from 'react';\r\nimport { ValidationMessages, FormFieldProps } from '.';\r\nimport { FieldProps, Field, FieldRenderProps } from 'react-final-form';\r\nimport FieldLabel from './FieldLabel';\r\nimport FieldInputErrorWrapper from './FieldInputErrorWrapper';\r\nimport { toKebabCase } from 'util/StringUtil';\r\n\r\nexport type TextAreaFieldProps = FieldProps> &\r\n\tFormFieldProps & {\r\n\t\trows?: number;\r\n\t\tplaceholder?: string;\r\n\t};\r\n\r\n/**\r\n * Component that renders a textarea input component.\r\n */\r\nexport default function TextAreaField({\r\n\tname,\r\n\tisRequired = true,\r\n\treadOnly = false,\r\n\tdisabled = false,\r\n\tplaceholder = '',\r\n\tlabel = '',\r\n\trows = 5,\r\n\tvalidate,\r\n\tafterSubmit,\r\n\tallowNull,\r\n\tbeforeSubmit,\r\n\tcomponent,\r\n\tdefaultValue,\r\n\tformat,\r\n\tformatOnBlur,\r\n\tinitialValue,\r\n\tisEqual,\r\n\tparse,\r\n\trender,\r\n\tsubscription,\r\n\tvalue,\r\n\ttestId,\r\n}: TextAreaFieldProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t{({ input, meta }) => (\r\n\t\t\t\t
\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t
\r\n\t\t\t)}\r\n\t\t\r\n\t);\r\n}\r\n","import React from 'react';\r\nimport { FieldRenderProps } from 'react-final-form';\r\nimport { toKebabCase } from 'util/StringUtil';\r\nimport { FormFieldProps, ValidationMessages } from '.';\r\nimport FieldInputErrorWrapper from './FieldInputErrorWrapper';\r\nimport FieldLabel from './FieldLabel';\r\n\r\nexport interface BaseInputProps extends FormFieldProps {\r\n\ttype?: string;\r\n\tstep?: string;\r\n}\r\n\r\nexport type InputFieldProps = FieldRenderProps &\r\n\tBaseInputProps & {\r\n\t\tplaceholder?: string;\r\n\t};\r\n\r\nexport type HTMLInputRef = React.MutableRefObject;\r\n/**\r\n * Component that renders an input with form field.\r\n */\r\nconst InputField = React.forwardRef((props: InputFieldProps, ref: HTMLInputRef) => {\r\n\tconst {\r\n\t\tinput: { name, onChange, value },\r\n\t\tmeta,\r\n\t\ttype,\r\n\t\tlabel = '',\r\n\t\tisRequired = true,\r\n\t\tdisabled = false,\r\n\t\treadOnly = false,\r\n\t\tplaceholder = '',\r\n\t\tstep,\r\n\t\ttestId,\r\n\t} = props;\r\n\r\n\treturn (\r\n\t\t
\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t\t\r\n\t\t\t\r\n\t\t\t\r\n\t\t
\r\n\t);\r\n});\r\n\r\nexport default InputField;\r\n","import React from 'react';\r\nimport { Field, FieldProps, FieldRenderProps } from 'react-final-form';\r\nimport InputField, { BaseInputProps, HTMLInputRef } from './InputField';\r\n\r\nexport type InputFieldProps = FieldProps> & BaseInputProps;\r\n\r\n/**\r\n * Component that renders a text box component, of the specified type\r\n */\r\nconst TextBoxField = React.forwardRef((props: InputFieldProps, ref: HTMLInputRef) => {\r\n\tconst {\r\n\t\tname,\r\n\t\ttype = 'text',\r\n\t\tisRequired = true,\r\n\t\treadOnly = false,\r\n\t\tdisabled = false,\r\n\t\tplaceholder = '',\r\n\t\tlabel = '',\r\n\t\tvalidate,\r\n\t\tafterSubmit,\r\n\t\tallowNull,\r\n\t\tbeforeSubmit,\r\n\t\tcomponent,\r\n\t\tdefaultValue,\r\n\t\tformat,\r\n\t\tformatOnBlur,\r\n\t\tinitialValue,\r\n\t\tisEqual,\r\n\t\tparse,\r\n\t\trender,\r\n\t\tsubscription,\r\n\t\tvalue,\r\n\t\ttestId,\r\n\t} = props;\r\n\r\n\treturn (\r\n\t\t\r\n\t\t\t{({ input, meta }) => (\r\n\t\t\t\t\r\n\t\t\t)}\r\n\t\t\r\n\t);\r\n});\r\n\r\nexport default TextBoxField;\r\n","export enum ModelStatus {\r\n\tPublished = 'Published',\r\n\tInactive = 'Inactive',\r\n\tDeleted = 'Deleted',\r\n\tDraft = 'Draft',\r\n\tArchived = 'Archived',\r\n}\r\n","import { ServerData } from 'services/ServerData';\r\n\r\nexport default {\r\n\tBaseUrl: ServerData.ACCOUNT_URL_BASE ?? '/my-account',\r\n\tLogin: ServerData.ACCOUNT_LOGIN_URL ?? '/my-account/login',\r\n\tLogin2fa: ServerData.ACCOUNT_LOGIN_WITH_2FA_URL ?? '/my-account/login-with-2fa',\r\n\tRegister: ServerData.ACCOUNT_REGISTER_URL ?? '/my-account/register',\r\n\tForgotPassword: ServerData.ACCOUNT_FORGOT_PASSWORD_URL ?? '/my-account/forgot-password',\r\n\tLoginWithRecoveryCode: ServerData.ACCOUNT_LOGIN_WITH_RECOVERY_CODE_URL ?? '/my-account/login-with-recovery-code',\r\n\tLogout: ServerData.ACCOUNT_LOGOUT_URL ?? '/my-account/logout',\r\n\t// #region Commerce\r\n\tOrganizationReview: ServerData.ACCOUNT_ORGANIZATION_REVIEW_URL ?? '/my-account/organization-review',\r\n\tOrganizationSelector: ServerData.ACCOUNT_ORGANIZATION_SELECTOR_URL ?? '/my-account/organization-selector',\r\n\t// #endregion\r\n};\r\n","import { useEffect } from 'react';\r\nimport 'shared/polyfills/customEvent';\r\nimport { RocEventType, ExtractEventParameters, RocEvent } from 'shared/events';\r\nimport addRocEventHandler from 'shared/util/events/rocEventUtils';\r\n\r\n/**\r\n * Helper function for dispatching ROC events.\r\n *\r\n * @param eventType The event type for the dispatcher\r\n */\r\nexport function dispatchRocEvent(eventType: T, data: ExtractEventParameters) {\r\n\tconst event = new CustomEvent(eventType, {\r\n\t\tdetail: data,\r\n\t});\r\n\tdocument.dispatchEvent(event);\r\n}\r\n\r\n/**\r\n * Reusable hook for handling ROC events\r\n *\r\n * @param eventType The type of event to handle\r\n * @param eventHandler The event handler\r\n * @param deps List of dependencies\r\n */\r\nexport default function useRocEventHandler(\r\n\teventType: T,\r\n\teventHandler: (data: ExtractEventParameters) => void,\r\n\tdeps?: any[],\r\n) {\r\n\tuseEffect(() => {\r\n\t\tconst removeHandlerCallback = addRocEventHandler(eventType, eventHandler);\r\n\r\n\t\treturn () => {\r\n\t\t\tremoveHandlerCallback();\r\n\t\t};\r\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\r\n\t}, deps);\r\n}\r\n","import React from 'react';\r\nimport { Localizer } from 'services/Localizer';\r\n\r\ninterface ResultsWithinDistanceProps {\r\n\tresultsCount: number;\r\n\tdistance: number;\r\n}\r\n\r\n/**\r\n * Simple component to display results within a distance.\r\n * Takes results count and distance props and returns localized message.\r\n *\r\n * @export\r\n * @param {ResultsWithinDistanceProps} props\r\n * @returns\r\n */\r\nexport default function ResultsWithinDistance(props: ResultsWithinDistanceProps) {\r\n\tconst { resultsCount, distance } = props;\r\n\r\n\treturn (\r\n\t\t<>\r\n\t\t\t{resultsCount} {Localizer('ResultsWithinDistance', distance.toString())}\r\n\t\t\r\n\t);\r\n}\r\n","import React from 'react';\r\nimport InlineAlert from 'shared/edit/InlineAlert';\r\n\r\n// eslint-disable-next-line\r\n// tslint:disable-next-line\r\nexport interface ErrorBoundaryRenderProps extends ErrorBoundaryState {}\r\n\r\nexport interface ErrorBoundaryProps {\r\n\tchildren: React.ReactNode;\r\n\trenderError?: (renderProps: ErrorBoundaryRenderProps) => React.ReactNode;\r\n}\r\n\r\nexport interface ErrorBoundaryState {\r\n\terror?: Error;\r\n}\r\n\r\n/**\r\n * Default Error Boundary component for frontend components, so that in case a JS error occurs, we show\r\n * something instead of nothing.\r\n */\r\nexport default class ErrorBoundary extends React.Component {\r\n\tpublic static defaultProps = {\r\n\t\trenderError: (renderProps: ErrorBoundaryRenderProps) => ,\r\n\t};\r\n\r\n\tpublic state: ErrorBoundaryState = {};\r\n\r\n\tpublic componentDidCatch(error: Error) {\r\n\t\tthis.setState({\r\n\t\t\terror,\r\n\t\t});\r\n\t}\r\n\r\n\tpublic render() {\r\n\t\tif (this.state.error) {\r\n\t\t\treturn this.props.renderError!(this.state);\r\n\t\t}\r\n\r\n\t\treturn this.props.children;\r\n\t}\r\n}\r\n","// source: https://developer.mozilla.org/en-US/docs/Web/API/Element/getAttributeNames\r\n/* eslint-disable no-var */\r\n(function () {\r\n\tif (Element.prototype.getAttributeNames == undefined) {\r\n\t\tElement.prototype.getAttributeNames = function () {\r\n\t\t\tvar attributes = this.attributes;\r\n\t\t\tvar length = attributes.length;\r\n\t\t\tvar result = new Array(length);\r\n\t\t\tfor (var i = 0; i < length; i++) {\r\n\t\t\t\tresult[i] = attributes[i].name;\r\n\t\t\t}\r\n\t\t\treturn result;\r\n\t\t};\r\n\t}\r\n})();\r\n","import React from 'react';\r\nimport ReactDOM from 'react-dom';\r\nimport ErrorBoundary from './ErrorBoundary';\r\nimport { toCamelCase } from 'util/StringUtil';\r\nimport 'shared/polyfills/getAttributeNames';\r\nimport Spinner from 'shared/components/Spinner';\r\n\r\ninterface AttributeProps {\r\n\t[index: string]: string;\r\n}\r\n\r\nfunction getDataPropsFromAttributes(element: Element): AttributeProps {\r\n\tconst props: AttributeProps = {};\r\n\r\n\tconst dataAttributePrefix = 'data-';\r\n\r\n\tconst attributeNames = element.getAttributeNames().filter((s) => s.startsWith(dataAttributePrefix));\r\n\tfor (const attributeName of attributeNames) {\r\n\t\tconst strippedName = toCamelCase(attributeName.substring(dataAttributePrefix.length));\r\n\t\tprops[strippedName] = element.getAttribute(attributeName) ?? '';\r\n\t}\r\n\r\n\treturn props;\r\n}\r\n\r\n/**\r\n * A helper function to facilitate initializing react applications on top of server-side rendered elements.\r\n * @param getReactElement Function that returns the react component to render.\r\n * @param elementId The ID of the DOM element being targeted.\r\n */\r\nexport const initReactApp = (getReactElement: (props: unknown) => React.ReactElement, elementId: string) => {\r\n\tif (typeof getReactElement !== 'function' || !elementId) {\r\n\t\treturn () => {\r\n\t\t\tconsole.warn('A react element generator function and element ID are required.');\r\n\t\t};\r\n\t}\r\n\r\n\tconst element = document.getElementById(elementId);\r\n\r\n\tif (!element) {\r\n\t\treturn () => {\r\n\t\t\tconsole.warn(\r\n\t\t\t\t`Element with ID '${elementId}' was not found. Did you forget to render it on the server or is this entry point not supposed to run?`,\r\n\t\t\t);\r\n\t\t};\r\n\t}\r\n\r\n\treturn () => {\r\n\t\tconst props = getDataPropsFromAttributes(element);\r\n\t\tconsole.debug(`Rendering application inside element with ID ${elementId}.`);\r\n\t\tReactDOM.render(\r\n\t\t\t}>\r\n\t\t\t\t{getReactElement(props)}\r\n\t\t\t,\r\n\t\t\telement,\r\n\t\t);\r\n\t};\r\n};\r\n\r\nexport const initReactAppByAttribute = (\r\n\tgetReactElement: (props: unknown, domElement: Element) => React.ReactElement,\r\n\tattribute: string,\r\n) => {\r\n\tif (typeof getReactElement !== 'function' || !attribute) {\r\n\t\treturn () => {\r\n\t\t\tconsole.warn('A react element generator function and element ID are required.');\r\n\t\t};\r\n\t}\r\n\r\n\tconst elements = document.querySelectorAll(`[${attribute}]`);\r\n\r\n\tif (!elements || elements.length == 0) {\r\n\t\treturn () => {\r\n\t\t\tconsole.warn(\r\n\t\t\t\t`No elements with data attribute '${attribute}' were found. Did you forget to render it on the server or is this entry point not supposed to run?`,\r\n\t\t\t);\r\n\t\t};\r\n\t}\r\n\r\n\treturn () => {\r\n\t\tfor (let i = 0; i < elements.length; ++i) {\r\n\t\t\tconst element = elements[i];\r\n\t\t\tconst props = getDataPropsFromAttributes(element);\r\n\t\t\tconsole.debug(`Rendering application inside element with attribute ${attribute}.`);\r\n\t\t\tReactDOM.render(\r\n\t\t\t\t}>\r\n\t\t\t\t\t{getReactElement(props, element)}\r\n\t\t\t\t,\r\n\t\t\t\telement,\r\n\t\t\t);\r\n\t\t}\r\n\t};\r\n};\r\n","import React from 'react';\r\nimport { Localizer } from 'services/Localizer';\r\n\r\n/**\r\n * Reusable component for the optional field marker\r\n */\r\nfunction OptionalFieldMarker() {\r\n\treturn ({Localizer('Optional')});\r\n}\r\n\r\nexport default React.memo(OptionalFieldMarker);\r\n","import { useState, useEffect } from 'react';\r\n\r\n/**\r\n * Reusable hook that returns true after a certain amount of time has passed. Useful to delay\r\n * displaying components in render functions.\r\n *\r\n * @export\r\n * @param {number} [waitMs=200]\r\n * @returns\r\n */\r\nexport default function useDelayedDisplay(waitMs: number = 200) {\r\n\tconst [display, setDisplay] = useState(false);\r\n\r\n\tuseEffect(() => {\r\n\t\t// after a set amount of time, show the spinner\r\n\t\tconst timeout = setTimeout(() => {\r\n\t\t\tsetDisplay(true);\r\n\t\t}, waitMs);\r\n\r\n\t\treturn () => {\r\n\t\t\tclearTimeout(timeout);\r\n\t\t};\r\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\r\n\t}, []);\r\n\r\n\treturn display;\r\n}\r\n","import React from 'react';\r\nimport { SVGProps } from './SVGProps';\r\nimport classnames from 'classnames';\r\n\r\n/**\r\n * Check circle SVG\r\n *\r\n * @returns\r\n */\r\nfunction CheckCircleSVG({ className, ...rest }: SVGProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default CheckCircleSVG;\r\n","import { RocEventType, RocEvent, ExtractEventParameters } from 'shared/events';\r\n\r\n/**\r\n * Helper function for handling ROC events from non React functions.\r\n * @param eventType The type of event to handle\r\n * @param eventHandler The event handler\r\n * @returns The callback function to remove this handler\r\n */\r\nexport default function addRocEventHandler(\r\n\teventType: T,\r\n\teventHandler: (data: ExtractEventParameters) => void,\r\n): () => void {\r\n\tconst handler = (evt: CustomEvent): void => {\r\n\t\teventHandler(evt.detail);\r\n\t};\r\n\r\n\tdocument.addEventListener(eventType, handler);\r\n\r\n\treturn () => document.removeEventListener(eventType, handler);\r\n}\r\n","import * as React from 'react';\r\n\r\ninterface DashCircleSVGProps {\r\n\tclass?: string;\r\n}\r\n\r\n/**\r\n * Dash circle SVG\r\n *\r\n * @returns\r\n */\r\nfunction DashCircleSVG(props: DashCircleSVGProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default DashCircleSVG;\r\n","import React from 'react';\r\nimport { SVGProps } from './SVGProps';\r\nimport classnames from 'classnames';\r\n\r\n/**\r\n * Circle Exclaimation SVG component\r\n *\r\n * @returns\r\n */\r\nfunction CircleExclamationSVG({ className, ...rest }: SVGProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default CircleExclamationSVG;\r\n","import React from 'react';\r\nimport XSVG from './svg/XSVG';\r\nimport { Localizer } from 'services/Localizer';\r\nimport { WithTestIdOptional } from '../../../../Roc.SharedClientApp/types/test';\r\n\r\ninterface CircleButtonProps extends WithTestIdOptional {\r\n\ticon?: React.ReactNode;\r\n}\r\n\r\nfunction CircleButton(props: React.HTMLProps & CircleButtonProps) {\r\n\tconst { icon, testId, ...otherProps } = props;\r\n\r\n\treturn (\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default CircleButton;\r\n","import React from 'react';\r\nimport { SVGProps } from './SVGProps';\r\nimport classnames from 'classnames';\r\n\r\n/**\r\n * Star Empty SVG\r\n *\r\n * @returns\r\n */\r\nfunction StarEmptySVG({ className, ...rest }: SVGProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default StarEmptySVG;\r\n","import React from 'react';\r\nimport { SVGProps } from './SVGProps';\r\nimport classnames from 'classnames';\r\n\r\n/**\r\n * Star SVG\r\n *\r\n * @returns\r\n */\r\nfunction StarSVG({ className, ...rest }: SVGProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default StarSVG;\r\n","/* eslint-disable jsx-a11y/label-has-for */\r\n/* eslint-disable jsx-a11y/no-noninteractive-element-interactions */\r\nimport classnames from 'classnames';\r\nimport React from 'react';\r\nimport { WithTestId } from 'shared-client/types/test';\r\nimport StarEmptySVG from 'shared/components/svg/StarEmptySVG';\r\nimport StarSVG from 'shared/components/svg/StarSVG';\r\nimport useStarRating from './useStarRating';\r\n\r\n/**\r\n * Product Rating Props\r\n */\r\ninterface RatingProps extends WithTestId {\r\n\tvalue: number | null;\r\n\tname: string;\r\n\treadonly?: boolean;\r\n\tonChange?: (rating: number) => void;\r\n\tmaxRating?: number;\r\n}\r\n\r\n/**\r\n * If readonly, displays the rating with blank and filled stars (1-maxRating)\r\n * If not readonly, displays the rating picker with blank and filled stars (1-maxRating)\r\n * @param props\r\n */\r\nexport default function StarRating(props: RatingProps) {\r\n\tconst { value, name, readonly = false, onChange, maxRating = 5, testId } = props;\r\n\r\n\tconst { ratingStars, setRatingHovered } = useStarRating({\r\n\t\tvalue,\r\n\t\tname,\r\n\t\tmaxRating,\r\n\t});\r\n\r\n\tif (!readonly && !onChange) {\r\n\t\tthrow new Error('Rating component is set to non-readonly, yet onChange is not defined.');\r\n\t}\r\n\r\n\t/**\r\n\t * Handle changes to the radio button that backs the star rating selection\r\n\t *\r\n\t * @param {*} e\r\n\t */\r\n\tconst onInputChange = (e) => {\r\n\t\tif (onChange) {\r\n\t\t\tonChange(parseInt(e.currentTarget.value));\r\n\t\t}\r\n\t};\r\n\r\n\tif (readonly) {\r\n\t\treturn (\r\n\t\t\t<>\r\n\t\t\t\t{ratingStars.map(({ id, isFull }) => (\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t{isFull ? (\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t) : (\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t)}\r\n\t\t\t\t\t\r\n\t\t\t\t))}\r\n\t\t\t\r\n\t\t);\r\n\t}\r\n\r\n\treturn (\r\n\t\t<>\r\n\t\t\t{ratingStars.map(({ id, isFull, isChecked, isPending, isHighlighted, ratingValue }) => {\r\n\t\t\t\tconst modifierClasses = classnames({\r\n\t\t\t\t\t'roc-rating__input--full': isFull,\r\n\t\t\t\t\t'roc-rating__input--pending': isPending,\r\n\t\t\t\t\t'roc-rating__label--highlighted': isHighlighted,\r\n\t\t\t\t});\r\n\r\n\t\t\t\treturn (\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t setRatingHovered(ratingValue)}\r\n\t\t\t\t\t\t\tonMouseLeave={() => setRatingHovered(null)}\r\n\t\t\t\t\t\t>\r\n\t\t\t\t\t\t\t{isFull ? (\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t) : (\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t)}\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t);\r\n\t\t\t})}\r\n\t\t\r\n\t);\r\n}\r\n","import { useEffect, useState } from 'react';\r\n\r\n/**\r\n * The state of all of the stars being displayed, these change together frequently\r\n * so lets store them together. This is also slightly better than calculating\r\n * on every single render. Makes it easier to reuse as well.\r\n */\r\ninterface RatingStarState {\r\n\tid: string;\r\n\tisFull: boolean;\r\n\tisPending: boolean;\r\n\tisHighlighted: boolean;\r\n\tisChecked: boolean;\r\n\tratingValue: number;\r\n}\r\n\r\n/**\r\n * The params for the useStarRating hook.\r\n */\r\ninterface UseStarRatingParams {\r\n\tvalue: number | null;\r\n\tname: string;\r\n\tmaxRating?: number;\r\n}\r\n\r\n/**\r\n * The values returned by the custom star rating hook\r\n */\r\ninterface UseStarRatingResult {\r\n\tratingStars: RatingStarState[];\r\n\tsetRatingHovered: (value: number | null) => void;\r\n}\r\n\r\n/**\r\n * Custom hook that manages state for simple star rating implementations\r\n * @param params\r\n */\r\nexport default function useStarRating(params: UseStarRatingParams): UseStarRatingResult {\r\n\tconst { value, name, maxRating = 5 } = params;\r\n\tconst [ratingStars, setRatingStars] = useState([]);\r\n\tconst [ratingHovered, setRatingHovered] = useState(null);\r\n\r\n\tuseEffect(() => {\r\n\t\tconst newState: RatingStarState[] = [];\r\n\r\n\t\tfor (let i = 1; i <= maxRating; i++) {\r\n\t\t\tconst id = 'rating-group-' + name + '-' + i;\r\n\t\t\tconst isFull = value !== null && value >= i;\r\n\t\t\tconst isPending = ratingHovered ? i > ratingHovered && isFull : false;\r\n\t\t\tconst isHighlighted = ratingHovered ? i <= ratingHovered : false;\r\n\t\t\tconst isChecked = value === i;\r\n\r\n\t\t\tnewState.push({\r\n\t\t\t\tid,\r\n\t\t\t\tisFull,\r\n\t\t\t\tisPending,\r\n\t\t\t\tisHighlighted,\r\n\t\t\t\tisChecked,\r\n\t\t\t\tratingValue: i,\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tsetRatingStars(newState);\r\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\r\n\t}, [value, ratingHovered]);\r\n\r\n\treturn { ratingStars, setRatingHovered };\r\n}\r\n","/**\r\n * Returns visitor expiry date for hawksearch visitor id stored in the cookie for the user.\r\n */\r\nexport function getVisitorExpiry() {\r\n\tconst d = new Date();\r\n\t// 1 year\r\n\td.setTime(d.getTime() + 360 * 24 * 60 * 60 * 1000);\r\n\treturn d.toUTCString();\r\n}\r\n\r\n/**\r\n * Returns visitor expiry date for hawksearch visit id stored in the cookie for the user.\r\n */\r\nexport function getVisitExpiry() {\r\n\tconst d = new Date();\r\n\t// 4 hours\r\n\td.setTime(d.getTime() + 4 * 60 * 60 * 1000);\r\n\treturn d.toUTCString();\r\n}\r\n\r\n/**\r\n * Creates GUID.\r\n */\r\nexport function createGuid() {\r\n\tconst s: string[] = [];\r\n\tconst hexDigits = '0123456789abcdef';\r\n\tfor (let i = 0; i < 36; i++) {\r\n\t\ts[i] = hexDigits.substr(Math.floor(Math.random() * 0x10), 1);\r\n\t}\r\n\ts[14] = '4'; // bits 12-15 of the time_hi_and_version field to 0010\r\n\ts[19] = hexDigits.substr(((s[19] as any) & 0x3) | 0x8, 1); // bits 6-7 of the clock_seq_hi_and_reserved to 01\r\n\ts[8] = s[13] = s[18] = s[23] = '-';\r\n\r\n\treturn s.join('');\r\n}\r\n\r\n/**\r\n * Returns the cookie.\r\n */\r\nexport function getCookie(name) {\r\n\tconst nameEQ = name + '=';\r\n\tconst ca = document.cookie.split(';');\r\n\r\n\tfor (let i = 0; i < ca.length; i++) {\r\n\t\tlet cookie = ca[i];\r\n\r\n\t\twhile (cookie.charAt(0) == ' ') {\r\n\t\t\tcookie = cookie.substring(1, cookie.length);\r\n\t\t}\r\n\r\n\t\tif (cookie.indexOf(nameEQ) == 0) {\r\n\t\t\treturn cookie.substring(nameEQ.length, cookie.length);\r\n\t\t}\r\n\t}\r\n\treturn null;\r\n}\r\n\r\n/**\r\n * Sets the cookie.\r\n */\r\nexport function setCookie(name: string, value: string, expiry?: string) {\r\n\tlet expires = '';\r\n\r\n\tif (expiry) {\r\n\t\texpires = '; expires=' + expiry;\r\n\t}\r\n\r\n\tdocument.cookie = name + '=' + value + expires + '; path=/';\r\n}\r\n","import React from 'react';\r\nimport { SVGProps } from './SVGProps';\r\nimport classnames from 'classnames';\r\n\r\n/**\r\n * Pencil SVG\r\n *\r\n * @returns\r\n */\r\nfunction PencilSVG({ className, ...rest }: SVGProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default PencilSVG;\r\n","import { ExternalLoginProvider } from 'features/login/ExternalLogins';\r\n\r\n/**\r\n * Extends Window with a property that will hold the client data\r\n *\r\n * @interface WindowWithClientData\r\n * @extends {Window}\r\n */\r\ninterface WindowWithServerData extends Window {\r\n\t__ROC_SERVER_DATA__?: Array<{\r\n\t\t[name: string]: string;\r\n\t}>;\r\n}\r\n\r\n/**\r\n * This type will hold all the keys that are used by ServerData\r\n */\r\ninterface ServerData {\r\n\tIsReCaptchaEnabled?: boolean;\r\n\tReCaptchaV3Key?: string;\r\n\tTimeZone?: string;\r\n\tUSE_EMAIL_AS_USERNAME?: boolean;\r\n\tRegistrationThankYouTitle?: string;\r\n\tRegistrationThankYouMessage?: string;\r\n\tForgotPasswordConfirmationTitle?: string;\r\n\tForgotPasswordConfirmationMessage?: string;\r\n\tPageTitleSuffix?: string;\r\n\tRequireConfirmEmail?: boolean;\r\n\tACCOUNT_URL_BASE?: string;\r\n\tACCOUNT_LOGIN_URL?: string;\r\n\tACCOUNT_LOGOUT_URL?: string;\r\n\tACCOUNT_REGISTER_URL?: string;\r\n\tACCOUNT_LOGIN_WITH_2FA_URL?: string;\r\n\tACCOUNT_FORGOT_PASSWORD_URL?: string;\r\n\tACCOUNT_LOGIN_WITH_RECOVERY_CODE_URL?: string;\r\n\tEXTERNAL_LOGIN_PROVIDERS?: ExternalLoginProvider[];\r\n\t// #region Commerce\r\n\tACCOUNT_ORGANIZATION_REVIEW_URL?: string;\r\n\tACCOUNT_ORGANIZATION_SELECTOR_URL?: string;\r\n\tGoogleMapsApiKey?: string; // used in Store Locator\r\n\tMinimumTimeBeforeRecentlyViewedProductsAreValidated?: number;\r\n\tQuickOrderItemMinumumSearchCharacters?: number;\r\n\tMaxAllowedQuickOrderItems?: number;\r\n\tMaxNumberForQuantityDropdown?: number;\r\n\tOrderDetailsUIComponent?: string;\r\n\tGuestCheckoutEnabled?: boolean;\r\n\t// #endregion\r\n\t// #region TapeCase Customizations\r\n\tListPriceMessagingForNotApprovedDistributors?: string;\r\n\tMaxNumberOfDaysToCancelOrders?: number;\r\n\tMaxNumberOfDaysToCancelOrdersMessage?: string;\r\n\t// #endregion\r\n}\r\n\r\n/**\r\n * Main object that will hold all the client data\r\n */\r\nexport const ServerData: ServerData = {};\r\n\r\n/**\r\n * Initializer function that will populate the main settings object\r\n */\r\nfunction initializeServerData() {\r\n\tconst windowWithServerData = window as WindowWithServerData;\r\n\r\n\tif (\r\n\t\twindowWithServerData &&\r\n\t\twindowWithServerData.__ROC_SERVER_DATA__ &&\r\n\t\tArray.isArray(windowWithServerData.__ROC_SERVER_DATA__)\r\n\t) {\r\n\t\tfor (const obj of windowWithServerData.__ROC_SERVER_DATA__) {\r\n\t\t\tfor (const key of Object.keys(obj)) {\r\n\t\t\t\tServerData[key] = obj[key];\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n}\r\n\r\ninitializeServerData();\r\n","import { useState } from 'react';\r\n\r\n/**\r\n * Custom hook for commonly used loading states.\r\n */\r\nexport function useLoader() {\r\n\tconst [loading, setLoading] = useState(false);\r\n\tconst [error, setError] = useState(undefined);\r\n\tconst [response, setResponse] = useState(null);\r\n\r\n\treturn {\r\n\t\tloading,\r\n\t\tsetLoading,\r\n\t\terror,\r\n\t\tsetError,\r\n\t\tresponse,\r\n\t\tsetResponse,\r\n\t};\r\n}\r\n","/* eslint-disable jsx-a11y/label-has-for */\r\nimport React, { useEffect, useRef, useState } from 'react';\r\nimport type { Coords } from 'google-map-react';\r\nimport Spinner from 'shared/components/Spinner';\r\nimport GoogleMapsMarker from './GoogleMapsMarker';\r\nimport { LocationDto, Geolocation } from './types';\r\nimport { ServerData } from 'services/ServerData';\r\nimport StoreLocationFormattedAddress from './StoreLocationFormattedAddress';\r\nimport { useStoreLocator } from './useStoreLocator';\r\nimport { useDefaultStoreLocationLoader } from '../default-store-location/useDefaultStoreLocationLoader';\r\nimport { Form } from 'react-final-form';\r\nimport { TextBoxField } from 'shared/edit/fields';\r\nimport MagnifyingGlassSVG from 'shared/components/svg/MagnifyingGlassSVG';\r\nimport StoreLocationOptions from './StoreLocationOptions';\r\nimport DefaultStoreLocationResultsItem from './DefaultStoreLocationResultsItem';\r\nimport InlineAlert from 'shared/edit/InlineAlert';\r\nimport { Localizer } from 'services/Localizer';\r\nimport type { Element } from 'react-scroll';\r\nimport scroller from 'react-scroll/modules/mixins/scroller';\r\nimport ResultsWithinDistance from './ResultsWithinDistance';\r\nimport Pagination from 'shared/components/Pagination';\r\nimport { lg, md } from 'shared/breakpoints';\r\nimport type { Desktop, Mobile, Tablet, TabletAndSmaller } from 'shared/breakpoints-responsive';\r\nconst LazyDesktop = React.lazy(() =>\r\n\timport(/* webpackChunkName: \"responsive-desktop-container\" */ 'shared/breakpoints-responsive').then((module) => ({\r\n\t\tdefault: module.Desktop,\r\n\t})),\r\n);\r\nconst LazyMobile = React.lazy(() =>\r\n\timport(/* webpackChunkName: \"responsive-mobile-container\" */ 'shared/breakpoints-responsive').then((module) => ({\r\n\t\tdefault: module.Mobile,\r\n\t})),\r\n);\r\nconst LazyTablet = React.lazy(() =>\r\n\timport(/* webpackChunkName: \"responsive-tablet-container\" */ 'shared/breakpoints-responsive').then((module) => ({\r\n\t\tdefault: module.Tablet,\r\n\t})),\r\n);\r\nconst LazyTabletAndSmaller = React.lazy(() =>\r\n\timport(/* webpackChunkName: \"responsive-desktop-tablet-smaller-container\" */ 'shared/breakpoints-responsive').then(\r\n\t\t(module) => ({\r\n\t\t\tdefault: module.TabletAndSmaller,\r\n\t\t}),\r\n\t),\r\n);\r\nconst LazyScrollToElement = React.lazy(() =>\r\n\timport('react-scroll').then((module) => ({ default: module.Element })),\r\n);\r\nconst LazyGoogleMapReact = React.lazy(() => import('google-map-react' as any));\r\n\r\ninterface MarkerProps {\r\n\tlat: number;\r\n\tlng: number;\r\n\tdto: LocationDto;\r\n}\r\n\r\n/**\r\n * Generates URL to launch Google Maps that displays the path between the searched location and the target location\r\n */\r\nexport function getGoogleMapsDirectionsUrl(searchText: string | null, targetLocation: Geolocation) {\r\n\tconst directionsUrl = '//google.com/maps/dir/';\r\n\r\n\t// more details about creating a query can be found in docs:\r\n\t// https://developers.google.com/maps/documentation/urls/guide#directions-action\r\n\tlet query = '?api=1';\r\n\tif (searchText) {\r\n\t\tquery += `&origin=${searchText}`;\r\n\t}\r\n\r\n\tquery += `&destination=${targetLocation.latitude},${targetLocation.longitude}`;\r\n\r\n\treturn `${directionsUrl}${query}`;\r\n}\r\n\r\n/**\r\n * Store Locator Component\r\n */\r\nexport default function StoreLocator() {\r\n\t// list of markers on the map\r\n\tconst [markers, setMarkers] = useState([]);\r\n\r\n\t// coordinates of the current center on the map\r\n\tconst [mapCenter, setMapCenter] = useState({\r\n\t\tlat: 0,\r\n\t\tlng: 0,\r\n\t});\r\n\r\n\t// if true Google API has been loaded\r\n\tconst [isGoogleApiLoaded, setIsGoogleApiLoaded] = useState(false);\r\n\r\n\t// if true then the search form has validation errors\r\n\tconst [hasValidationError, setHasValidationError] = useState(false);\r\n\r\n\t// reference to the current map\r\n\tconst mapObj = useRef(null);\r\n\tconst mapsObj = useRef(null);\r\n\tconst focusEl = useRef(null);\r\n\r\n\tconst [activeMarkerKey, setActiveMarkerKey] = useState(null);\r\n\r\n\t// load default/preferred store location for the current user\r\n\tconst { defaultStoreLocation } = useDefaultStoreLocationLoader();\r\n\r\n\tconst {\r\n\t\tstate: { isLoading, searchResults, savingError, loadingError, isSaving: isSavingDefaultLocation },\r\n\t\tactor: { setSearchText, goToPage, saveDefaultLocation, setDataLoaderActive, goToNextPage, goToPreviousPage },\r\n\t} = useStoreLocator({\r\n\t\tdefaultStoreLocation,\r\n\t});\r\n\r\n\tconst defaultZoom = 1;\r\n\r\n\tuseEffect(() => {\r\n\t\tsetDataLoaderActive(true);\r\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\r\n\t}, []);\r\n\r\n\t// When search results change, reload markers if store locator query has been updated. Then, center the map.\r\n\tuseEffect(() => {\r\n\t\tif (!searchResults || !searchResults.results) {\r\n\t\t\tsetMarkers([]);\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tsetMarkers(\r\n\t\t\tsearchResults.results.map((location) => {\r\n\t\t\t\treturn {\r\n\t\t\t\t\tlat: location.latitude,\r\n\t\t\t\t\tlng: location.longitude,\r\n\t\t\t\t\tdto: location,\r\n\t\t\t\t};\r\n\t\t\t}),\r\n\t\t);\r\n\t}, [searchResults]);\r\n\r\n\t/**\r\n\t * When map markers change, center map around new markers.\r\n\t *\r\n\t */\r\n\tuseEffect(() => {\r\n\t\tcenterMap();\r\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\r\n\t}, [markers]);\r\n\r\n\t/**\r\n\t * Handles the marker onClick\r\n\t *\r\n\t * @param {number} clickedMarkerIndex\r\n\t */\r\n\tconst onMarkerClick = (clickedMarkerIndex: number) => {\r\n\t\tconst markerClicked = markers[clickedMarkerIndex];\r\n\r\n\t\tcenterMapTo(markerClicked);\r\n\t\tsetActiveMarkerKey(clickedMarkerIndex);\r\n\t};\r\n\r\n\t/**\r\n\t * Google API load callback\r\n\t *\r\n\t * @param {google.maps.Map} map\r\n\t * @param {*} maps\r\n\t */\r\n\tconst onApiIsLoaded = (map: google.maps.Map, maps) => {\r\n\t\tmapObj.current = map;\r\n\t\tmapsObj.current = maps;\r\n\t\tsetIsGoogleApiLoaded(true);\r\n\t\tcenterMap();\r\n\t};\r\n\r\n\t/**\r\n\t * handles search form submission,\r\n\t *\r\n\t * @param {*} formValues\r\n\t * @returns\r\n\t */\r\n\tconst onFormSubmit = async (formValues: any) => {\r\n\t\tif (!formValues.searchText) {\r\n\t\t\tsetHasValidationError(true);\r\n\t\t\treturn;\r\n\t\t}\r\n\t\tsetHasValidationError(false);\r\n\t\tsetSearchText(formValues.searchText);\r\n\t};\r\n\r\n\t/**\r\n\t * Centers map around all markers\r\n\t *\r\n\t */\r\n\tconst centerMap = () => {\r\n\t\tif (markers && markers.length > 0) {\r\n\t\t\tif (mapObj !== null && mapsObj !== null && mapObj.current !== null) {\r\n\t\t\t\tconst bounds = new mapsObj.current.LatLngBounds();\r\n\r\n\t\t\t\tmarkers.forEach((point) => {\r\n\t\t\t\t\tbounds.extend(point);\r\n\t\t\t\t});\r\n\r\n\t\t\t\tmapObj.current.fitBounds(bounds);\r\n\t\t\t}\r\n\t\t}\r\n\t};\r\n\r\n\t/**\r\n\t * Centers map to the given marker\r\n\t *\r\n\t * @param {MarkerProps} marker\r\n\t */\r\n\tconst centerMapTo = (marker: MarkerProps) => {\r\n\t\tsetMapCenter(marker);\r\n\t};\r\n\r\n\tconst SearchFormValidationError = hasValidationError ? (\r\n\t\t\r\n\t) : null;\r\n\r\n\tconst Map = (\r\n\t\t onApiIsLoaded(map, maps)}\r\n\t\t\tonChildClick={onMarkerClick}\r\n\t\t>\r\n\t\t\t{markers.map((point, i) => {\r\n\t\t\t\treturn (\r\n\t\t\t\t\t\r\n\t\t\t\t);\r\n\t\t\t})}\r\n\t\t\r\n\t);\r\n\r\n\tconst SearchForm = (\r\n\t\t<>\r\n\t\t\t\r\n\r\n\t\t\t {\r\n\t\t\t\t\treturn (\r\n\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t{/* linter cant detect nesting because the input is encapsulated inside TextBoxField */}\r\n\t\t\t\t\t\t\t\r\n\r\n\t\t\t\t\t\t\t{SearchFormValidationError}\r\n\t\t\t\t\t\t
\r\n\t\t\t\t\t);\r\n\t\t\t\t}}\r\n\t\t\t/>\r\n\t\t\r\n\t);\r\n\r\n\tconst SearchResultsPagination =\r\n\t\tsearchResults && markers && markers.length > 0 && searchResults.pagination.totalPages > 1 ? (\r\n\t\t\t
\r\n\t\t\t\t\r\n\r\n\t\t\t\t{!isGoogleApiLoaded ? : null}\r\n\t\t\t
\r\n\t\t) : null;\r\n\r\n\tconst SearchResultsComponent = searchResults ? (\r\n\t\t
\r\n\t\t\t
\r\n\t\t\t\t{searchResults.searchText ? (\r\n\t\t\t\t\t

\r\n\t\t\t\t\t\t{Localizer('SearchResultsFor', searchResults.searchText)}\r\n\t\t\t\t\t

\r\n\t\t\t\t) : null}\r\n\r\n\t\t\t\t{searchResults.searchDistanceInMiles ? (\r\n\t\t\t\t\t
\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t
\r\n\t\t\t\t) : null}\r\n\r\n\t\t\t\t
{SearchResultsPagination}
\r\n\r\n\t\t\t\t
\r\n\t\t\t\t\t{searchResults.results.map((location, i) => {\r\n\t\t\t\t\t\treturn (\r\n\t\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t\t\t\t\t {\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tconst markerIndex = markers.findIndex(\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t(marker) => marker.dto.id === location.id,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t);\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tif (markerIndex > -1) {\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tonMarkerClick(markerIndex);\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tscroller.scrollTo('scroll-to-map', {\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tduration: 400,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tsmooth: true,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tif (window.innerWidth >= md && window.innerWidth < lg) {\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tfocusEl.current?.focus();\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t\t\t\t}}\r\n\t\t\t\t\t\t\t\t\t\t\t/>\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t\t
\r\n\r\n\t\t\t\t\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t\t
\r\n\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t {\r\n\t\t\t\t\t\t\t\t\t\t\tconst markerIndex = markers.findIndex(\r\n\t\t\t\t\t\t\t\t\t\t\t\t(marker) => marker.dto.id === location.id,\r\n\t\t\t\t\t\t\t\t\t\t\t);\r\n\t\t\t\t\t\t\t\t\t\t\tif (markerIndex > -1) {\r\n\t\t\t\t\t\t\t\t\t\t\t\tonMarkerClick(markerIndex);\r\n\t\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t\t}}\r\n\t\t\t\t\t\t\t\t\t/>\r\n\r\n\t\t\t\t\t\t\t\t\t\r\n\r\n\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t
\r\n\t\t\t\t\t\t);\r\n\t\t\t\t\t})}\r\n\t\t\t\t
\r\n\r\n\t\t\t\t
{SearchResultsPagination}
\r\n\t\t\t
\r\n\t\t
\r\n\t) : null;\r\n\r\n\treturn (\r\n\t\t}>\r\n\t\t\t<>\r\n\t\t\t\t
\r\n\t\t\t\t\t{loadingError ?? savingError != null ? : null}\r\n\t\t\t\t
\r\n\r\n\t\t\t\t{/* Mobile */}\r\n\t\t\t\t\r\n\t\t\t\t\t{SearchForm}\r\n\t\t\t\t\t{SearchResultsComponent}\r\n\t\t\t\t\r\n\r\n\t\t\t\t{/* Tablet */}\r\n\t\t\t\t\r\n\t\t\t\t\t{SearchForm}\r\n\t\t\t\t\t
\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t{Map}\r\n\t\t\t\t\t
\r\n\t\t\t\t\t{SearchResultsComponent}\r\n\t\t\t\t
\r\n\r\n\t\t\t\t{/* Desktop */}\r\n\t\t\t\t\r\n\t\t\t\t\t
\r\n\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t{SearchForm}\r\n\t\t\t\t\t\t\t{SearchResultsComponent}\r\n\t\t\t\t\t\t
\r\n\r\n\t\t\t\t\t\t
{Map}
\r\n\t\t\t\t\t
\r\n\t\t\t\t
\r\n\t\t\t\r\n\t\t
\r\n\t);\r\n}\r\n","import React from 'react';\r\nimport { initReactApp } from 'shared/util/ApplicationInit';\r\nimport StoreLocator from './StoreLocator';\r\n\r\nconst render = initReactApp(() => , 'store-locator');\r\n\r\nrender();\r\n\r\n// optional, use this to enable hot reloading\r\nif ((module as any).hot) {\r\n\t(module as any).hot.accept('./StoreLocator', () => {\r\n\t\trender();\r\n\t});\r\n}\r\n","import React from 'react';\r\nimport { SVGProps } from './SVGProps';\r\nimport classnames from 'classnames';\r\n\r\n/**\r\n * Folder SVG\r\n *\r\n * @returns\r\n */\r\nfunction FolderSVG({ className, ...rest }: SVGProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default FolderSVG;\r\n","import React from 'react';\r\nimport { SVGProps } from './SVGProps';\r\nimport classnames from 'classnames';\r\n\r\n/**\r\n * Garbage Can SVG\r\n *\r\n * @returns\r\n */\r\nfunction GarbageCanCircleSVG({ className, ...rest }: SVGProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default GarbageCanCircleSVG;\r\n","import React from 'react';\r\nimport { ModelStatus } from '../../../../Roc.SharedClientApp/types/model-status';\r\nimport DashCircleSVG from './hawksearch/components/svg/DashCircleSVG';\r\nimport CheckCircleSVG from './svg/CheckCircleSVG';\r\nimport FolderSVG from './svg/FolderSVG';\r\nimport GarbageCanCircleSVG from './svg/GarbageCanCircleSVG';\r\nimport PencilSVG from './svg/PencilSVG';\r\n\r\ninterface PageEditorStatusDisplayProps {\r\n\tstatus: ModelStatus;\r\n}\r\n\r\nexport function StatusDisplay(props: PageEditorStatusDisplayProps) {\r\n\tconst { status } = props;\r\n\r\n\treturn (\r\n\t\t
\r\n\t\t\t{status === ModelStatus.Published ? (\r\n\t\t\t\t\r\n\t\t\t) : status === ModelStatus.Inactive ? (\r\n\t\t\t\t\r\n\t\t\t) : status === ModelStatus.Deleted ? (\r\n\t\t\t\t\r\n\t\t\t) : status === ModelStatus.Draft ? (\r\n\t\t\t\t\r\n\t\t\t) : status === ModelStatus.Archived ? (\r\n\t\t\t\t\r\n\t\t\t) : null}\r\n\t\t
\r\n\t);\r\n}\r\n","// These functions may be potentially innaccurate in certain locales that use differing amounts of characters in different cases\r\n\r\n/**\r\n * Tests if a string includes another if casing is ignored\r\n * @param thisString The string to test\r\n * @param otherString The potentially included string being tested for\r\n */\r\nexport function stringWeaklyIncludes(thisString: string, otherString: string) {\r\n\treturn thisString.toLocaleLowerCase().includes(otherString.toLocaleLowerCase());\r\n}\r\n\r\n/**\r\n * Tests if a string starts with another if casing is ignored\r\n * @param thisString The string to test\r\n * @param otherString The potentially included string being tested for\r\n */\r\nexport function stringWeaklyStartsWith(thisString: string, otherString: string) {\r\n\treturn thisString.toLocaleLowerCase().startsWith(otherString.toLocaleLowerCase());\r\n}\r\n\r\n/**\r\n * Tests if a string ends with another if casing is ignored\r\n * @param thisString The string to test\r\n * @param otherString The potentially included string being tested for\r\n */\r\nexport function stringWeaklyEndsWith(thisString: string, otherString: string) {\r\n\treturn thisString.toLocaleLowerCase().endsWith(otherString.toLocaleLowerCase());\r\n}\r\n\r\n/**\r\n * Converts the first character in a string to upper-case. Will not work for all languages (for example Dutch).\r\n *\r\n * @export\r\n * @param {string} thisString\r\n * @returns\r\n */\r\nexport function firstCharacterToUpper(thisString: string) {\r\n\tif (!thisString) {\r\n\t\treturn '';\r\n\t}\r\n\r\n\tlet newString = thisString.substring(0, 1).toLocaleUpperCase();\r\n\r\n\tif (thisString.length > 1) {\r\n\t\tnewString += thisString.substring(1);\r\n\t}\r\n\r\n\treturn newString;\r\n}\r\n\r\n/**\r\n * Converts the first character in a string to upper-case. Will not work for all languages (for example Dutch).\r\n *\r\n * @export\r\n * @param {string} thisString\r\n * @returns\r\n */\r\nexport function firstCharacterToLower(thisString: string) {\r\n\tif (!thisString) {\r\n\t\treturn '';\r\n\t}\r\n\r\n\tlet newString = thisString.substring(0, 1).toLocaleLowerCase();\r\n\r\n\tif (thisString.length > 1) {\r\n\t\tnewString += thisString.substring(1);\r\n\t}\r\n\r\n\treturn newString;\r\n}\r\n\r\n// https://github.com/uxitten/polyfill/blob/master/string.polyfill.js\r\n// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/padStart\r\nexport function padStart(value, targetLength, padString) {\r\n\t// tslint:disable-next-line:no-bitwise\r\n\ttargetLength = targetLength >> 0; // truncate if number, or convert non-number to 0;\r\n\tpadString = String(typeof padString !== 'undefined' ? padString : ' ');\r\n\tif (value.length >= targetLength) {\r\n\t\treturn String(value);\r\n\t} else {\r\n\t\ttargetLength = targetLength - value.length;\r\n\t\tif (targetLength > padString.length) {\r\n\t\t\tpadString += padString.repeat(targetLength / padString.length); // append to original to ensure we are longer than needed\r\n\t\t}\r\n\t\treturn padString.slice(0, targetLength) + String(value);\r\n\t}\r\n}\r\n\r\n/**\r\n * Converts a string from \" Something Like This\" to \"something-like-this\"\r\n * @param value The string to convert\r\n */\r\nexport function toKebabCase(value: string) {\r\n\tif (!value || !value.trim()) {\r\n\t\treturn '';\r\n\t}\r\n\r\n\treturn value\r\n\t\t.trim()\r\n\t\t.replace(/[^a-zA-Z0-9]+/g, '-')\r\n\t\t.replace(/([a-z0-9])([A-Z])/g, '$1-$2')\r\n\t\t.replace(/([A-Z])([A-Z])(?=[a-z])/g, '$1-$2')\r\n\t\t.replace(/-$/, '')\r\n\t\t.toLocaleLowerCase();\r\n}\r\n\r\n/**\r\n * Converts a string from PascalCase, camelCase, snake_case, or space separated to camelCase. Beginning and trailing whitespace are trimmed.\r\n * @param value The string to convert\r\n */\r\nexport function toCamelCase(value: string) {\r\n\treturn value\r\n\t\t.replace(/(?:^\\w|[A-Z]|\\b\\w)/g, function (word, index) {\r\n\t\t\treturn index === 0 ? word.toLowerCase() : word.toUpperCase();\r\n\t\t})\r\n\t\t.replace(/(?:\\s+|[-_])/g, '');\r\n}\r\n\r\n/**\r\n * Removes html characters\r\n *\r\n * @export\r\n * @param {*} html\r\n * @returns\r\n */\r\nexport function stripHtml(html) {\r\n\tconst tmp = document.createElement('div');\r\n\ttmp.innerHTML = html;\r\n\treturn tmp.textContent || tmp.innerText || '';\r\n}\r\n\r\n/**\r\n * Cuts of text and adds ellipsis (...) after a certain number of characters\r\n * @param text The text to format\r\n * @param cutoff The number of characters to add the ellipsis after\r\n */\r\nexport function addEllipsis(text: string, cutoff: number = 20) {\r\n\tif (!text || text.length < cutoff) {\r\n\t\treturn text;\r\n\t}\r\n\r\n\treturn text.substring(0, cutoff) + '...';\r\n}\r\n\r\n/**\r\n * Trims a string value\r\n */\r\nexport function trimString(value: string) {\r\n\treturn value ? value.trim() : '';\r\n}\r\n","import React from 'react';\r\nimport { SVGProps } from './SVGProps';\r\nimport classnames from 'classnames';\r\n\r\n/**\r\n * Left chevron SVG\r\n *\r\n * @returns\r\n */\r\nfunction LeftChevronSVG({ className, ...rest }: SVGProps) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n\r\nexport default LeftChevronSVG;\r\n","var api = require(\"!../../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\");\n var content = require(\"!!../../../../node_modules/css-loader/dist/cjs.js!./style.css\");\n\n content = content.__esModule ? content.default : content;\n\n if (typeof content === 'string') {\n content = [[module.id, content, '']];\n }\n\nvar options = {};\n\noptions.insert = \"head\";\noptions.singleton = false;\n\nvar update = api(content, options);\n\n\n\nmodule.exports = content.locals || {};","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \".react-toggle {\\n touch-action: pan-x;\\n\\n display: inline-block;\\n position: relative;\\n cursor: pointer;\\n background-color: transparent;\\n border: 0;\\n padding: 0;\\n\\n -webkit-touch-callout: none;\\n -webkit-user-select: none;\\n -khtml-user-select: none;\\n -moz-user-select: none;\\n -ms-user-select: none;\\n user-select: none;\\n\\n -webkit-tap-highlight-color: rgba(0,0,0,0);\\n -webkit-tap-highlight-color: transparent;\\n}\\n\\n.react-toggle-screenreader-only {\\n border: 0;\\n clip: rect(0 0 0 0);\\n height: 1px;\\n margin: -1px;\\n overflow: hidden;\\n padding: 0;\\n position: absolute;\\n width: 1px;\\n}\\n\\n.react-toggle--disabled {\\n cursor: not-allowed;\\n opacity: 0.5;\\n -webkit-transition: opacity 0.25s;\\n transition: opacity 0.25s;\\n}\\n\\n.react-toggle-track {\\n width: 50px;\\n height: 24px;\\n padding: 0;\\n border-radius: 30px;\\n background-color: #4D4D4D;\\n -webkit-transition: all 0.2s ease;\\n -moz-transition: all 0.2s ease;\\n transition: all 0.2s ease;\\n}\\n\\n.react-toggle:hover:not(.react-toggle--disabled) .react-toggle-track {\\n background-color: #000000;\\n}\\n\\n.react-toggle--checked .react-toggle-track {\\n background-color: #19AB27;\\n}\\n\\n.react-toggle--checked:hover:not(.react-toggle--disabled) .react-toggle-track {\\n background-color: #128D15;\\n}\\n\\n.react-toggle-track-check {\\n position: absolute;\\n width: 14px;\\n height: 10px;\\n top: 0px;\\n bottom: 0px;\\n margin-top: auto;\\n margin-bottom: auto;\\n line-height: 0;\\n left: 8px;\\n opacity: 0;\\n -webkit-transition: opacity 0.25s ease;\\n -moz-transition: opacity 0.25s ease;\\n transition: opacity 0.25s ease;\\n}\\n\\n.react-toggle--checked .react-toggle-track-check {\\n opacity: 1;\\n -webkit-transition: opacity 0.25s ease;\\n -moz-transition: opacity 0.25s ease;\\n transition: opacity 0.25s ease;\\n}\\n\\n.react-toggle-track-x {\\n position: absolute;\\n width: 10px;\\n height: 10px;\\n top: 0px;\\n bottom: 0px;\\n margin-top: auto;\\n margin-bottom: auto;\\n line-height: 0;\\n right: 10px;\\n opacity: 1;\\n -webkit-transition: opacity 0.25s ease;\\n -moz-transition: opacity 0.25s ease;\\n transition: opacity 0.25s ease;\\n}\\n\\n.react-toggle--checked .react-toggle-track-x {\\n opacity: 0;\\n}\\n\\n.react-toggle-thumb {\\n transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1) 0ms;\\n position: absolute;\\n top: 1px;\\n left: 1px;\\n width: 22px;\\n height: 22px;\\n border: 1px solid #4D4D4D;\\n border-radius: 50%;\\n background-color: #FAFAFA;\\n\\n -webkit-box-sizing: border-box;\\n -moz-box-sizing: border-box;\\n box-sizing: border-box;\\n\\n -webkit-transition: all 0.25s ease;\\n -moz-transition: all 0.25s ease;\\n transition: all 0.25s ease;\\n}\\n\\n.react-toggle--checked .react-toggle-thumb {\\n left: 27px;\\n border-color: #19AB27;\\n}\\n\\n.react-toggle--focus .react-toggle-thumb {\\n -webkit-box-shadow: 0px 0px 3px 2px #0099E0;\\n -moz-box-shadow: 0px 0px 3px 2px #0099E0;\\n box-shadow: 0px 0px 2px 3px #0099E0;\\n}\\n\\n.react-toggle:active:not(.react-toggle--disabled) .react-toggle-thumb {\\n -webkit-box-shadow: 0px 0px 5px 5px #0099E0;\\n -moz-box-shadow: 0px 0px 5px 5px #0099E0;\\n box-shadow: 0px 0px 5px 5px #0099E0;\\n}\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n"],"sourceRoot":""}