{"version":3,"sources":["common/atoms/FeatureButton/FeatureButton.tsx","state/initial-form-state.ts","AppContext.ts","common/assets/codex-icon.svg","enums/DeviceSize.ts","Theme.tsx","webpack:///./src/common/assets/codex-icon.svg?c962","const/domain.ts","common/atoms/PoweredBy/PoweredBy.tsx","pages/ErrorContainer.tsx","common/assets/default-loading-icon.gif","common/atoms/fade-in/FadeIn.tsx","common/molecules/loading/Loading.tsx","common/atoms/ProgressBar/ProgressBar.tsx","services/FormService.tsx","common/molecules/QuestionTypes/DatePickerSelector.tsx","common/molecules/QuestionTypes/MultipleChoice.tsx","util/handleEnterPress.ts","common/molecules/QuestionTypes/Select.tsx","common/molecules/QuestionTypes/Text.tsx","common/molecules/QuestionTypes/TextArea.tsx","common/molecules/QuestionSelect/QuestionSelect.tsx","common/molecules/MainPage/MainPage.tsx","common/molecules/MainPageContainer/MainHeaderContainer.tsx","common/atoms/StatusIcon/StatusIcon.tsx","common/molecules/NavItems/NavItems.tsx","pages/FormContainer.tsx","routes/Routes.tsx","App.tsx","reportWebVitals.ts","index.tsx"],"names":["FeatureButtonSize","initialFormState","name","avatar","intro","title","body","buttonText","outro","meta","created","Date","createdBy","lastUpdated","lastUpdatedBy","organisationId","datasetMetaId","access","manage","organisation","team","user","edit","view","questionGroups","FormContext","createContext","formState","setFormState","console","warn","Devices","TABLET_PORTRAIT","LARGE_PHONE","NORMAL_PHONE","defaultTheme","colors","system","darkBlue","darkBlueHighlight","darkBlueShadow","darkGrey","darkOffBlack","grey","navy","offBlack","offWhite","white","general","blue","green","purple","red","sea","yellow","typography","header","sizes","p","smaller","small","tiny","h1","h2","h3","h4","h5","margin","standard","large","xlarge","xxlarge","xxxlarge","padding","borders","radius","StyledText","styled","StyledSubHeader","StyledH1","StyledInput","theme","Input","StyledTextArea","TextArea","StyledDropdownUltraWide","Dropdown","TextStyledSubHeader","div","Accordion","Title","InputWrapper","InnerInputWrapper","WarningWrapper","hasError","errorText","length","Theme","children","fonts","font","weights","DEFAULT_COLOR","_style","_g","getHeight","size","WIDE","WIDE_SMALL","WIDE_LARGE","WIDE_XLARGE","Notification","color","Face","props","height","image","FaceText","DivWrapper","isActive","calcHeight","SHADOW_HEIGHT","borderColor","ButtonWrapper","button","isDisabled","isDisplayOnly","FeatureButton","action","text","textStyle","icon","hasNotification","notificationColor","faceStyle","style","containerStyle","buttonColor","activeBorderColor","className","SMALL","onClick","disabled","DOMAIN","_extends","Object","assign","target","i","arguments","source","key","prototype","hasOwnProperty","call","apply","this","_objectWithoutProperties","excluded","sourceKeys","keys","indexOf","_objectWithoutPropertiesLoose","getOwnPropertySymbols","sourceSymbolKeys","propertyIsEnumerable","SvgCodexIcon","_ref","svgRef","titleId","baseProfile","xmlns","viewBox","width","ref","undefined","id","d","ForwardRef","StyledConfigurIcon","ConfigurIcon","PoweredBy","themeContext","useContext","ThemeContext","href","rel","display","flexDirection","Wrapper","PoweredByWrapper","ErrorContainer","alt","src","ConfigurLogo","window","location","replace","fadeIn","keyframes","FadeIn","duration","delay","delegated","animationDuration","animationDelay","Overlay","LoadingIcon","img","LoadingText","Loading","loading","DefaultLoadingIcon","ProgressWrapper","colour","isVisible","ProgressBar","useState","progress","setProgress","activeQuestionAnchor","useLocation","hash","substring","questionDetails","map","questionGroup","questions","flat","useEffect","numberOfQuestions","filter","question","displayType","Enums","FormQuestionDisplayType","HIDDEN","numberOfCompleted","x","status","FormQuestionStatus","COMPLETED","Progress","percent","FormService","c","projectId","formId","axios","get","process","params","processLists","result","data","entries","post","timeRequiredFormats","DateFormat","TIME_SIMPLE","TIME_WITH_SECONDS","TIME_24_SIMPLE","TIME_24_WITH_SECONDS","DATETIME_SHORT","DATETIME_SHORT_NO_COMMA","DATETIME_MED","DATETIME_FULL","DATETIME_HUGE","DATETIME_SHORT_WITH_SECONDS","DATETIME_SHORT_WITH_SECONDS_NO_COMMA","DATETIME_MED_WITH_SECONDS","DATETIME_FULL_WITH_SECONDS","DATETIME_HUGE_WITH_SECONDS","DATETIME_24_SHORT","DATETIME_24_SHORT_NO_COMMA","DATETIME_24_MED","DATETIME_24_FULL","DATETIME_24_HUGE","DATETIME_24_SHORT_WITH_SECONDS","DATETIME_24_SHORT_WITH_SECONDS_NO_COMMA","DATETIME_24_MED_WITH_SECONDS","DATETIME_24_FULL_WITH_SECONDS","DATETIME_24_HUGE_WITH_SECONDS","timeOnlyFormats","active","DateInputWrapper","DatePickerSelector","finalQuestion","dateFormat","DATE_SHORT","value","dateValue","setValue","markQuestionComplete","popperPlacement","popperModifiers","buttonColour","calendarOpen","setCalendarOpen","setHasError","canProceed","field","dataValidation","constraints","isRequired","isMobile","innerWidth","parseFloat","Services","validators","DataValidator","isValidDate","isValid","selected","DateTime","fromFormat","String","toString","withPortal","placeholderText","showPopperArrow","offset","enabled","onChange","e","fromJSDate","toFormat","onCalendarClose","onCalendarOpen","showTimeSelect","includes","timeIntervals","showTimeSelectOnly","MultipleChoiceWrapper","ButtonsInnerWrapper","MultipleChoice","isTablet","setButtonSize","BOOLEAN","listValues","option","index","inputValue","handleEnterPress","event","code","preventDefault","StyledFormsDropdownUltraWide","DropdownInnerWrapper","Select","disableAllScroll","enableScrollUp","questionOptions","setQuestionOptions","lv","formatQuestionOptions","clearable","placeholder","search","selection","options","onKeyUp","onOpen","onClose","TextInputWrapper","TextStyledInput","Text","setErrorText","validate","type","ValueDataType","TEXT","isText","EMAIL","isEmail","POSTCODE","isPostcode","PHONE_NUM","isPhoneNum","NUMBER","isNumber","dataValidationType","error","message","onBlur","Message","Header","TextAreaInputWrapper","LargeStyledTextArea","QuestionSelect","disableScroll","finishForm","isFormComplete","firstIncompleteQuestionIndex","findIndex","NOT_COMPLETED","isOnLastQuestion","_id","TEXT_AREA","SELECT","DATE","format","MULTIPLE_CHOICE","SlideInnerWrapper","StartFinishPageWrapper","MainPage","setIsFormComplete","setLoading","submitted","setSubmitted","setError","finalQuestionId","q","reverse","valuesArray","forEach","initialiseFormValues","formValues","setFormValues","colours","tertiary","generateAnswersObject","valuesObject","Array","isArray","join","setValueAsSubmittedDate","now","postCompletedQuestions","a","postForm","every","licenseKey","anchors","allQuestionIds","questionDetail","getAnchors","normalScrollElements","render","fullpageApi","moveSectionDown","group","questionButton","setAllowScrolling","setKeyboardScrolling","groupName","questionId","find","completeQuestion","newValue","updateQuestionStateValue","MainPageHeaderWrapper","MainPageWrapper","NavToggleWrapper","Heading","backgroundColor","LogoWrapper","ProgressBarWrapper","MainPageContainer","setIsVisibleValue","headerColour","primary","navButtonColour","secondary","progressBarColour","faBars","EXTRA_SMALL","logo","DefaultAvatar","StatusIcon","isQuestionActive","faCheckCircle","StyledAccordionContent","Content","AccordionInnerText","StyledAccordionTitle","isGroupActive","accordionActiveColour","AccordionWrapper","NavPoweredByWrapper","NavItems","setIsVisible","activeGroupIndex","setActiveGroupIndex","activeQuestionIndex","setActiveQuestionIndex","AccordionStyles","ActiveQuestionAnchorIndex","isWelcomeActive","selectCursor","groupIndex","questionIndex","handleClick","_","titleProps","getGroupStatus","numberOfCompletedQuestions","inverted","fluid","faChevronUp","faChevronDown","Sidebar","FormContainer","useParams","history","useHistory","getForm","form","push","Routes","path","exact","component","App","Provider","reportWebVitals","onPerfEntry","then","getCLS","getFID","getFCP","getLCP","getTTFB","ReactDOM","StrictMode","document","getElementById"],"mappings":"iLAYYA,E,kECVCC,EAAoC,CAC/CC,KAAM,WACNC,OACE,mFACFC,MAAO,CACLC,MAAM,oBACNC,KAAK,2DACLC,WAAY,eAEdC,MAAO,CACLH,MAAO,iBACPC,KAAK,4CAEPG,KAAM,CACJC,QAAS,IAAIC,KACbC,UAAW,GACXC,YAAa,IAAIF,KACjBG,cAAe,IAEjBC,eAAgB,GAChBC,cAAe,GACfC,OAAQ,CACNC,OAAQ,CAAEC,aAAc,GAAIC,KAAM,GAAIC,KAAM,IAC5CC,KAAM,CAAEH,aAAc,GAAIC,KAAM,GAAIC,KAAM,IAC1CE,KAAM,CAAEJ,aAAc,GAAIC,KAAM,GAAIC,KAAM,KAG5CG,eAAgB,IChBLC,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AAU0Q,aAAcA,MAE1B,cAAC,GAAD,CACE1Q,UAAWA,EACXoP,kBAAmBsB,EACnBzF,eAAgBA,EAChBc,kBAAmBA,OAIvB,cAAC,GAAD,UACE,cAAC,GAAD,SAtBG,cAAC,GAAD,CAASnM,SAAS,EAAMlF,KAAM,qBCjD1B4X,GAfI,WACjB,OACE,eAAC,IAAD,WAEE,cAAC,IAAD,CACEC,KAAI,sBACJC,OAAO,EACPC,UAAWV,KAGb,cAAC,IAAD,CAAOQ,KAAI,IAAOC,OAAO,EAAMC,UAAWjU,SCcjCkU,GApBC,WAAO,IAAD,EACcxS,mBAChCxN,GAFkB,mBACb0B,EADa,KACFC,EADE,KAKpB,OACE,cAAC,GAAD,UACE,cAAC,IAAD,UACE,cAAC,IAAD,UACE,cAACH,EAAYye,SAAb,CAAsBhO,MAAO,CAAEvQ,YAAWC,gBAA1C,SACE,qBAAK+G,UAAU,MAAf,SACE,cAAC,GAAD,eCNCwX,GAZS,SAACC,GACnBA,GAAeA,GACjB,8BAAqBC,MAAK,YAAkD,IAA/CC,EAA8C,EAA9CA,OAAQC,EAAsC,EAAtCA,OAAQC,EAA8B,EAA9BA,OAAQC,EAAsB,EAAtBA,OAAQC,EAAc,EAAdA,QAC3DJ,EAAOF,GACPG,EAAOH,GACPI,EAAOJ,GACPK,EAAOL,GACPM,EAAQN,O,OCHdO,IAASrF,OACP,cAAC,IAAMsF,WAAP,UACE,cAAC,GAAD,MAEFC,SAASC,eAAe,SAM1BX,O","file":"static/js/main.71bfcaf0.chunk.js","sourcesContent":["import React, { FC } from 'react';\nimport styled from 'styled-components';\nimport { defaultTheme } from '../../../Theme';\n\nconst WIDE_HEIGHT = 40;\nconst WIDE_LARGE_HEIGHT = 60;\nconst WIDE_SMALL_HEIGHT = 30;\nconst SHADOW_HEIGHT = 7;\nconst BORDER_BUFFER = 2;\nconst DEFAULT_COLOR = defaultTheme.colors.general.blue;\nconst DEFAULT_BORDER_COLOR = 'transparent';\n\nexport enum FeatureButtonSize {\n EXTRA_SMALL = 40,\n SMALL = 60,\n MEDIUM = 80,\n LARGE = 100,\n WIDE = 200,\n WIDE_SMALL = 150,\n WIDE_LARGE = 300,\n WIDE_XLARGE = 350,\n}\n\nexport interface FeatureButtonProps {\n // Action\n action?: () => void;\n\n // Active styling\n isActive?: boolean;\n\n // Display only\n isDisplayOnly?: boolean;\n\n // Disabled styling\n isDisabled?: boolean;\n\n // Appearance\n size?: FeatureButtonSize | number;\n height?: number;\n color?: string; // Hex code\n borderColor?: string; // Hex code\n\n // Text\n text?: string;\n textStyle?: React.CSSProperties;\n\n // Image\n image?: string;\n\n // Icon\n icon?: React.ReactElement;\n\n // Notification marker\n hasNotification?: boolean;\n notificationColor?: string; // Hex code\n\n // Face Override\n faceStyle?: React.CSSProperties;\n\n // Button Override\n style?: React.CSSProperties;\n\n // Container Override\n containerStyle?: React.CSSProperties;\n}\n\ninterface WrapperProps {\n size: FeatureButtonSize | number;\n height?: number;\n color: string; // Hex code\n borderColor: string; // Hex code\n isActive?: boolean;\n isDisabled?: boolean;\n isDisplayOnly?: boolean;\n}\n\ninterface FaceProps {\n size: FeatureButtonSize | number;\n height?: number;\n color: string; // Hex code\n image?: string;\n}\n\ninterface NotificationProps {\n isActive: boolean;\n color?: string; // Hex code\n}\n\nconst getHeight = (size: FeatureButtonSize | number) => {\n switch (size) {\n case FeatureButtonSize.WIDE:\n return WIDE_HEIGHT;\n case FeatureButtonSize.WIDE_SMALL:\n return WIDE_SMALL_HEIGHT;\n case FeatureButtonSize.WIDE_LARGE:\n return WIDE_LARGE_HEIGHT;\n case FeatureButtonSize.WIDE_XLARGE:\n return WIDE_LARGE_HEIGHT;\n default:\n return size;\n }\n};\n\nconst Notification = styled.div`\n position: absolute;\n top: -5px;\n right: -5px;\n z-index: 99;\n\n width: 13px;\n height: 13px;\n border-radius: 50%;\n border: 1px solid white;\n\n background-color: ${({ color }) => color || DEFAULT_COLOR};\n`;\n\nconst Face = styled.div`\n display: flex;\n justify-content: center;\n align-items: center;\n\n width: ${(props) => props.size}px;\n height: ${(props) => props.height || getHeight(props.size)}px;\n\n box-sizing: border-box;\n border-radius: ${({ theme }) => theme.borders.radius};\n padding: ${({ theme }) => theme.padding.standard};\n\n background: ${({ color }) => color} url(${({ image }) => image}) no-repeat\n center / 75%;\n\n transition: opacity 0.3s, background 0.3s;\n`;\n\nconst FaceText = styled.p`\n color: ${({ theme }) => theme.colors.system.white};\n\n font-size: ${({ theme }) => theme.typography.sizes.smaller};\n ${({ theme }) => theme.typography.header};\n text-transform: uppercase;\n`;\n\nconst DivWrapper = styled.div`\n display: flex;\n\n box-sizing: border-box;\n position: relative;\n\n width: ${({ size }) => size}px;\n height: ${({ isActive, size, height }) => {\n const calcHeight = height || getHeight(size);\n // BORDER_BUFFER is used here to allow for the increased size due to the active border being added\n return isActive ? calcHeight + BORDER_BUFFER : calcHeight + SHADOW_HEIGHT;\n }}px;\n\n padding: 0;\n margin: ${({ isActive }) =>\n // BORDER_BUFFER is used here to allow for the increased size due to the active border being added\n isActive ? SHADOW_HEIGHT - BORDER_BUFFER + 'px 0 0' : 0};\n border: 1px solid\n ${({ isActive, borderColor }) => (isActive ? borderColor : 'transparent')};\n border-radius: ${({ theme }) => theme.borders.radius};\n\n background: linear-gradient(\n ${({ color }) => color}CC,\n ${({ color }) => color}CC\n ),\n #000;\n\n outline: none;\n\n transition: border 0.3s, opacity 0.3s;\n`;\n\nconst ButtonWrapper = styled.button`\n display: flex;\n\n box-sizing: border-box;\n position: relative;\n\n width: ${({ size }) => size}px;\n height: ${({ isActive, size, height }) => {\n const calcHeight = height || getHeight(size);\n // BORDER_BUFFER is used here to allow for the increased size due to the active border being added\n return isActive ? calcHeight + BORDER_BUFFER : calcHeight + SHADOW_HEIGHT;\n }}px;\n\n padding: 0;\n margin: ${({ isActive }) =>\n // BORDER_BUFFER is used here to allow for the increased size due to the active border being added\n isActive ? SHADOW_HEIGHT - BORDER_BUFFER + 'px 0 0' : 0};\n border: 1px solid\n ${({ isActive, borderColor }) => (isActive ? borderColor : 'transparent')};\n border-radius: ${({ theme }) => theme.borders.radius};\n\n background: linear-gradient(\n ${({ color }) => color}CC,\n ${({ color }) => color}CC\n ),\n #000;\n\n outline: none;\n\n transition: border 0.3s, opacity 0.3s;\n\n opacity: ${({ isDisabled }) => (isDisabled ? 0.4 : 1)};\n\n ${({ isDisabled, isDisplayOnly, size, height }) =>\n !isDisabled && !isDisplayOnly\n ? `\n &:hover {\n cursor: pointer;\n }\n\n &:hover ${Face} {\n opacity: 0.7;\n }\n \n &:active {\n height: ${(height || getHeight(size)) + BORDER_BUFFER}px;\n margin-top: ${SHADOW_HEIGHT - BORDER_BUFFER}px;\n }`\n : ''};\n`;\n\nconst FeatureButton: FC = ({\n action,\n isActive = false,\n isDisplayOnly = false,\n isDisabled = false,\n size,\n height,\n color,\n borderColor,\n text,\n textStyle,\n image,\n icon,\n hasNotification = false,\n notificationColor,\n faceStyle,\n style,\n containerStyle,\n}) => {\n const buttonColor = color || DEFAULT_COLOR;\n const activeBorderColor = borderColor || DEFAULT_BORDER_COLOR;\n\n const children = (\n <>\n \n {icon}\n {text && {text}}\n \n {hasNotification && (\n \n )}\n \n );\n\n return (\n
\n {(!action || isDisplayOnly) && (\n \n {children}\n \n )}\n\n {action && (\n \n {children}\n \n )}\n
\n );\n};\n\nexport default FeatureButton;\n","import { Interfaces } from '@configur-tech/upit-core-types';\n\nexport const initialFormState: Interfaces.Form = {\n name: 'Configur',\n avatar:\n 'https://stage.d3b8n6in2yqzyt.amplifyapp.com/static/media/codex-icon.df7424b4.svg',\n intro: {\n title: `Let's get started`,\n body: `Just tap the button below to start completing this form.`,\n buttonText: 'Get Started',\n },\n outro: {\n title: 'Form Submitted',\n body: `Your response has been received, thanks!`,\n },\n meta: {\n created: new Date(),\n createdBy: '',\n lastUpdated: new Date(),\n lastUpdatedBy: '',\n },\n organisationId: '',\n datasetMetaId: '',\n access: {\n manage: { organisation: [], team: [], user: [] },\n edit: { organisation: [], team: [], user: [] },\n view: { organisation: [], team: [], user: [] },\n },\n\n questionGroups: [],\n};\n","import { Interfaces } from '@configur-tech/upit-core-types';\nimport { createContext, useContext } from 'react';\nimport { initialFormState } from './state/initial-form-state';\n\nexport interface FormOutputWithTheme extends Interfaces.FormOutput {\n theme: Interfaces.Theme;\n}\n\nexport type FormContextType = {\n formState: FormOutputWithTheme;\n setFormState: (form: FormOutputWithTheme) => void;\n};\n\nexport const FormContext = createContext({\n formState: initialFormState as FormOutputWithTheme,\n setFormState: () => console.warn('No form provider'),\n});\n\nexport const useFormContext = (): FormContextType => useContext(FormContext);\n","export default __webpack_public_path__ + \"static/media/codex-icon.281a6801.svg\";","const Devices = {\n TABLET_PORTRAIT: '800px',\n LARGE_PHONE: '450px',\n NORMAL_PHONE: '380px',\n};\n\nexport default Devices;\n","import React, { CSSProperties, FC } from 'react';\nimport GoogleFontLoader from 'react-google-font-loader';\nimport { Accordion, Dropdown, Input, TextArea } from 'semantic-ui-react';\nimport styled, { DefaultTheme, ThemeProvider } from 'styled-components';\nimport Devices from './enums/DeviceSize';\n\nexport const defaultTheme: DefaultTheme = {\n colors: {\n system: {\n darkBlue: '#272C34',\n darkBlueHighlight: '#3D4857',\n darkBlueShadow: '#1B1F24',\n darkGrey: '#808080',\n darkOffBlack: '#23282F',\n grey: '#E4E4E4',\n navy: '#01203A',\n offBlack: '#2F3640',\n offWhite: '#F0EEEE',\n white: '#F8F8F8',\n },\n general: {\n blue: '#3498DB',\n green: '#2ECC71',\n purple: '#7d317d',\n red: '#E74C3C',\n sea: '#3C6382',\n yellow: '#F7C535',\n },\n },\n\n typography: {\n header: `\n font-family: 'Roboto', 'sans-serif';\n font-weight: bold;\n margin: 0;\n padding: 0;\n `,\n body: `\n font-size: 1em;\n font-family: 'Lato', 'sans-serif';\n font-weight: regular;\n margin: 0 0 1em 0;\n padding: 0;\n `,\n sizes: {\n p: '1.0em',\n smaller: '0.85em',\n small: '0.75em',\n tiny: '0.65em',\n h1: '1.8em',\n h2: '1.6em',\n h3: '1.4em',\n h4: '1.2em',\n h5: '1.0em',\n },\n },\n\n margin: {\n small: '5px',\n standard: '10px',\n large: '15px',\n xlarge: '20px',\n xxlarge: '25px',\n xxxlarge: '30px',\n },\n\n padding: {\n small: '5px',\n standard: '10px',\n large: '15px',\n xlarge: '20px',\n xxlarge: '25px',\n xxxlarge: '30px',\n },\n\n borders: {\n radius: '5px',\n },\n};\n\nexport const StyledText = styled.p`\n ${defaultTheme.typography.body};\n font-size: ${defaultTheme.typography.sizes.p};\n color: ${defaultTheme.colors.system.offBlack};\n`;\n\nexport const StyledSubHeader = styled(StyledText)`\n ${defaultTheme.typography.header};\n font-size: ${defaultTheme.typography.sizes.h4};\n margin-bottom: ${defaultTheme.margin.standard};\n color: ${defaultTheme.colors.system.offBlack};\n`;\n\nexport const StyledBodySubHeader = styled(StyledText)`\n ${defaultTheme.typography.header};\n font-size: ${defaultTheme.typography.sizes.h5};\n margin-bottom: ${defaultTheme.margin.standard};\n color: ${defaultTheme.colors.system.offBlack};\n`;\n\nexport const StyledH1 = styled.h1`\n ${defaultTheme.typography.header};\n font-size: ${defaultTheme.typography.sizes.h1};\n margin-bottom: ${defaultTheme.margin.large};\n color: ${defaultTheme.colors.system.offBlack};\n`;\n\nexport const StyledH2 = styled.h2`\n ${defaultTheme.typography.header};\n font-size: ${defaultTheme.typography.sizes.h2};\n margin-bottom: ${defaultTheme.margin.large};\n color: ${defaultTheme.colors.system.offBlack};\n`;\n\nexport const StyledH3 = styled.h3`\n ${defaultTheme.typography.header};\n font-size: ${defaultTheme.typography.sizes.h3};\n margin-bottom: ${defaultTheme.margin.large};\n color: ${defaultTheme.colors.system.offBlack};\n`;\n\nexport const StyledH4 = styled.h4`\n ${defaultTheme.typography.header};\n font-size: ${defaultTheme.typography.sizes.h4};\n margin-bottom: ${defaultTheme.margin.standard};\n color: ${defaultTheme.colors.system.offBlack};\n`;\n\nexport const StyledH5 = styled.h5`\n ${defaultTheme.typography.header};\n font-size: ${defaultTheme.typography.sizes.h5};\n margin-bottom: ${defaultTheme.margin.standard};\n color: ${defaultTheme.colors.system.offBlack};\n`;\n\nexport const StyledInputHeader = styled(StyledText)`\n text-transform: uppercase;\n\n ${({ theme }) => theme.typography.header};\n font-size: ${({ theme }) => theme.typography.sizes.smaller};\n color: ${({ theme }) => theme.colors.system.offBlack};\n\n margin-bottom: ${({ theme }) => theme.margin.small};\n`;\n\nexport const StyledInput = styled(Input)`\n width: 250px;\n max-width: 100%;\n\n > input {\n text-align: center !important;\n\n &:focus {\n border-color: ${({ theme }) => theme.colors.general.blue};\n outline: none;\n }\n }\n`;\n\nexport const StyledTextArea = styled(TextArea)`\n width: 400px;\n max-width: 100%;\n\n padding: ${({ theme }) => `${theme.padding.standard} ${theme.margin.large}`};\n\n border: 1px solid ${({ theme }) => theme.colors.system.grey};\n border-radius: ${({ theme }) => theme.borders.radius};\n\n &:focus {\n border-color: ${({ theme }) => theme.colors.general.blue};\n outline: none;\n }\n`;\n\nexport const StyledDropdown = styled(Dropdown)`\n width: 250px;\n\n margin: ${({ theme }) => `${theme.margin.standard} 0 ${theme.margin.xlarge}`};\n\n .menu {\n max-height: 150px !important;\n }\n`;\n\nexport const StyledDropdownWide = styled(Dropdown)`\n width: 400px;\n\n margin: ${({ theme }) => `${theme.margin.standard} 0 ${theme.margin.xlarge}`};\n`;\n\nexport const StyledDropdownUltraWide = styled(Dropdown)`\n width: 650px;\n\n margin: ${({ theme }) => `${theme.margin.standard} 0 ${theme.margin.xlarge}`};\n`;\n\nexport const StageWrapper = styled.div`\n flex-grow: 2;\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n`;\n\nexport const StageInner = styled.div`\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n\n padding: ${({ theme }) =>\n `${theme.padding.xxxlarge} ${theme.padding.xlarge}`};\n`;\n\nexport const StageBodyText = styled(StyledText)`\n width: 100%;\n max-width: 700px;\n margin-bottom: ${({ theme }) => theme.margin.xlarge};\n text-align: center;\n`;\n\nexport const StyledAccordion = styled(Accordion)`\n min-width: 350px;\n\n background-color: ${({ theme }) => theme.colors.system.white};\n border: 1px solid ${({ theme }) => theme.colors.system.grey};\n border-radius: ${({ theme }) => theme.borders.radius};\n`;\n\nexport const StyledAccordionTitle = styled(Accordion.Title)`\n display: flex;\n justify-content: space-between;\n align-items: center;\n\n padding: ${({ theme }) =>\n `${theme.padding.standard} ${theme.padding.large}`} !important;\n\n border-bottom: 1px solid ${({ theme }) => theme.colors.system.grey};\n\n > p {\n margin: 0;\n }\n`;\n\nexport const TextStyledSubHeader = styled(StyledSubHeader)`\n font-size: 2.5em;\n padding: ${({ theme }) => theme.padding.standard};\n margin: 0;\n @media only screen and (max-width: ${Devices.LARGE_PHONE}) {\n font-size: ${({ theme }) => theme.typography.sizes.h2};\n }\n`;\n\nexport const InputWrapper = styled.div`\n display: flex;\n flex-direction: column;\n width: 800px;\n > .input {\n width: 800px;\n max-width: 800px;\n font-size: ${({ theme }) => theme.typography.sizes.h1};\n }\n\n > div {\n padding: ${({ theme }) => theme.padding.standard};\n align-self: flex-end;\n }\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n width: 95vw;\n > .input {\n max-width: 95vw;\n }\n }\n @media only screen and (max-width: ${Devices.LARGE_PHONE}) {\n > .input {\n font-size: ${({ theme }) => theme.typography.sizes.h3};\n }\n }\n`;\n\nexport const InnerInputWrapper = styled.div`\n width: 800px;\n max-width: 800px;\n padding: ${({ theme }) => theme.padding.standard};\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n width: 100%;\n }\n`;\n\nexport const DefaultPopupStyles: CSSProperties = {\n border: 'none',\n borderRadius: defaultTheme.borders.radius,\n fontFamily: 'Roboto',\n fontWeight: 'bold',\n};\n\nexport const WarningWrapper = styled.div<{\n hasError: boolean;\n errorText: string;\n}>`\n ${({ hasError, errorText }) =>\n hasError && errorText && errorText.length > 0\n ? `padding: ${({ theme }) => theme.padding.standard};`\n : `display:none;`};\n`;\n\nconst Theme: FC = ({ children }) => (\n \n \n {children}\n \n);\n\nexport default Theme;\n","var _style, _g;\n\nfunction _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nimport * as React from \"react\";\n\nfunction SvgCodexIcon(_ref, svgRef) {\n var title = _ref.title,\n titleId = _ref.titleId,\n props = _objectWithoutProperties(_ref, [\"title\", \"titleId\"]);\n\n return /*#__PURE__*/React.createElement(\"svg\", _extends({\n baseProfile: \"tiny-ps\",\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 1208 1208\",\n width: 1208,\n height: 1208,\n ref: svgRef,\n \"aria-labelledby\": titleId\n }, props), title === undefined ? /*#__PURE__*/React.createElement(\"title\", {\n id: titleId\n }, \"icon (1)-ai\") : title ? /*#__PURE__*/React.createElement(\"title\", {\n id: titleId\n }, title) : null, _style || (_style = /*#__PURE__*/React.createElement(\"style\", null, \"\\n\\t\\ttspan { white-space:pre }\\n\\t\\t.shp0 { fill: #f9c041 } \\n\\t\\t.shp1 { fill: #3fc2a0 } \\n\\t\")), _g || (_g = /*#__PURE__*/React.createElement(\"g\", {\n id: \"Layer 1\"\n }, /*#__PURE__*/React.createElement(\"path\", {\n id: \"\",\n className: \"shp0\",\n d: \"M805.81 237.75C730.71 237.75 660.91 260.44 602.86 299.3C702.72 364.51 768.76 477.18 768.76 605.34C768.76 732.01 704.28 843.59 606.37 909.13L606.37 909.13C663.73 946.58 732.2 968.43 805.81 968.43C1007.58 968.43 1171.15 804.86 1171.15 603.09C1171.15 401.32 1007.58 237.75 805.81 237.75Z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"\",\n className: \"shp1\",\n d: \"M440.47 603.09C440.47 476.43 504.95 364.84 602.86 299.3L602.86 299.3C545.51 261.85 477.03 240 403.42 240C201.65 240 38.08 403.57 38.08 605.34C38.08 807.11 201.65 970.68 403.42 970.68C478.53 970.68 548.32 947.99 606.37 909.13C506.52 843.92 440.47 731.25 440.47 603.09Z\"\n }))));\n}\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(SvgCodexIcon);\nexport default __webpack_public_path__ + \"static/media/codex-icon.281a6801.svg\";\nexport { ForwardRef as ReactComponent };","export const DOMAIN = 'https://goconfigur.com';\n","import React, { FC, useContext } from 'react';\nimport styled, { ThemeContext } from 'styled-components';\nimport { DOMAIN } from '../../../const/domain';\nimport { ReactComponent as ConfigurIcon } from '../../assets/codex-icon.svg';\nimport FeatureButton, {\n FeatureButtonSize,\n} from '../../atoms/FeatureButton/FeatureButton';\n\nconst StyledConfigurIcon = styled(ConfigurIcon)`\n margin-left: ${({ theme }) => theme.margin.standard};\n`;\n\nconst PoweredBy: FC = () => {\n const themeContext = useContext(ThemeContext);\n return (\n \n }\n />\n \n );\n};\n\nexport default PoweredBy;\n","import React, { FC, useContext } from 'react';\nimport { Helmet } from 'react-helmet-async';\nimport styled, { ThemeContext } from 'styled-components';\nimport ConfigurLogo from '../common/assets/codex-icon.svg';\nimport FeatureButton, {\n FeatureButtonSize,\n} from '../common/atoms/FeatureButton/FeatureButton';\nimport PoweredBy from '../common/atoms/PoweredBy/PoweredBy';\nimport { DOMAIN } from '../const/domain';\nimport Devices from '../enums/DeviceSize';\nimport { TextStyledSubHeader } from '../Theme';\n\nconst Wrapper = styled.div`\n width: 100%;\n height: 100vh;\n\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n\n > img {\n width: 150px;\n }\n\n > p:last-of-type {\n margin-bottom: ${({ theme }) => theme.margin.xxxlarge};\n }\n`;\n\nconst PoweredByWrapper = styled.div`\n right: ${({ theme }) => theme.margin.xlarge};\n position: fixed;\n bottom: ${({ theme }) => theme.margin.xlarge};\n z-index: 99;\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n display: none;\n }\n`;\n\nconst ErrorContainer: FC = () => {\n const themeContext = useContext(ThemeContext);\n\n return (\n <>\n \n {`Forms Powered by Configur`}\n \n\n \n {'Configur\n\n Want to create your own form?\n

\n Sign up to Configur today to easily store, secure and share your data\n across Forms, APIs, Data Views and more!\n

\n window.location.replace(DOMAIN)}\n size={FeatureButtonSize.WIDE}\n color={themeContext.colors.general.green}\n text={'Sign Up Now'}\n />\n
\n \n \n \n \n );\n};\n\nexport default ErrorContainer;\n","export default __webpack_public_path__ + \"static/media/default-loading-icon.aea186cf.gif\";","import React, { FC } from 'react';\nimport styled, { keyframes } from 'styled-components';\n\ninterface FadeInProps {\n duration?: number;\n delay?: number;\n}\n\nconst fadeIn = keyframes`\n from {\n opacity: 0;\n }\n to {\n opacity: 1;\n }\n`;\n\nconst FadeIn: FC = ({\n duration = 300,\n delay = 0,\n children,\n ...delegated\n}) => {\n return (\n \n {children}\n \n );\n};\nconst Wrapper = styled.div`\n position: absolute;\n z-index: 999;\n @media (prefers-reduced-motion: no-preference) {\n animation-name: ${fadeIn};\n animation-fill-mode: backwards;\n }\n`;\nexport default FadeIn;\n","import React, { FC } from 'react';\nimport styled from 'styled-components';\nimport { StyledH1 } from '../../../Theme';\nimport DefaultLoadingIcon from '../../assets/default-loading-icon.gif';\nimport FadeIn from '../../atoms/fade-in/FadeIn';\n\nexport interface LoadingProps {\n loading?: boolean;\n image?: React.ReactElement;\n text?: string;\n}\n\nconst Overlay = styled.div`\n display: flex;\n justify-content: center;\n align-items: center;\n\n position: fixed;\n width: 100vw;\n height: 100vh;\n\n background-color: ${({ theme }) => `${theme.colors.system.white}`};\n z-index: 999;\n`;\n\nconst Wrapper = styled.div`\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n`;\n\nconst LoadingIcon = styled.img`\n width: 150px;\n height: 150px;\n`;\n\nconst LoadingText = styled(StyledH1)`\n margin-top: ${({ theme }) => theme.margin.large};\n`;\n\nconst Loading: FC = ({ loading, image, text }) => {\n if (!loading) {\n return null;\n }\n\n return (\n \n \n \n {image || }\n {text || 'Loading...'}\n \n \n \n );\n};\n\nexport default Loading;\n","import { Enums } from '@configur-tech/upit-core-types';\nimport React, { FC, useContext, useEffect, useState } from 'react';\nimport { useLocation } from 'react-router-dom';\nimport { Progress } from 'semantic-ui-react';\nimport styled from 'styled-components';\nimport { FormContext } from '../../../AppContext';\nimport Devices from '../../../enums/DeviceSize';\n\nexport interface ProgressBarProps {\n isVisible: boolean;\n colour?: string;\n}\n\nconst ProgressWrapper = styled.div<{ isVisible: boolean; colour?: string }>`\n width: 20vw;\n padding: ${({ theme }) => theme.padding.xlarge};\n > .ui.progress:last-child {\n margin: 0;\n > div {\n background-color: ${({ colour, theme }) =>\n colour || theme.colors.general.green};\n }\n }\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n padding: 0;\n width: 100vw;\n ${({ isVisible }) => (isVisible ? `display:none` : ``)};\n }\n`;\n\nconst ProgressBar: FC = ({ isVisible, colour }) => {\n const { formState } = useContext(FormContext);\n const [progress, setProgress] = useState(0);\n const activeQuestionAnchor = useLocation().hash.substring(1);\n\n const questionDetails = formState.questionGroups\n .map((questionGroup) => questionGroup.questions)\n .flat();\n\n useEffect(() => {\n const numberOfQuestions = questionDetails.filter(\n (question) =>\n question.displayType !== Enums.FormQuestionDisplayType.HIDDEN,\n ).length;\n const numberOfCompleted = questionDetails.filter(\n (x) =>\n x.status === Enums.FormQuestionStatus.COMPLETED &&\n x.displayType !== Enums.FormQuestionDisplayType.HIDDEN,\n ).length;\n const newProgress = (numberOfCompleted / numberOfQuestions) * 100;\n\n setProgress(newProgress);\n }, [activeQuestionAnchor, questionDetails]);\n\n return (\n \n \n \n );\n};\n\nexport default ProgressBar;\n","import { Interfaces } from '@configur-tech/upit-core-types';\nimport axios from 'axios';\nimport { FormOutputWithTheme } from '../AppContext';\n\nconst READ_ENDPOINT = process.env['REACT_APP_CRUD_FORM'] || '';\nconst POST_ENDPOINT = process.env['REACT_APP_DATASET_API'] || '';\n\ninterface DatasetPostResponse {\n datasetMeta: Interfaces.DatasetMetaOutput;\n entries: Record[];\n}\n\nexport default class FormService {\n c;\n public static async getForm(\n projectId: string,\n formId: string,\n ): Promise {\n const result = await axios.get(`${READ_ENDPOINT}${formId}`, {\n params: { projectId, processLists: true },\n });\n\n return result?.data?.data as FormOutputWithTheme;\n }\n\n public static async postForm(\n formId: string,\n datasetMetaId: string,\n entries: Record[],\n ): Promise {\n const result = await axios.post(\n `${POST_ENDPOINT}${formId}/${datasetMetaId}`,\n {\n entries,\n },\n );\n\n return result?.data as DatasetPostResponse;\n }\n}\n","import { Enums, Services } from '@configur-tech/upit-core-types';\nimport { DateTime } from 'luxon';\nimport React, { FC, useEffect, useState } from 'react';\nimport DatePicker from 'react-datepicker';\nimport styled from 'styled-components';\nimport Devices from '../../../enums/DeviceSize';\nimport QuestionProps from '../../../interfaces/QuestionProps';\nimport { InputWrapper, TextStyledSubHeader } from '../../../Theme';\nimport FeatureButton, {\n FeatureButtonSize,\n} from '../../atoms/FeatureButton/FeatureButton';\n\ninterface DateTimePickerProps extends QuestionProps {\n dateValue?: string;\n dateFormat?: Enums.DateFormat | string;\n popperPlacement?: string;\n popperModifiers?: Record | null;\n}\n\nconst timeRequiredFormats = [\n Enums.DateFormat.TIME_SIMPLE,\n Enums.DateFormat.TIME_WITH_SECONDS,\n Enums.DateFormat.TIME_24_SIMPLE,\n Enums.DateFormat.TIME_24_WITH_SECONDS,\n Enums.DateFormat.DATETIME_SHORT,\n Enums.DateFormat.DATETIME_SHORT_NO_COMMA,\n Enums.DateFormat.DATETIME_MED,\n Enums.DateFormat.DATETIME_FULL,\n Enums.DateFormat.DATETIME_HUGE,\n Enums.DateFormat.DATETIME_SHORT_WITH_SECONDS,\n Enums.DateFormat.DATETIME_SHORT_WITH_SECONDS_NO_COMMA,\n Enums.DateFormat.DATETIME_MED_WITH_SECONDS,\n Enums.DateFormat.DATETIME_FULL_WITH_SECONDS,\n Enums.DateFormat.DATETIME_HUGE_WITH_SECONDS,\n Enums.DateFormat.DATETIME_24_SHORT,\n Enums.DateFormat.DATETIME_24_SHORT_NO_COMMA,\n Enums.DateFormat.DATETIME_24_MED,\n Enums.DateFormat.DATETIME_24_FULL,\n Enums.DateFormat.DATETIME_24_HUGE,\n Enums.DateFormat.DATETIME_24_SHORT_WITH_SECONDS,\n Enums.DateFormat.DATETIME_24_SHORT_WITH_SECONDS_NO_COMMA,\n Enums.DateFormat.DATETIME_24_MED_WITH_SECONDS,\n Enums.DateFormat.DATETIME_24_FULL_WITH_SECONDS,\n Enums.DateFormat.DATETIME_24_HUGE_WITH_SECONDS,\n];\n\nconst timeOnlyFormats = [\n Enums.DateFormat.TIME_SIMPLE,\n Enums.DateFormat.TIME_WITH_SECONDS,\n Enums.DateFormat.TIME_24_SIMPLE,\n Enums.DateFormat.TIME_24_WITH_SECONDS,\n];\n\nconst Wrapper = styled.div<{ active }>`\n align-items: center;\n background: #fff;\n\n width: calc(100% - 20px);\n height: 10vh;\n margin: ${({ theme }) => theme.margin.standard};\n\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n width: 90vw;\n }\n\n border: 1px solid\n ${({ theme, active }) =>\n active ? theme.colors.general.blue : theme.colors.system.grey};\n border-radius: ${({ theme }) => theme.borders.radius};\n\n > div {\n display: flex;\n width: 100%;\n min-height: 100%;\n\n > div {\n > input {\n text-align: left !important;\n font-size: ${({ theme }) => theme.typography.sizes.h3};\n vertical-align: center;\n\n border: none;\n width: 100%;\n height: 100%;\n\n &:hover {\n cursor: pointer;\n }\n\n &:focus {\n border: none;\n outline: none;\n }\n }\n }\n }\n\n .react-datepicker__portal {\n position: absolute;\n }\n\n .react-datepicker {\n font-size: ${({ theme }) => theme.typography.sizes.p};\n box-sizing: content-box;\n @media only screen and (max-width: ${Devices.LARGE_PHONE}) {\n width: 250px;\n font-size: ${({ theme }) => theme.typography.sizes.p};\n }\n\n button {\n box-sizing: border-box;\n }\n }\n .react-datepicker__month-container {\n width: inherit;\n display: flex;\n flex-direction: column;\n }\n .react-datepicker__header {\n padding-top: ${({ theme }) => theme.padding.standard};\n }\n .react-datepicker__month {\n font-size: ${({ theme }) => theme.typography.sizes.h4};\n @media only screen and (max-width: ${Devices.LARGE_PHONE}) {\n font-size: ${({ theme }) => theme.typography.sizes.p};\n }\n @media only screen and (max-width: ${Devices.NORMAL_PHONE}) {\n font-size: ${({ theme }) => theme.typography.sizes.small};\n }\n }\n\n .react-datepicker__week {\n display: flex;\n justify-content: space-evenly;\n }\n\n .react-datepicker__day {\n padding: ${({ theme }) => theme.padding.small};\n }\n\n .react-datepicker__day--keyboard-selected {\n background-color: ${({ theme }) => theme.colors.general.blue};\n }\n\n .react-datepicker__day-names {\n display: flex;\n justify-content: space-evenly;\n @media only screen and (max-width: ${Devices.NORMAL_PHONE}) {\n font-size: ${({ theme }) => theme.typography.sizes.smaller};\n }\n }\n .react-datepicker__current-month {\n font-size: ${({ theme }) => theme.typography.sizes.h4};\n width: inherit;\n @media only screen and (max-width: ${Devices.NORMAL_PHONE}) {\n font-size: ${({ theme }) => theme.typography.sizes.smaller};\n }\n }\n`;\n\nconst DateInputWrapper = styled(InputWrapper)`\n > .ui.input {\n height: 105px;\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n height: 85px;\n }\n > input {\n width: 100%;\n height: 100%;\n padding: ${({ theme }) => theme.padding.large};\n }\n }\n`;\n\nconst DatePickerSelector: FC = ({\n question,\n finalQuestion,\n dateFormat = Enums.DateFormat.DATE_SHORT,\n value,\n dateValue,\n setValue,\n markQuestionComplete,\n popperPlacement,\n popperModifiers,\n buttonColour,\n}) => {\n const [calendarOpen, setCalendarOpen] = useState(false);\n const [hasError, setHasError] = useState(false);\n\n const buttonText = finalQuestion ? 'Finish' : 'Next';\n\n const canProceed = question.field.dataValidation?.constraints?.isRequired\n ? !!(value && !hasError)\n : !hasError;\n\n const isMobile = window.innerWidth < parseFloat(Devices.LARGE_PHONE);\n\n const isValid = (value: string | number | boolean | string[]) => {\n if (!value && !question.field.dataValidation?.constraints?.isRequired) {\n return setHasError(false);\n }\n\n return setHasError(Services.validators.DataValidator.isValidDate(value));\n };\n\n useEffect(() => {\n if (value) {\n isValid(value);\n }\n }, []);\n\n return (\n \n {question.question}\n \n \n setValue(DateTime.fromJSDate(e).toFormat(dateFormat))\n }\n onCalendarClose={() => setCalendarOpen(false)}\n onCalendarOpen={() => setCalendarOpen(true)}\n showTimeSelect={timeRequiredFormats.includes(\n dateFormat as Enums.DateFormat,\n )}\n timeIntervals={1}\n showTimeSelectOnly={timeOnlyFormats.includes(\n dateFormat as Enums.DateFormat,\n )}\n />\n \n \n \n );\n};\n\nexport default DatePickerSelector;\n","import { Interfaces } from '@configur-tech/upit-core-types';\nimport { FormQuestionDisplayType } from '@configur-tech/upit-core-types/lib/enums';\nimport React, { FC, useContext } from 'react';\nimport styled, { ThemeContext } from 'styled-components';\nimport Devices from '../../../enums/DeviceSize';\nimport QuestionProps from '../../../interfaces/QuestionProps';\nimport {\n InnerInputWrapper,\n InputWrapper,\n TextStyledSubHeader,\n} from '../../../Theme';\nimport FeatureButton, {\n FeatureButtonSize,\n} from '../../atoms/FeatureButton/FeatureButton';\n\nconst MultipleChoiceWrapper = styled(InputWrapper)`\n min-height: 10vh;\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n width: 95vw;\n }\n`;\n\nconst ButtonsInnerWrapper = styled(InnerInputWrapper)`\n display: flex;\n flex-wrap: wrap;\n\n > div {\n padding-bottom: ${({ theme }) => theme.padding.large};\n margin-right: ${({ theme }) => theme.margin.xxxlarge};\n > button > div > p {\n font-size: ${({ theme }) => theme.typography.sizes.h3};\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n }\n }\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n > div {\n margin-right: ${({ theme }) => theme.margin.xxxlarge};\n }\n }\n @media only screen and (max-width: ${Devices.LARGE_PHONE}) {\n justify-content: space-around;\n > div {\n margin-right: 0;\n > button > div > p {\n font-size: ${({ theme }) => theme.typography.sizes.h5};\n }\n }\n }\n`;\n\nconst MultipleChoice: FC = ({\n question,\n value,\n finalQuestion,\n setValue,\n markQuestionComplete,\n buttonColour,\n}) => {\n const themeContext = useContext(ThemeContext);\n const isMobile = window.innerWidth < parseFloat(Devices.LARGE_PHONE);\n const isTablet = window.innerWidth < parseFloat(Devices.TABLET_PORTRAIT);\n const buttonText = finalQuestion ? 'Finish' : 'Next';\n const isActive = (value, text) => {\n return String(value).includes(String(text));\n };\n\n const canProceed = question.field.dataValidation?.constraints?.isRequired\n ? !!value || value === false\n : true;\n\n const setButtonSize = () => {\n return isMobile\n ? FeatureButtonSize.WIDE_LARGE\n : isTablet\n ? FeatureButtonSize.WIDE_LARGE\n : FeatureButtonSize.WIDE_XLARGE;\n };\n\n const handleMCClick = (inputValue: string) => {\n setValue(value === inputValue ? '' : inputValue);\n };\n\n return question.displayType === FormQuestionDisplayType.BOOLEAN ? (\n \n {question.question}\n\n \n setValue(value !== true)}\n />\n setValue(value === false)}\n />\n \n \n \n ) : (\n \n {question.question}\n\n \n {(question.field.dataValidation?.constraints\n ?.listValues as Interfaces.ListValue[])?.map((option, index) => {\n return (\n handleMCClick(option.value)}\n />\n );\n })}\n \n \n \n );\n};\n\nexport default MultipleChoice;\n","export const handleEnterPress = (\n event: KeyboardEvent,\n canProceed: boolean,\n markQuestionComplete: () => void,\n): void => {\n if (event.code === 'Enter' && canProceed) {\n event.preventDefault();\n markQuestionComplete();\n }\n};\n","import React, { FC, useEffect, useState } from 'react';\nimport { DropdownItemProps } from 'semantic-ui-react';\nimport styled from 'styled-components';\nimport Devices from '../../../enums/DeviceSize';\nimport QuestionProps from '../../../interfaces/QuestionProps';\nimport {\n InnerInputWrapper,\n InputWrapper,\n StyledDropdownUltraWide,\n TextStyledSubHeader,\n} from '../../../Theme';\nimport { handleEnterPress } from '../../../util/handleEnterPress';\nimport FeatureButton, {\n FeatureButtonSize,\n} from '../../atoms/FeatureButton/FeatureButton';\n\nconst StyledFormsDropdownUltraWide = styled(StyledDropdownUltraWide)`\n width: 100%;\n min-height: 10vh;\n`;\n\nconst DropdownInnerWrapper = styled(InnerInputWrapper)`\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n width: 95vw;\n }\n > .ui.selection.dropdown {\n padding: ${({ theme }) => theme.padding.large};\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n justify-content: flex-start;\n margin: 0;\n font-size: ${({ theme }) => theme.typography.sizes.h1};\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n font-size: ${({ theme }) => theme.typography.sizes.h4};\n }\n > i.dropdown {\n position: static;\n margin-left: auto;\n }\n }\n`;\n\nconst Select: FC = ({\n question,\n value,\n finalQuestion,\n setValue,\n markQuestionComplete,\n disableAllScroll,\n enableScrollUp,\n buttonColour,\n}) => {\n const buttonText = finalQuestion ? 'Finish' : 'Next';\n const [questionOptions, setQuestionOptions] = useState(\n [],\n );\n\n const canProceed = question.field.dataValidation?.constraints?.isRequired\n ? !!value\n : true;\n\n const formatQuestionOptions = (question) => {\n return question.field.dataValidation?.constraints?.listValues?.map(\n (lv, i) => {\n return {\n key: `option-${lv.value}-${i}`,\n text: lv.value,\n value: lv.value,\n };\n },\n );\n };\n\n useEffect(() => {\n setQuestionOptions(formatQuestionOptions(question));\n }, [question]);\n\n // TODO - ADD MULTIPLE SUPPORT IN FE\n // const isMultiple =\n // question && question?.numberSelectable && question.numberSelectable > 1;\n\n return (\n \n {question.question}\n\n \n {\n setValue(data.value);\n }}\n onKeyUp={(event: KeyboardEvent) => {\n handleEnterPress(event, canProceed, markQuestionComplete);\n }}\n onOpen={() => {\n if (disableAllScroll) {\n disableAllScroll();\n }\n }}\n onClose={() => {\n if (enableScrollUp) {\n enableScrollUp();\n }\n }}\n />\n \n \n \n );\n};\n\nexport default Select;\n","import { Enums, Interfaces, Services } from '@configur-tech/upit-core-types';\nimport React, { FC, useState } from 'react';\nimport { Message } from 'semantic-ui-react';\nimport styled from 'styled-components';\nimport Devices from '../../../enums/DeviceSize';\nimport QuestionProps from '../../../interfaces/QuestionProps';\nimport {\n InputWrapper,\n StyledInput,\n TextStyledSubHeader,\n WarningWrapper,\n} from '../../../Theme';\nimport { handleEnterPress } from '../../../util/handleEnterPress';\nimport FeatureButton, {\n FeatureButtonSize,\n} from '../../atoms/FeatureButton/FeatureButton';\n\nconst TextInputWrapper = styled(InputWrapper)`\n > .ui.input {\n height: 105px;\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n height: 85px;\n }\n > input {\n height: 100%;\n padding: ${({ theme }) => theme.padding.large};\n }\n }\n`;\n\nconst TextStyledInput = styled(StyledInput)`\n > input {\n text-align: left !important;\n }\n`;\n\nconst Text: FC = ({\n question,\n value,\n finalQuestion,\n setValue,\n markQuestionComplete,\n buttonColour,\n}) => {\n const buttonText = finalQuestion ? 'Finish' : 'Next';\n const [hasError, setHasError] = useState(false);\n const [errorText, setErrorText] = useState('');\n\n const isValid = (\n type: Enums.ValueDataType,\n value: string | number | boolean | string[],\n constraints?: Interfaces.SchemaFieldConstraints,\n ) => {\n if (type === Enums.ValueDataType.TEXT) {\n if (!value && !question.field.dataValidation?.constraints?.isRequired) {\n return setHasError(false);\n }\n\n if (Services.validators.DataValidator.isText(value, constraints)) {\n return setHasError(false);\n }\n\n setHasError(true);\n setErrorText('This is not valid text.');\n }\n\n if (type === Enums.ValueDataType.EMAIL) {\n if (!value && !question.field.dataValidation?.constraints?.isRequired) {\n return setHasError(false);\n }\n\n if (Services.validators.DataValidator.isEmail(value)) {\n return setHasError(false);\n }\n\n setHasError(true);\n setErrorText('This is not a valid email address');\n }\n\n if (type === Enums.ValueDataType.POSTCODE) {\n if (!value && !question.field.dataValidation?.constraints?.isRequired) {\n return setHasError(false);\n }\n\n if (Services.validators.DataValidator.isPostcode(value, constraints)) {\n return setHasError(false);\n }\n\n setHasError(true);\n setErrorText('This is not a valid postcode');\n }\n\n if (type === Enums.ValueDataType.PHONE_NUM) {\n if (!value && !question.field.dataValidation?.constraints?.isRequired) {\n return setHasError(false);\n }\n\n if (Services.validators.DataValidator.isPhoneNum(value, constraints)) {\n return setHasError(false);\n }\n\n setHasError(true);\n setErrorText('This is not a valid phone number');\n }\n\n if (type === Enums.ValueDataType.NUMBER) {\n if (Services.validators.DataValidator.isNumber(value, constraints)) {\n return setHasError(false);\n }\n\n setHasError(true);\n setErrorText('This is not a valid number');\n }\n };\n\n const canProceed = question.field.dataValidation?.constraints?.isRequired\n ? !!(value && !hasError)\n : !hasError;\n\n const validate = (event?, canProceed?, markQuestionComplete?) => {\n try {\n isValid(\n question.field.dataValidation?.dataValidationType ||\n Enums.ValueDataType.TEXT,\n value,\n question.field.dataValidation?.constraints,\n );\n handleEnterPress(event, canProceed, markQuestionComplete);\n } catch (error) {\n setHasError(error);\n setErrorText(error.message);\n }\n };\n\n return (\n \n {question.question}\n {\n setValue(e.target.value);\n }}\n onBlur={validate}\n error={hasError}\n type={question.displayType}\n onKeyUp={(event: KeyboardEvent) => {\n if (event.code === 'Enter') {\n validate(event, canProceed, markQuestionComplete);\n }\n }}\n />\n \n \n {errorText}\n \n \n \n \n );\n};\n\nexport default Text;\n","import { Services } from '@configur-tech/upit-core-types';\nimport { SchemaFieldConstraints } from '@configur-tech/upit-core-types/lib/interfaces';\nimport React, { FC, useState } from 'react';\nimport { Message } from 'semantic-ui-react';\nimport styled from 'styled-components';\nimport Devices from '../../../enums/DeviceSize';\nimport QuestionProps from '../../../interfaces/QuestionProps';\nimport {\n InnerInputWrapper,\n InputWrapper,\n StyledTextArea,\n TextStyledSubHeader,\n WarningWrapper,\n} from '../../../Theme';\nimport FeatureButton, {\n FeatureButtonSize,\n} from '../../atoms/FeatureButton/FeatureButton';\n\nconst TextAreaInputWrapper = styled(InputWrapper)`\n > textarea {\n width: 800px;\n max-width: 800px;\n font-size: ${({ theme }) => theme.typography.sizes.h1};\n }\n\n > textarea {\n padding: ${({ theme }) => theme.padding.standard};\n align-self: flex-end;\n }\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n > textarea {\n width: 90vw;\n }\n }\n @media only screen and (max-width: ${Devices.LARGE_PHONE}) {\n > textarea {\n font-size: ${({ theme }) => theme.typography.sizes.h3};\n > div {\n > textarea {\n font-size: ${({ theme }) => theme.typography.sizes.h3};\n }\n }\n }\n }\n`;\n\nconst LargeStyledTextArea = styled(StyledTextArea)`\n width: 100%;\n height: 15vh;\n`;\n\nconst TextArea: FC = ({\n question,\n value,\n finalQuestion,\n setValue,\n markQuestionComplete,\n buttonColour,\n}) => {\n const buttonText = finalQuestion ? 'Finish' : 'Next';\n const [hasError, setHasError] = useState(false);\n const [errorText, setErrorText] = useState('');\n\n const isValid = (\n value: string | number | boolean | string[],\n constraints?: SchemaFieldConstraints,\n ) => {\n if (!value && !question.field.dataValidation?.constraints?.isRequired) {\n return setHasError(false);\n }\n\n Services.validators.DataValidator.isText(value, constraints)\n ? setHasError(false)\n : setHasError(true);\n };\n\n const canProceed = question.field.dataValidation?.constraints?.isRequired\n ? !!(value && !hasError)\n : !hasError;\n\n return (\n \n {question.question}\n \n {\n setValue(e.target.value);\n }}\n type={question.displayType}\n onBlur={() => {\n try {\n isValid(value, question.field.dataValidation?.constraints);\n } catch (error) {\n setHasError(error);\n setErrorText(error.message);\n }\n }}\n />\n \n \n \n {errorText}\n \n \n \n \n );\n};\n\nexport default TextArea;\n","import {\n FormQuestionDisplayType,\n FormQuestionStatus,\n} from '@configur-tech/upit-core-types/lib/enums';\nimport { FormQuestion } from '@configur-tech/upit-core-types/lib/interfaces';\nimport React, { FC, useContext, useEffect } from 'react';\nimport { useLocation } from 'react-router-dom';\nimport { FormContext } from '../../../AppContext';\nimport DatePickerSelector from '../QuestionTypes/DatePickerSelector';\nimport MultipleChoice from '../QuestionTypes/MultipleChoice';\nimport Select from '../QuestionTypes/Select';\nimport Text from '../QuestionTypes/Text';\nimport TextArea from '../QuestionTypes/TextArea';\n\nexport interface QuestionSelectProps {\n question: FormQuestion;\n setValue: (value: string | string[] | boolean) => void;\n disableScroll: () => void;\n disableAllScroll: () => void;\n enableScrollUp: () => void;\n markQuestionComplete: () => void;\n finalQuestion: boolean;\n isFormComplete: boolean;\n finishForm: () => void;\n value: string | string[] | boolean;\n buttonColour?: string;\n}\n\nconst QuestionSelect: FC = ({\n question,\n value,\n finalQuestion,\n setValue,\n markQuestionComplete,\n disableScroll,\n disableAllScroll,\n enableScrollUp,\n finishForm,\n isFormComplete,\n buttonColour,\n}) => {\n const location = useLocation();\n const activeQuestionAnchor = location.hash.substring(1);\n const { formState } = useContext(FormContext);\n const questionDetails = formState.questionGroups\n .map((questionGroup) => questionGroup.questions)\n .flat();\n\n const firstIncompleteQuestionIndex = questionDetails.findIndex(\n (question) => question.status === FormQuestionStatus.NOT_COMPLETED,\n );\n const firstIncompleteQuestionId =\n questionDetails[firstIncompleteQuestionIndex] &&\n questionDetails[firstIncompleteQuestionIndex]._id;\n const isOnLastQuestion = activeQuestionAnchor === firstIncompleteQuestionId;\n\n useEffect(() => {\n disableScroll();\n }, [isOnLastQuestion, disableScroll]);\n\n useEffect(() => {\n if (isFormComplete) {\n finishForm();\n }\n }, [isFormComplete, finishForm]);\n\n switch (question.displayType) {\n case FormQuestionDisplayType.TEXT_AREA:\n return (\n \n );\n case FormQuestionDisplayType.SELECT:\n return (\n \n );\n case FormQuestionDisplayType.DATE:\n return (\n \n );\n case FormQuestionDisplayType.MULTIPLE_CHOICE:\n return (\n \n );\n case FormQuestionDisplayType.BOOLEAN:\n return (\n \n );\n case FormQuestionDisplayType.TEXT:\n return (\n \n );\n case FormQuestionDisplayType.NUMBER:\n return (\n \n );\n\n default:\n return (\n \n );\n }\n};\n\nexport default QuestionSelect;\n","import { Enums } from '@configur-tech/upit-core-types';\nimport {\n FormQuestionDisplayType,\n FormQuestionStatus,\n} from '@configur-tech/upit-core-types/lib/enums';\nimport ReactFullpage from '@fullpage/react-fullpage';\nimport { DateTime } from 'luxon';\nimport React, { FC, useContext, useEffect, useState } from 'react';\nimport { useLocation } from 'react-router-dom';\nimport styled, { ThemeContext } from 'styled-components';\nimport { FormContext, FormOutputWithTheme } from '../../../AppContext';\nimport Devices from '../../../enums/DeviceSize';\nimport FormService from '../../../services/FormService';\nimport { InputWrapper, TextStyledSubHeader } from '../../../Theme';\nimport FeatureButton, {\n FeatureButtonSize,\n} from '../../atoms/FeatureButton/FeatureButton';\nimport Loading from '../loading/Loading';\nimport QuestionSelect from '../QuestionSelect/QuestionSelect';\n\nconst SlideInnerWrapper = styled.div`\n background-color: ${({ theme }) => theme.colors.system.white};\n height: 100%;\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n a,\n a:hover,\n a:focus,\n a:active {\n color: ${({ theme }) => theme.colors.system.offWhite};\n text-decoration: none;\n cursor: pointer;\n }\n`;\n\nconst StartFinishPageWrapper = styled(InputWrapper)`\n align-items: center;\n justify-content: center;\n text-align: center;\n > p {\n font-size: 1.8em;\n padding: ${({ theme }) => theme.padding.xxxlarge};\n margin: 0;\n @media only screen and (max-width: ${Devices.LARGE_PHONE}) {\n font-size: ${({ theme }) => theme.typography.sizes.h4};\n }\n }\n > div {\n align-self: center;\n padding: ${({ theme }) => theme.padding.xxxlarge};\n }\n`;\n\nconst MainPage: FC<{\n isFormComplete: boolean;\n setIsFormComplete: (value: boolean) => void;\n}> = ({ setIsFormComplete, isFormComplete }) => {\n const { formState, setFormState } = useContext(FormContext);\n\n const [loading, setLoading] = useState(false);\n const [submitted, setSubmitted] = useState(false);\n const [error, setError] = useState(false);\n\n const questionDetails = formState.questionGroups\n .map((questionGroup) => questionGroup.questions)\n .flat();\n const finalQuestionId = questionDetails\n .filter((q) => q.displayType !== FormQuestionDisplayType.HIDDEN)\n ?.reverse()[0]._id;\n const themeContext = useContext(ThemeContext);\n const location = useLocation();\n const activeQuestionAnchor = location.hash.substring(1);\n const initialiseFormValues = () => {\n const valuesArray = {};\n questionDetails.forEach(\n (question) => (valuesArray[question._id] = question.value),\n );\n return valuesArray;\n };\n const [formValues, setFormValues] = useState<\n Record\n >(initialiseFormValues());\n\n const buttonColour =\n (formState as FormOutputWithTheme)?.theme?.colours?.tertiary ||\n themeContext.colors.general.green;\n\n const updateQuestionStateValue = (groupName, questionId, newValue) => {\n const group = formState.questionGroups.find(\n (group) => group.groupName === groupName,\n );\n const question = group?.questions.find(\n (question) => question._id === questionId,\n );\n if (question) {\n question.value = newValue;\n setFormState(formState);\n }\n };\n\n useEffect(() => {\n if (\n questionDetails.filter((x) => x.status === FormQuestionStatus.COMPLETED)\n .length === questionDetails.length\n ) {\n setIsFormComplete(true);\n }\n }, [activeQuestionAnchor, questionDetails]);\n\n const completeQuestion = (groupName, questionId) => {\n const group = formState.questionGroups.find(\n (group) => group.groupName === groupName,\n );\n const question = group?.questions.find(\n (question) => question._id === questionId,\n );\n if (question) {\n question.status = FormQuestionStatus.COMPLETED;\n }\n setFormState(formState);\n };\n\n const generateAnswersObject = () => {\n const valuesObject = {};\n questionDetails.forEach((question) => {\n if (Array.isArray(question.value)) {\n valuesObject[question.field.name] = question.value.join(', ');\n } else if (question.setValueAsSubmittedDate) {\n const format =\n question.field.dataValidation?.constraints?.format ||\n Enums.DateFormat.DATE_SHORT;\n valuesObject[question.field.name] = DateTime.now().toFormat(format);\n } else {\n valuesObject[question.field.name] = question.value;\n }\n });\n\n return valuesObject;\n };\n\n const postCompletedQuestions = async () => {\n setLoading(true);\n try {\n await FormService.postForm(formState._id, formState.datasetMetaId, [\n generateAnswersObject(),\n ]);\n setSubmitted(true);\n } catch (err) {\n setError(true);\n }\n setLoading(false);\n };\n\n useEffect(() => {\n if (\n questionDetails\n .filter(\n (question) => question.displayType !== FormQuestionDisplayType.HIDDEN,\n )\n .every((question) => question.status === FormQuestionStatus.COMPLETED)\n ) {\n postCompletedQuestions();\n }\n }, [activeQuestionAnchor]);\n\n const getAnchors = () => {\n const allQuestionIds = questionDetails\n .filter(\n (question) =>\n question.displayType !== Enums.FormQuestionDisplayType.HIDDEN,\n )\n .map((questionDetail) => questionDetail._id);\n\n return ['welcome', ...allQuestionIds, 'finish'];\n };\n\n if (loading) {\n return ;\n }\n\n return (\n {\n return (\n \n {!submitted && !error && (\n <>\n
\n \n \n \n {formState.intro?.title}\n \n

{formState.intro?.body}

\n {\n fullpageApi.moveSectionDown();\n }}\n size={FeatureButtonSize.WIDE}\n color={buttonColour}\n text={formState.intro?.buttonText}\n />\n
\n
\n
\n\n {formState.questionGroups.map((group) => {\n return group.questions\n .filter(\n (question) =>\n question.displayType !==\n Enums.FormQuestionDisplayType.HIDDEN,\n )\n .map((questionButton, index) => {\n return (\n
\n \n {\n fullpageApi?.setAllowScrolling(false);\n fullpageApi?.setKeyboardScrolling(false);\n }}\n disableScroll={() => {\n fullpageApi?.setAllowScrolling(false, 'down');\n fullpageApi?.setKeyboardScrolling(\n false,\n 'down',\n );\n }}\n disableAllScroll={() => {\n fullpageApi?.setAllowScrolling(false, 'up');\n fullpageApi?.setKeyboardScrolling(false, 'up');\n fullpageApi?.setAllowScrolling(false, 'down');\n fullpageApi?.setKeyboardScrolling(\n false,\n 'down',\n );\n }}\n enableScrollUp={() => {\n fullpageApi?.setAllowScrolling(true, 'up');\n fullpageApi?.setKeyboardScrolling(true, 'up');\n }}\n markQuestionComplete={() => {\n fullpageApi.moveSectionDown();\n completeQuestion(\n group.groupName,\n questionButton._id,\n );\n }}\n setValue={(value) => {\n updateQuestionStateValue(\n group.groupName,\n questionButton._id,\n value,\n );\n setFormValues({\n ...formValues,\n [questionButton._id]: value,\n });\n }}\n buttonColour={buttonColour}\n />\n \n
\n );\n });\n })}\n \n )}\n\n
\n \n \n \n {error ? 'Something went wrong' : formState.outro?.title}\n \n

\n {error\n ? 'A problem has occurred. Please try again later.'\n : formState.outro?.body}\n

\n
\n
\n
\n
\n );\n }}\n />\n );\n};\n\nexport default MainPage;\n","import { faBars } from '@fortawesome/free-solid-svg-icons';\nimport { FontAwesomeIcon } from '@fortawesome/react-fontawesome';\nimport React, { FC, useContext, useEffect } from 'react';\nimport styled, { ThemeContext } from 'styled-components';\nimport { FormContext, FormOutputWithTheme } from '../../../AppContext';\nimport Devices from '../../../enums/DeviceSize';\nimport DefaultAvatar from '../../assets/codex-icon.svg';\nimport FeatureButton, {\n FeatureButtonSize,\n} from '../../atoms/FeatureButton/FeatureButton';\nimport ProgressBar from '../../atoms/ProgressBar/ProgressBar';\nimport MainPage from '../MainPage/MainPage';\n\nexport interface MainPageProps {\n isVisible: boolean;\n setIsVisibleValue: React.Dispatch>;\n isFormComplete: boolean;\n setIsFormComplete: React.Dispatch>;\n}\n\nconst MainPageHeaderWrapper = styled.div<{ isVisible: boolean }>`\n background-color: ${({ theme }) => theme.colors.system.white};\n ${({ isVisible }) =>\n isVisible\n ? `width: 80vw; margin-left: 20vw; `\n : `width: 100vw; margin-left: 0; `};\n transition: 0.25s;\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n ${({ isVisible }) => (isVisible ? `width: 100vw; margin-left: 0;` : ``)};\n }\n`;\n\nconst MainPageWrapper = styled.div<{ isVisible: boolean }>`\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n ${({ isVisible }) =>\n isVisible ? `display: none;` : `width: 100vw; margin-left: 0;`};\n }\n`;\n\nconst NavToggleWrapper = styled.div`\n padding: ${({ theme }) => theme.padding.standard};\n display: flex;\n align-items: center;\n justify-content: center;\n > h1 {\n margin: ${({ theme }) => theme.margin.xxxlarge};\n font-size: ${({ theme }) => theme.typography.sizes.h2};\n\n @media only screen and (max-width: ${Devices.LARGE_PHONE}) {\n font-size: ${({ theme }) => theme.typography.sizes.h4};\n margin: ${({ theme }) => theme.margin.large};\n }\n @media only screen and (max-width: ${Devices.NORMAL_PHONE}) {\n font-size: ${({ theme }) => theme.typography.sizes.smaller};\n }\n }\n`;\n\nconst Heading = styled.div<{ isVisible: boolean; backgroundColor?: string }>`\n display: flex;\n justify-content: space-between;\n align-items: center;\n background-color: ${({ backgroundColor, theme }) =>\n backgroundColor ? backgroundColor : theme.colors.system.offWhite};\n height: 90px;\n ${({ isVisible }) => (isVisible ? `width: 80vw;` : `width: 100vw;`)};\n transition: 0.25s;\n position: fixed;\n top: 0;\n z-index: 1;\n border-bottom: 1px solid ${({ theme }) => theme.colors.system.grey};\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n ${({ isVisible }) => (isVisible ? `width: 100vw;` : ``)};\n }\n`;\n\nconst LogoWrapper = styled.div<{ isVisible: boolean }>`\n display: flex;\n justify-content: center;\n z-index: -1;\n position: fixed;\n ${({ isVisible }) => (isVisible ? `width: 85vw;` : `width: 100vw;`)};\n\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n position: static;\n margin: ${({ theme }) => theme.margin.standard};\n ${({ isVisible }) => (isVisible ? `width: 10vw` : `width: 10vw;`)};\n }\n`;\n\nconst ProgressBarWrapper = styled.div`\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n position: fixed;\n top: 90px;\n }\n`;\n\nconst MainPageContainer: FC = ({\n isVisible,\n setIsVisibleValue,\n isFormComplete,\n setIsFormComplete,\n}) => {\n const themeContext = useContext(ThemeContext);\n const { formState } = useContext(FormContext);\n\n const isMobile = window.innerWidth < parseFloat(Devices.TABLET_PORTRAIT);\n useEffect(() => {\n if (isFormComplete) {\n setIsVisibleValue(false);\n }\n }, [isFormComplete]);\n const headerColour = (formState as FormOutputWithTheme)?.theme?.colours\n ?.primary;\n const navButtonColour = (formState as FormOutputWithTheme)?.theme?.colours\n ?.secondary;\n const progressBarColour = (formState as FormOutputWithTheme)?.theme?.colours\n ?.tertiary;\n\n return (\n <>\n \n \n \n {!isFormComplete && (\n setIsVisibleValue(!isVisible)}\n isActive={isVisible}\n icon={\n \n }\n size={FeatureButtonSize.EXTRA_SMALL}\n color={navButtonColour}\n />\n )}\n

{formState.name}

\n
\n \n \n \n \n \n \n
\n \n \n \n
\n \n );\n};\n\nexport default MainPageContainer;\n","import React, { FC, useContext } from 'react';\nimport { ThemeContext } from 'styled-components';\nimport { FontAwesomeIcon } from '@fortawesome/react-fontawesome';\nimport { faCheckCircle } from '@fortawesome/free-solid-svg-icons';\nimport { FormQuestionStatus } from '@configur-tech/upit-core-types/lib/enums';\n\ninterface StatusIconProps {\n status: FormQuestionStatus;\n isQuestionActive: boolean;\n}\n\nconst StatusIcon: FC = ({ status, isQuestionActive }) => {\n const themeContext = useContext(ThemeContext);\n let color;\n switch (status) {\n case FormQuestionStatus.COMPLETED:\n color = themeContext.colors.general.green;\n break;\n case FormQuestionStatus.NOT_COMPLETED:\n isQuestionActive\n ? (color = themeContext.colors.system.offWhite)\n : (color = themeContext.colors.system.grey);\n break;\n\n default:\n color = themeContext.colors.general.yellow;\n }\n\n return ;\n};\n\nexport default StatusIcon;\n","import { Enums, Interfaces } from '@configur-tech/upit-core-types';\nimport { FormQuestionStatus } from '@configur-tech/upit-core-types/lib/enums';\nimport { faChevronDown, faChevronUp } from '@fortawesome/free-solid-svg-icons';\nimport { FontAwesomeIcon } from '@fortawesome/react-fontawesome';\nimport React, {\n CSSProperties,\n FC,\n useContext,\n useEffect,\n useState,\n} from 'react';\nimport { useLocation } from 'react-router-dom';\nimport { Accordion } from 'semantic-ui-react';\nimport styled, { ThemeContext } from 'styled-components';\nimport { FormContext, FormOutputWithTheme } from '../../../AppContext';\nimport Devices from '../../../enums/DeviceSize';\nimport PoweredBy from '../../atoms/PoweredBy/PoweredBy';\nimport StatusIcon from '../../atoms/StatusIcon/StatusIcon';\n\nconst StyledAccordionContent = styled(({ ...props }) => {\n delete props.isQuestionActive;\n return ;\n})`\n width: 100%;\n padding: inherit;\n ${({ isQuestionActive, theme }) =>\n isQuestionActive\n ? `background-color: ${theme.colors.system.grey};\n > a > div > svg {\n color: ${theme.colors.system.white};\n }`\n : `background-color: ${theme.colors.system.offWhite}\n `};\n\n > a {\n color: inherit;\n }\n .blockedCursor {\n cursor: not-allowed;\n }\n :hover {\n background-color: ${({ theme }) => `${theme.colors.system.grey}`};\n > a > div > svg {\n color: ${({ theme }) => theme.colors.system.white};\n }\n }\n`;\n\nconst AccordionInnerText = styled.div`\n display: flex;\n align-items: center;\n justify-content: space-between;\n white-space: nowrap;\n > p {\n overflow: hidden;\n text-overflow: ellipsis;\n margin: 0;\n padding-right: ${({ theme }) => theme.padding.standard};\n }\n`;\n\nconst StyledAccordionTitle = styled(({ ...props }) => {\n delete props.isGroupActive;\n return ;\n})`\n width: 100%;\n\n ${({ accordionActiveColour, isGroupActive, theme }) =>\n isGroupActive\n ? `background-color: ${\n accordionActiveColour\n ? accordionActiveColour\n : theme.colors.general.blue\n } ; > p{color: ${theme.colors.system.white}}`\n : `background-color: ${theme.colors.system.grey}; > p{color: ${theme.colors.system.offBlack}}`};\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n > p {\n padding: ${({ theme }) => `${theme.padding.standard} `};\n margin: 0;\n }\n > .svg-inline--fa {\n margin: ${({ theme }) => `${theme.margin.standard}`};\n width: ${({ theme }) => theme.typography.sizes.h4};\n height: ${({ theme }) => theme.typography.sizes.h4};\n }\n`;\n\nconst AccordionWrapper = styled.div`\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n height: calc(100vh - 90px);\n }\n`;\n\nconst NavPoweredByWrapper = styled.div`\n display: none;\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n display: flex;\n justify-content: center;\n margin-bottom: ${({ theme }) => theme.margin.xlarge};\n }\n`;\n\nconst NavItems: FC<{\n setIsVisible: React.Dispatch>;\n}> = ({ setIsVisible }) => {\n const themeContext = useContext(ThemeContext);\n const { formState } = useContext(FormContext);\n const location = useLocation();\n const [activeGroupIndex, setActiveGroupIndex] = useState(0);\n const [activeQuestionIndex, setActiveQuestionIndex] = useState(0);\n const isMobile = window.innerWidth < parseFloat(Devices.TABLET_PORTRAIT);\n const activeQuestionAnchor = location.hash.substring(1);\n\n const AccordionStyles: CSSProperties = {\n padding: themeContext.padding.standard,\n };\n\n const accordionActiveColour = (formState as FormOutputWithTheme)?.theme\n ?.colours?.secondary;\n\n const questionDetails = formState.questionGroups\n .map((questionGroup) => questionGroup.questions)\n .flat();\n\n const ActiveQuestionAnchorIndex = questionDetails.findIndex(\n (question) => question._id === activeQuestionAnchor,\n );\n\n const isWelcomeActive =\n questionDetails.filter(\n (questionDetail) => questionDetail._id === activeQuestionAnchor,\n ).length === 0;\n\n const isLinkEnabled = (questionId) =>\n questionDetails.findIndex((question) => question._id === questionId) <=\n ActiveQuestionAnchorIndex\n ? `#${questionId}`\n : undefined;\n\n const selectCursor = (questionId) => {\n if (questionId > ActiveQuestionAnchorIndex) {\n return `blockedCursor`;\n }\n };\n\n const findActiveGroupIndex = (data) =>\n data.findIndex(\n (group) =>\n group.questions.findIndex(\n (question) => question._id === activeQuestionAnchor,\n ) !== -1,\n );\n\n const findActiveQuestionIndex = (group) =>\n group\n ? group.questions.findIndex(\n (question) => question._id === activeQuestionAnchor,\n )\n : -1;\n\n useEffect(() => {\n const groupIndex = findActiveGroupIndex(formState.questionGroups);\n const questionIndex = findActiveQuestionIndex(\n formState.questionGroups[groupIndex],\n );\n setActiveGroupIndex(groupIndex);\n setActiveQuestionIndex(questionIndex);\n }, [activeQuestionAnchor]);\n\n const handleClick = (_, titleProps) => {\n const { index } = titleProps;\n\n const newIndex = activeGroupIndex === index ? -1 : index;\n\n setActiveGroupIndex(newIndex);\n setActiveQuestionIndex(-1);\n };\n\n const getGroupStatus = (questions: Interfaces.FormQuestionOutput[]) => {\n const numberOfQuestions = questions.filter(\n (question) =>\n question.displayType !== Enums.FormQuestionDisplayType.HIDDEN,\n ).length;\n const numberOfCompletedQuestions = questions.filter(\n (question) =>\n question.status === FormQuestionStatus.COMPLETED &&\n question.displayType !== Enums.FormQuestionDisplayType.HIDDEN,\n ).length;\n return `(${numberOfCompletedQuestions}/${numberOfQuestions})`;\n };\n\n return (\n \n \n \n \n

{'Welcome'}

\n \n
\n {formState.questionGroups.map((group, groupIndex) => {\n const isGroupActive = activeGroupIndex === groupIndex;\n return (\n
\n \n

\n {group.groupName} {getGroupStatus(group.questions)}\n

\n \n \n {group.questions\n .filter(\n (question) =>\n question.displayType !==\n Enums.FormQuestionDisplayType.HIDDEN,\n )\n .map((questionButton, questionIndex) => {\n const isQuestionActive =\n questionIndex === activeQuestionIndex;\n return (\n isMobile && setIsVisible(false)}\n key={questionIndex}\n >\n \n \n

{questionButton.question}

\n \n
\n \n \n );\n })}\n
\n );\n })}\n
\n \n \n \n
\n );\n};\n\nexport default NavItems;\n","import React, { FC, useContext, useEffect, useState } from 'react';\nimport { Helmet } from 'react-helmet-async';\nimport { useParams } from 'react-router';\n\nimport { useHistory } from 'react-router-dom';\nimport styled from 'styled-components';\nimport { FormContext } from '../AppContext';\nimport PoweredBy from '../common/atoms/PoweredBy/PoweredBy';\nimport Loading from '../common/molecules/loading/Loading';\nimport MainPageContainer from '../common/molecules/MainPageContainer/MainHeaderContainer';\nimport NavItems from '../common/molecules/NavItems/NavItems';\nimport Devices from '../enums/DeviceSize';\nimport FormService from '../services/FormService';\n\nconst Wrapper = styled.div`\n height: 100vh;\n display: flex;\n flex-direction: column;\n`;\n\nconst Sidebar = styled.div<{ isVisible: boolean }>`\n position: fixed;\n height: 100%;\n border-right: 1px solid ${({ theme }) => theme.colors.system.grey};\n background-color: ${({ theme }) => theme.colors.system.offWhite};\n ${({ isVisible }) => (isVisible ? `width: 20vw;` : `width: 0;`)};\n transition: width 0.25s;\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n ${({ isVisible }) =>\n isVisible ? `width: 100vw; margin-top: 90px;` : `width: 0;`};\n }\n`;\n\nconst PoweredByWrapper = styled.div`\n right: ${({ theme }) => theme.margin.xlarge};\n position: fixed;\n bottom: ${({ theme }) => theme.margin.xlarge};\n z-index: 99;\n @media only screen and (max-width: ${Devices.TABLET_PORTRAIT}) {\n display: none;\n }\n`;\n\nconst FormContainer: FC = () => {\n const params = useParams();\n const history = useHistory();\n\n const { formState, setFormState } = useContext(FormContext);\n\n const [isVisible, setIsVisible] = useState(false);\n const [isFormComplete, setIsFormComplete] = useState(false);\n\n useEffect(() => {\n if (params.projectId && params.formId) {\n (async () => {\n try {\n const form = await FormService.getForm(\n params.projectId,\n params.formId,\n );\n setFormState(form);\n } catch (err) {\n history.push('/');\n }\n })();\n }\n }, []);\n\n if (!formState._id) {\n return ;\n }\n\n return (\n <>\n \n {`${formState.name || 'Form'} - Powered by Configur`}\n \n\n \n \n \n \n \n \n\n \n \n \n \n );\n};\n\nexport default FormContainer;\n","import React, { FC } from 'react';\nimport { Route, Switch } from 'react-router-dom';\nimport ErrorContainer from '../pages/ErrorContainer';\nimport FormContainer from '../pages/FormContainer';\n\nconst Routes: FC = () => {\n return (\n \n {/*Form*/}\n \n {/*Error*/}\n \n \n );\n};\n\nexport default Routes;\n","import React, { FC, useState } from 'react';\nimport 'react-datepicker/dist/react-datepicker.css';\nimport { HelmetProvider } from 'react-helmet-async';\nimport { BrowserRouter as Router } from 'react-router-dom';\nimport { FormContext, FormOutputWithTheme } from './AppContext';\nimport Routes from './routes/Routes';\nimport { initialFormState } from './state/initial-form-state';\nimport Theme from './Theme';\n\nconst App: FC = () => {\n const [formState, setFormState] = useState(\n initialFormState as FormOutputWithTheme,\n );\n\n return (\n \n \n \n \n
\n \n
\n
\n
\n
\n
\n );\n};\n\nexport default App;\n","import { ReportHandler } from 'web-vitals';\n\nconst reportWebVitals = (onPerfEntry?: ReportHandler): void => {\n if (onPerfEntry && onPerfEntry) {\n import('web-vitals').then(({ getCLS, getFID, getFCP, getLCP, getTTFB }) => {\n getCLS(onPerfEntry);\n getFID(onPerfEntry);\n getFCP(onPerfEntry);\n getLCP(onPerfEntry);\n getTTFB(onPerfEntry);\n });\n }\n};\n\nexport default reportWebVitals;\n","import React from 'react';\nimport ReactDOM from 'react-dom';\nimport App from './App';\nimport reportWebVitals from './reportWebVitals';\nimport 'semantic-ui-css/semantic.min.css';\n\nReactDOM.render(\n \n \n ,\n document.getElementById('root'),\n);\n\n// If you want to start measuring performance in your app, pass a function\n// to log results (for example: reportWebVitals(console.log))\n// or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals\nreportWebVitals();\n"],"sourceRoot":""}